Template Struct variable_map< std::complex< double > >

Struct Documentation

template<>
struct blackbird::variable_map<std::complex<double>>

get and set complex values in the variable map

Public Static Functions

static inline std::complex<double> getVal(Visitor *V, std::string key)

Get value from the variable map corresponding to a name, and attempt to convert it into an complex value

Parameters
  • V – Blackbird Visitor

  • key – variable name

Throws
  • invalid_argument – Cannot convert a string variable to an complex

  • invalid_argument – Cannot convert a bool variable to an complex

  • invalid_argument – Variable key not defined

Returns

integer value

static inline void setVal(Visitor *V, std::string key, std::complex<double> val)

Set an complex value in the variable map corresponding to a name

Parameters
  • V – Blackbird Visitor

  • key – variable name

  • val – variable value