XGCa
Public Types | Public Member Functions | Static Public Member Functions | List of all members
PlaneFiles Struct Reference

#include <grid_files.hpp>

Inheritance diagram for PlaneFiles:
Inheritance graph
[legend]
Collaboration diagram for PlaneFiles:
Collaboration graph
[legend]

Public Types

enum  GridCreateOpt { Hexagonal =0 , Circular =1 }
 

Public Member Functions

void convert_to_x_rgn_format (const View< double **, CLayout, HostType > &tmp_nodes, View< RZPair *, HostType > &x, View< int *, HostType > &rgn, bool is_stellarator)
 
void convert_to_node_format (const View< int **, CLayout, HostType > &tmp_ele, View< Vertex *, HostType > &nodes)
 
 PlaneFiles ()
 
void construct_hex_grid (int nshells, double raxis, double zaxis, double rscale, double zscale)
 
double node_to_node_dist (RZPair a, RZPair b)
 
void construct_circular_grid (int nshells, double raxis, double zaxis, double rscale, double zscale)
 
 PlaneFiles (int nshells, double raxis, double zaxis, double rscale, double zscale, GridCreateOpt grid_opt=Hexagonal)
 
 PlaneFiles (MagneticField< HostType > &magnetic_field, int nshells, GridCreateOpt grid_opt=Hexagonal)
 
int get_nnodes () const override
 
View< RZPair *, HostTypeget_x () const override
 
View< int *, HostTypeget_rgn () const override
 
int get_ntriangles () const override
 
View< Vertex *, HostTypeget_nodes () const override
 
View< int *, HostTypeget_i_x () const override
 
int get_nsurfaces () const override
 
int get_nsurfaces1 () const override
 
int get_nsurfaces2 () const override
 
int get_nsurfaces3a () const override
 
int get_nsurfaces3b () const override
 
View< int *, HostTypeget_i_surf_separatrices () const override
 
View< int *, HostTypeget_nnodes_on_surface () const override
 
int get_sum_nnodes_on_surfaces () const override
 
int get_num_non_aligned () const override
 
View< int *, HostTypeget_non_aligned_vert () const override
 
View< int *, HostTypeget_non_aligned_nsurf () const override
 
View< int **, CLayout, HostTypeget_non_aligned_surf_idx () const override
 
View< int **, CLayout, HostTypeget_surf_idx () const override
 
View< int *, HostTypepack_scalars (int max_nodes_on_surface, int n_xpts, int n_separatrices) const override
 
void unpack_scalars (const View< int *, HostType > &scalars, int &max_nodes_on_surface, int &n_xpts, int &n_separatrices) override
 
int n_specified_xpts () const override
 
View< Equil::XPoint *, HostTypeget_xpts () const override
 
RZPair get_axis () const override
 
RZPair get_reference_point () const override
 
View< double *, HostTypeget_psiN () const override
 
- Public Member Functions inherited from PlaneFilesInterface
virtual ~PlaneFilesInterface ()=default
 

Static Public Member Functions

static int nshells_from_nnodes (int nnodes)
 

Additional Inherited Members

- Protected Types inherited from PlaneFilesBase
enum  FileRegion { Inside =0 , OnWall }
 
- Protected Attributes inherited from PlaneFilesBase
int nnodes
 
View< RZPair *, HostTypex
 
View< int *, HostTypergn
 
int ntriangles
 
View< Vertex *, HostTypenodes
 
View< int *, HostTypei_x
 
int nsurfaces
 
int nsurfaces1
 
int nsurfaces2
 
int nsurfaces3a
 
int nsurfaces3b
 
View< int *, HostTypei_surf_separatrices
 
View< int *, HostTypennodes_on_surface
 
int sum_nnodes_on_surfaces
 
int num_non_aligned
 
View< int *, HostTypenon_aligned_vert
 
View< int *, HostTypenon_aligned_nsurf
 
View< int **, CLayout, HostTypenon_aligned_surf_idx
 
View< int **, CLayout, HostTypesurf_idx
 
View< double *, HostTypepsiN
 An array of normalized psi coordinates temporarily needed for the stellarator version. More...
 

Member Enumeration Documentation

◆ GridCreateOpt

Enumerator
Hexagonal 
Circular 

Constructor & Destructor Documentation

◆ PlaneFiles() [1/3]

PlaneFiles::PlaneFiles ( )
inline

◆ PlaneFiles() [2/3]

PlaneFiles::PlaneFiles ( int  nshells,
double  raxis,
double  zaxis,
double  rscale,
double  zscale,
GridCreateOpt  grid_opt = Hexagonal 
)

Constructor to create analytic grid (hexagonal shells) given center and triangle scale

Parameters
[in]nshellsis the number of concentric hexagons to be constructed
[in]raxisis where the grid is to be centered (r coord)
[in]zaxisis where the grid is to be centered (z coord)
[in]rscaleis the length of the triangles
[in]zscaleis the height of the triangles
Here is the call graph for this function:

◆ PlaneFiles() [3/3]

