Stellarator-Tools
|
Defines the base class of the type surface_context_class. This module contains all the code necessary define a surface for cariddi to read a virtual surface from. More...
Data Types | |
interface | surface_context_class |
Base class representing a surface context. This contains all memory needed to operate surface. More... | |
Functions/Subroutines | |
class(surface_context_class) function, pointer | surface_context_construct (wout_file_name, surface_file_name, parallel, io_unit) |
Construct a surface_context_class object. More... | |
subroutine | surface_context_destruct (this) |
Deconstruct a bmw_context_class object. More... | |
subroutine | surface_context_set_vector_potential (this, io_unit, parallel) |
Set the vector potential on the surface. More... | |
subroutine | surface_context_write (this, output_file, io_unit, parallel) |
Defines the base class of the type surface_context_class. This module contains all the code necessary define a surface for cariddi to read a virtual surface from.
class (surface_context_class) function, pointer surface_context::surface_context_construct | ( | character (len=*), intent(in) | wout_file_name, |
character (len=*), intent(in) | surface_file_name, | ||
class (bmw_parallel_context_class), intent(in) | parallel, | ||
integer, intent(in) | io_unit | ||
) |
Construct a surface_context_class object.
Allocates memory and initializes a surface_context_class object.
[in] | wout_file_name | Path and name of the wout file. |
[in] | surface_file_name | Path defining the surface to compute fields to. |
[in] | parallel | bmw_parallel_context_class object instance. |
[in] | io_unit | Unit number to write messages to. |
subroutine surface_context::surface_context_destruct | ( | type (surface_context_class), intent(inout) | this | ) |
Deconstruct a bmw_context_class object.
Deallocates memory and uninitializes a bmw_context_class object.
[in,out] | this | A bmw_context_class instance. |
subroutine surface_context::surface_context_set_vector_potential | ( | class (surface_context_class), intent(inout) | this, |
integer, intent(in) | io_unit, | ||
class (bmw_parallel_context_class), intent(in) | parallel | ||
) |
Set the vector potential on the surface.
This uses the biot-savart to set a vector potential on an arbitrary surface. At each point in the surface, the plasma current in volume integrated.
b = mu0/4pi Int Int Int (Jsupu*esubu + Jsupv*esubv) / |x - xp|*signJ*J*da*du*dv (1)
Where the primed (p) variables are the values on the last closed flux surface grid.
[in,out] | this | A surface_context_class instance. |
[in] | io_unit | Unit number to write messages to. |
[in] | parallel | bmw_parallel_context_class object instance. |