desc.geometry.FourierRZCurve
- class desc.geometry.FourierRZCurve(R_n=10, Z_n=0, modes_R=None, modes_Z=None, NFP=1, sym='auto', name='')Source
Curve parameterized by Fourier series for R,Z in terms of toroidal angle phi.
- Parameters:
R_n (array-like) – Fourier coefficients for R, Z.
Z_n (array-like) – Fourier coefficients for R, Z.
modes_R (array-like, optional) – Mode numbers associated with R_n. If not given defaults to [-n:n].
modes_Z (array-like, optional) – Mode numbers associated with Z_n, If not given defaults to [-n:n]].
NFP (int) – Number of field periods.
sym (bool) – Whether to enforce stellarator symmetry.
name (str) – Name for this curve.
Methods
change_resolution
([N, NFP, sym])Change the maximum toroidal resolution.
compute
(names[, grid, params, transforms, ...])Compute the quantity given by name on grid.
copy
([deepcopy])Return a (deep)copy of this object.
equiv
(other)Compare equivalence between DESC objects.
flip
([normal])Flip the curve about the plane with specified normal.
from_input_file
(path)Create a axis curve from Fourier coefficients in a DESC or VMEC input file.
get_coeffs
(n)Get Fourier coefficients for given mode number(s).
load
(load_from[, file_format])Initialize from file.
pack_params
(p)Convert a dictionary of parameters into a single array.
rotate
([axis, angle])Rotate the curve by a fixed angle about axis in X, Y, Z coordinates.
save
(file_name[, file_format, file_mode])Save the object.
set_coeffs
(n[, R, Z])Set specific Fourier coefficients.
to_FourierXYZ
([N, grid, s, name])Convert Curve to FourierXYZCurve representation.
to_SplineXYZ
([knots, grid, method, name])Convert Curve to SplineXYZCurve.
translate
([displacement])Translate the curve by a rigid displacement in X, Y, Z.
Convert a single array of concatenated parameters into a dictionary.
Attributes
Maximum mode number.
Number of field periods.
Spectral basis for R_Fourier series.
Spectral coefficients for R.
Spectral basis for Z_Fourier series.
Spectral coefficients for Z.
total number of optimizable parameters.
dictionary of integers of sizes of each optimizable parameter.
Name of the curve.
string names of parameters that have been declared optimizable.
dictionary of arrays of optimizable parameters.
Rotation matrix of curve in X, Y, Z.
Displacement of curve in X, Y, Z.
Whether this curve has stellarator symmetry.
arrays of indices for each parameter in concatenated array.