PlaneFiles::PlaneFiles ( MagneticField< HostType > &  magnetic_field,
int  nshells,
GridCreateOpt  grid_opt = Hexagonal 
)

Constructor to create analytic grid (hexagonal shells) to fit the magnetic field provided

Parameters
[in]magnetic_fieldis the magnetic field that the grid should fit
[in]nshellsis the number of concentric hexagons to be constructed
Here is the call graph for this function:

Member Function Documentation

◆ construct_circular_grid()

void PlaneFiles::construct_circular_grid ( int  nshells,
double  raxis,
double  zaxis,
double  rscale,
double  zscale 
)

Construct the circular grid

Parameters
[in]nshellsis the number of concentric circles to be constructed
[in]raxisis where the grid is to be centered (r coord)
[in]zaxisis where the grid is to be centered (z coord)
[in]rscaleis the length of the triangles
[in]zscaleis the height of the triangles
Here is the call graph for this function:
Here is the caller graph for this function:

◆ construct_hex_grid()

void PlaneFiles::construct_hex_grid ( int  nshells,
double  raxis,
double  zaxis,
double  rscale,
double  zscale 
)

Construct the analytic hexagonal grid

Parameters
[in]nshellsis the number of concentric hexagons to be constructed
[in]raxisis where the grid is to be centered (r coord)
[in]zaxisis where the grid is to be centered (z coord)
[in]rscaleis the length of the triangles
[in]zscaleis the height of the triangles
Here is the caller graph for this function:

◆ convert_to_node_format()

void PlaneFiles::convert_to_node_format ( const View< int **, CLayout, HostType > &  tmp_ele,
View< Vertex *, HostType > &  nodes 
)
Here is the call graph for this function:

◆ convert_to_x_rgn_format()

void PlaneFiles::convert_to_x_rgn_format ( const View< double **, CLayout, HostType > &  tmp_nodes,
View< RZPair *, HostType > &  x,
View< int *, HostType > &  rgn,
bool  is_stellarator 
)
Here is the call graph for this function:

◆ get_axis()

RZPair PlaneFiles::get_axis ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_i_surf_separatrices()

View< int *, HostType > PlaneFiles::get_i_surf_separatrices ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_i_x()

View< int *, HostType > PlaneFiles::get_i_x ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nnodes()

int PlaneFiles::get_nnodes ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nnodes_on_surface()

View< int *, HostType > PlaneFiles::get_nnodes_on_surface ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nodes()

View< Vertex *, HostType > PlaneFiles::get_nodes ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_non_aligned_nsurf()

View< int *, HostType > PlaneFiles::get_non_aligned_nsurf ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_non_aligned_surf_idx()

View< int **, CLayout, HostType > PlaneFiles::get_non_aligned_surf_idx ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_non_aligned_vert()

View< int *, HostType > PlaneFiles::get_non_aligned_vert ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nsurfaces()

int PlaneFiles::get_nsurfaces ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nsurfaces1()

int PlaneFiles::get_nsurfaces1 ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nsurfaces2()

int PlaneFiles::get_nsurfaces2 ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nsurfaces3a()

int PlaneFiles::get_nsurfaces3a ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_nsurfaces3b()

int PlaneFiles::get_nsurfaces3b ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_ntriangles()

int PlaneFiles::get_ntriangles ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_num_non_aligned()

int PlaneFiles::get_num_non_aligned ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_psiN()

View< double *, HostType > PlaneFiles::get_psiN ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_reference_point()

RZPair PlaneFiles::get_reference_point ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_rgn()

View< int *, HostType > PlaneFiles::get_rgn ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_sum_nnodes_on_surfaces()

int PlaneFiles::get_sum_nnodes_on_surfaces ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_surf_idx()

View< int **, CLayout, HostType > PlaneFiles::get_surf_idx ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_x()

View< RZPair *, HostType > PlaneFiles::get_x ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ get_xpts()

View< Equil::XPoint *, HostType > PlaneFiles::get_xpts ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ n_specified_xpts()

int PlaneFiles::n_specified_xpts ( ) const
overridevirtual

Implements PlaneFilesInterface.

◆ node_to_node_dist()

double PlaneFiles::node_to_node_dist ( RZPair  a,
RZPair  b 
)

Determine distance between two node points

Parameters
[in]ais the first point
[in]bis the second point
Here is the caller graph for this function:

◆ nshells_from_nnodes()

int PlaneFiles::nshells_from_nnodes ( int  nnodes)
static
Here is the caller graph for this function:

◆ pack_scalars()

View< int *, HostType > PlaneFiles::pack_scalars ( int  max_nodes_on_surface,
int  n_xpts,
int  n_separatrices 
) const
overridevirtual

Implements PlaneFilesInterface.

◆ unpack_scalars()

void PlaneFiles::unpack_scalars ( const View< int *, HostType > &  scalars,
int &  max_nodes_on_surface,
int &  n_xpts,
int &  n_separatrices 
)
overridevirtual

Implements PlaneFilesInterface.


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