Stellarator-Tools
Limiter Gird File

Introduction

LGRID is a code to precompute the distance from a grid point to the closest point on a limiter. Limiters are specified as a series of line segments in a counter clockwise fasion. That is a polygon with vertices ordered in a counter clockwise will have the inside of the polygon represent the interior. Clockwise ordering will have the outside of the polygon represent the interior.

Input Configuation

All limiters are defined using the same format. A key word, the number of phi planes the limiter surface is associated with, a list of phi values and then a list of r z segment positions terminated by a end_limiter keyword.

keyword
num_phi
phi1(REAL) phi2(REAL) ... phiN(REAL)
r1(REAL) z1(REAL)
r2(REAL) z2(REAL)
...
rM(REAL) zM(REAL)
end_limiter

Keywords

new_limiter_degA limiter at phi angles specified in degrees.
new_limiter_radA limiter at phi angles specified in radians.
end_limiterEnd of the limiter.

Example File

3
10.0 50.0 175.0
0.5 -0.25
1.0 -0.25
1.0 0.25
0.5 0.25
end_limiter
const std::string new_limiter_deg
Limiter plane keyword specified in degrees.
Definition: main.cpp:91

Command Line Arguments

LGRID is run with the following command.

lgrid filename r0 dr numr z0 dz numz

filenamePath to file containing the limiter configuation.
r0Starting radial grid position.
drRadial grid width.
numrNumber of radial grid points.
z0Starting vertical grid position.
dzVertical grid width.
numzNumber of vertical grid points.