desc.basis.ZernikePolynomial
- class desc.basis.ZernikePolynomial(L, M, sym=False, spectral_indexing='ansi')Source
2D basis set for analytic functions in a unit disc.
- Parameters:
L (int) – Maximum radial resolution. Use L=-1 for default based on M.
M (int) – Maximum poloidal resolution.
sym ({
'cos','sin',False}) –'cos'for cos(m*t-n*z) symmetry'sin'for sin(m*t-n*z) symmetryFalsefor no symmetry (Default)
spectral_indexing ({
'ansi','fringe'}) –Indexing method, default value =
'ansi'For L=0, all methods are equivalent and give a “chevron” shaped basis (only the outer edge of the zernike pyramid of width M). For L>0, the indexing scheme defines order of the basis functions:
'ansi': ANSI indexing fills in the pyramid with triangles of decreasing size, ending in a triangle shape. For L == M, the traditional ANSI pyramid indexing is recovered. For L>M, adds rows to the bottom of the pyramid, increasing L while keeping M constant, giving a “house” shape.'fringe': Fringe indexing fills in the pyramid with chevrons of decreasing size, ending in a diamond shape for L=2*M where the traditional fringe/U of Arizona indexing is recovered. For L > 2*M, adds chevrons to the bottom, making a hexagonal diamond.
Methods
change_resolution(L, M[, sym])Change resolution of the basis to the given resolutions.
copy([deepcopy])Return a (deep)copy of this object.
equiv(other)Compare equivalence between DESC objects.
evaluate(nodes[, derivatives, modes, unique])Evaluate basis functions at specified nodes.
get_idx([L, M, N, error])Get the index of the
'modes'array corresponding to given mode numbers.load(load_from[, file_format])Initialize from file.
save(file_name[, file_format, file_mode])Save the object.
Attributes
Maximum radial resolution.
Maximum poloidal resolution.
Maximum toroidal resolution.
Number of field periods.
Mode numbers [l,m,n].
Total number of modes in the spectral basis.
Type of indexing used for the spectral basis.
Type of symmetry.