Extension: Geometries
#include "dg/geometries/geometries.h"

Constructs and display geometric parameters for the solovev and taylor fields. More...

Public Member Functions

 Parameters (const dg::file::WrappedJsonValue &js)
 Construct from Json dataset. More...
 
Json::Value dump () const
 Put values into a json string. More...
 
bool hasXpoint () const
 True if any coefficient c_i!=0 with 7<=i<12. More...
 
bool isToroidal () const
 True if pp==0. More...
 
void display (std::ostream &os=std::cout) const
 Write variables as a formatted string. More...
 

Public Attributes

double A
 A coefficient. More...
 
double R_0
 major tokamak radius More...
 
double pp
 prefactor for Psi_p More...
 
double pi
 prefactor for current I More...
 
double a
 little tokamak radius More...
 
double elongation
 elongation of the magnetic surfaces More...
 
double triangularity
 triangularity of the magnetic surfaces More...
 
std::vector< double > c
 12 coefficients for the solovev equilibrium; More...
 
std::string description
 

Detailed Description

Constructs and display geometric parameters for the solovev and taylor fields.

Note
include json/json.h before geometries.h in order to activate json functionality

Constructor & Destructor Documentation

◆ Parameters()

dg::geo::solovev::Parameters::Parameters ( const dg::file::WrappedJsonValue &  js)
inline

Construct from Json dataset.

// Solovev (and Taylor) geometry parameters
{
"equilibrium": "solovev",
// Note that for the taylor field you need to include boost before the geometries header!
// "equilibrium" : "taylor",
"A": 0,
"R_0": 213.36,
"PP": 1,
"PI": 1,
"c":[
0.072597888572520090,
-0.14926096478076946,
// ... 12 coefficients in total
],
"description" : "standardX",
"inverseaspectratio": 0.3211009174311926,
"triangularity": 0.3,
"elongation": 1.44
}
See also
dg::geo::description to see valid values for the description field
Note
the dg::geo::taylor field is chosen by setting "taylor" in the equilibrium field (but also note that you need to include boost for the taylor field)
Parameters
jsvalid Json object (see code above to see the valid key : value pairs)
Note
the default values in brackets are taken if the variables are not found in the input file
Attention
This Constructor is only defined if json/json.h is included before dg/geometries/geometries.h

Member Function Documentation

◆ display()

void dg::geo::solovev::Parameters::display ( std::ostream &  os = std::cout) const
inline

Write variables as a formatted string.

◆ dump()

Json::Value dg::geo::solovev::Parameters::dump ( ) const
inline

Put values into a json string.

Returns
Json value
Attention
This member is only defined if json/json.h is included before dg/geometries/geometries.h

◆ hasXpoint()

bool dg::geo::solovev::Parameters::hasXpoint ( ) const
inline

True if any coefficient c_i!=0 with 7<=i<12.

The Xpoint is situated close to R_X = R_0-1.1*triangularity*a Z_X = -1.1*elongation*a

Returns
true if Psip has an Xpoint, false else

◆ isToroidal()

bool dg::geo::solovev::Parameters::isToroidal ( ) const
inline

True if pp==0.

Returns
true if the flux function is a constant

Member Data Documentation

◆ A

double dg::geo::solovev::Parameters::A

A coefficient.

◆ a

double dg::geo::solovev::Parameters::a

little tokamak radius

◆ c

std::vector<double> dg::geo::solovev::Parameters::c

12 coefficients for the solovev equilibrium;

◆ description

std::string dg::geo::solovev::Parameters::description

◆ elongation

double dg::geo::solovev::Parameters::elongation

elongation of the magnetic surfaces

◆ pi

double dg::geo::solovev::Parameters::pi

prefactor for current I

◆ pp

double dg::geo::solovev::Parameters::pp

prefactor for Psi_p

◆ R_0

double dg::geo::solovev::Parameters::R_0

major tokamak radius

◆ triangularity

double dg::geo::solovev::Parameters::triangularity

triangularity of the magnetic surfaces


The documentation for this struct was generated from the following file: