Alphabetical Listing
Basis
|
1D basis set for flux surface quantities. |
|
1D basis set for use with the magnetic axis. |
|
2D basis set for use on a single flux surface. |
|
2D basis set for analytic functions in a unit disc. |
3D basis: tensor product of Chebyshev polynomials and two Fourier series. |
|
|
3D basis set for analytic functions in a toroidal volume. |
Coils
|
Set of coils of different geometry but shared parameterization and resolution. |
|
Coil parameterized by fourier series for R,Z in terms of toroidal angle phi. |
|
Coil parameterized by fourier series for X,Y,Z in terms of arbitrary angle s. |
|
Coil that lines in a plane. |
|
Set of coils or coilsets of different geometry. |
|
Coil parameterized by spline points in X,Y,Z. |
Compatibility
Convert an Equilibrium to have a positive coordinate Jacobian. |
|
Change the sign of the helicity of an Equilibrium. |
|
|
Rescale an Equilibrium in size L and magnetic field strength B. |
Continuation
Solve for an equilibrium by continuation method. |
|
Solve for an equilibrium using an automatic continuation method. |
Derivatives
Note that the derivative
module also exposes the Derivative
class, which is an alias for AutoDiffDerivative
if JAX is installed, or FiniteDiffDerivative
if not.
|
Computes derivatives using automatic differentiation with JAX. |
|
Computes derivatives using 2nd order centered finite differences. |
Equilibrium
|
Equilibrium is an object that represents a plasma equilibrium. |
EquilibriaFamily stores a list of Equilibria. |
Examples
|
Get example equilibria and data. |
Return a list of examples that DESC has. |
Geometry
|
Curve parameterized by Fourier series for R,Z in terms of toroidal angle phi. |
|
Curve parameterized by Fourier series for X,Y,Z in terms of arbitrary angle s. |
|
Curve that lies in a plane. |
Toroidal surface represented by Fourier series in poloidal and toroidal angles. |
|
|
Curve parameterized by spline knots in X,Y,Z. |
A toroidal cross section represented by a Zernike polynomial in R,Z. |
Grid
|
Collocation grid with custom node placement. |
|
Grid in which the nodes are linearly spaced in each coordinate. |
|
Grid used for numerical quadrature. |
|
Grid in which the nodes are arranged in concentric circles. |
Find "least rational" surfaces for given iota profile. |
|
Find "most rational" surfaces for a give iota profile. |
IO
|
Load any DESC object from previously saved file. |
Magnetic Fields
Magnetic field due to a surface current potential on a toroidal surface. |
|
Magnetic field due to a surface current potential on a toroidal surface. |
|
Magnetic field due to a Dommaschk scalar magnetic potential in rpz coordinates. |
|
|
A magnetic field with perfect omnigenity (but is not necessarily analytic). |
Pure poloidal magnetic field (ie in theta direction). |
|
Magnetic field due to a scalar magnetic potential in cylindrical coordinates. |
|
Magnetic field scaled by a scalar value. |
|
Magnetic field from precomputed values on a grid. |
|
Sum of two or more magnetic field sources. |
|
Magnetic field purely in the toroidal (phi) direction. |
|
Uniform magnetic field purely in the vertical (Z) direction. |
|
Trace field lines by integration. |
|
|
Read BNORM-style .txt file containing Bnormal Fourier coefficients. |
Objective Functions
|
Aspect ratio = major radius / minor radius. |
Promote consistency of the bootstrap current for axisymmetry or quasi-symmetry. |
|
|
Target for free boundary conditions on LCFS for finite beta equilibrium. |
|
Target a particular value for the magnetic field scale length. |
|
Radial, poloidal, and toroidal current density. |
|
Elongation = semi-major radius / semi-minor radius. |
|
MHD energy. |
|
Fixes effective atomic number profile coefficients. |
|
Fixes magnetic axis R coefficients. |
|
Fixes magnetic axis Z coefficients. |
|
Boundary condition on the R boundary parameters. |
|
Boundary condition on the Z boundary parameters. |
|
Fixes toroidal current profile coefficients. |
|
Fixes electron density profile coefficients. |
|
Fixes electron temperature profile coefficients. |
|
Fixes ion temperature profile coefficients. |
|
Fixes rotational transform coefficients. |
|
Fixes Fourier-Zernike R coefficients. |
|
Fixes Fourier-Zernike Z coefficients. |
|
Ensures the B_max contour is straight in Boozer coordinates. |
|
Fixes OmnigenousField.x_lmn coefficients. |
|
Fixes OmnigenousField.B_lm coefficients. |
|
Fix specific degrees of freedom associated with a given Optimizable object. |
|
Fixes pressure coefficients. |
|
Fixes total toroidal magnetic flux within the last closed flux surface. |
|
Fixes a linear sum of Fourier-Zernike R coefficients. |
|
Fixes a linear sum of Fourier-Zernike Z coefficients. |
|
Fixes lambda=0 so that poloidal angle is the SFL poloidal angle. |
|
Radial and helical MHD force balance. |
Force balance for anisotropic pressure equilibria. |
|
|
A generic objective that can compute any quantity from the data_index. |
Get the objective function for a typical force balance equilibrium problem. |
|
Get the constraints necessary for a fixed-axis equilibrium problem. |
|
Get the constraints necessary for a typical fixed-boundary equilibrium problem. |
|
|
Get the constraints necessary for fixing NAE behavior in an equilibrium problem. |
|
Target "good" coordinates, meaning non self-intersecting curves. |
|
Helical MHD force balance. |
|
Isodynamicity metric for cross field transport. |
|
Wrap a user defined linear objective function. |
|
The magnetic well is a fast proxy for MHD stability. |
|
Target a particular value for the mean curvature. |
|
The Mercier criterion is a fast proxy for MHD stability. |
|
Wrap a user defined objective function. |
|
Objective function comprised of one or more Objectives. |
|
Omnigenity error. |
|
Target the distance between the plasma and a surrounding surface. |
|
Target pressure profile. |
|
Target a particular value for the (unsigned) principal curvature. |
|
Quasi-symmetry Boozer harmonics error. |
|
Quasi-symmetry two-term error. |
Quasi-symmetry triple product error. |
|
|
Radial MHD force balance. |
|
Targets a rotational transform profile. |
|
Targets a shear profile (normalized derivative of rotational transform). |
|
Target toroidal current profile. |
|
Target for free boundary conditions on LCFS for vacuum equilibrium. |
|
Plasma volume. |
Optimize
|
A helper class to wrap several optimization routines. |
|
Minimize a function with constraints using an augmented Lagrangian method. |
|
Minimize a scalar function using a (quasi)-Newton trust region method. |
|
Minimize a function with constraints using an augmented Lagrangian method. |
|
Solve a least squares problem using a (quasi)-Newton trust region method. |
|
Decorator to wrap a function for optimization. |
|
Minimize a scalar function using stochastic gradient descent with momentum. |
Perturbations
|
Compute differences between parameters for perturbations. |
|
Perturb an Equilibrium with respect to input parameters. |
|
Perturb an Equilibrium with respect to input parameters to optimize an objective. |
Plotting
|
Plot 1D profiles. |
|
Plot 2D cross-sections. |
|
Plot 3D surfaces. |
|
Plot basis functions. |
|
Plot Fourier harmonics of \(|B|\) in Boozer coordinates. |
|
Plot \(|B|\) on a surface vs the Boozer poloidal and toroidal angles. |
|
Plot stellarator boundaries at multiple toroidal coordinates. |
|
Plot stellarator boundary at multiple toroidal coordinates. |
|
Plot spectral coefficient magnitudes vs spectral mode number. |
|
Create 3D plot of coil geometry. |
|
Plot comparison between flux surfaces of multiple equilibria. |
|
Plot flux surface averages of quantities. |
|
Plot the location of collocation nodes on the zeta=0 plane. |
|
Plot the DESC logo. |
|
Plot quasi-symmetry errors f_B, f_C, and f_T as normalized flux functions. |
|
Plot Poincare sections. |
|
Plot flux surfaces. |
Profiles
|
Profile represented by a monic power series. |
|
Profile represented by two powers. |
|
Profile represented by a piecewise cubic spline. |
|
Profile represented by a modified hyperbolic tangent + polynomial. |
|
Profile times a constant value. |
|
Sum of two or more Profiles. |
|
Product of two or more Profiles. |
Transform
|
Transforms from spectral coefficients to real space values. |
VMEC
Performs input from VMEC netCDF files to DESC Equilibrium and vice-versa. |