desc.coils.MixedCoilSet
- class desc.coils.MixedCoilSet(*coils, name='')Source
Set of coils or coilsets of different geometry.
- Parameters:
coils (Coil or array-like of Coils) – Collection of coils.
name (str) – Name of this CoilSet.
Methods
append
(value)S.append(value) -- append value to the end of the sequence
clear
()compute
(names[, grid, params, transforms, data])Compute the quantity given by name on grid, for each coil in the coilset.
compute_Bnormal
(surface[, eval_grid, ...])Compute Bnormal from self on the given surface.
compute_magnetic_field
(coords[, params, ...])Compute magnetic field at a set of points.
copy
([deepcopy])Return a (deep)copy of this object.
count
(value)equiv
(other)Compare equivalence between DESC objects.
extend
(values)S.extend(iterable) -- extend sequence by appending elements from the iterable
flip
(*args, **kwargs)Flip the coils across a plane.
from_makegrid_coilfile
(coil_file[, method])Create a CoilSet of SplineXYZCoils from a MAKEGRID-formatted coil txtfile.
from_symmetry
(coils[, NFP, sym])Create a coil group by reflection and symmetry.
index
(value, [start, [stop]])Raises ValueError if the value is not present.
insert
(i, new_item)Insert a new coil into the coilset at position i.
linspaced_angular
(coil[, current, axis, ...])Create a coil set by repeating a coil n times rotationally.
linspaced_linear
(coil[, current, ...])Create a coil group by repeating a coil n times in a straight line.
load
(load_from[, file_format])Initialize from file.
pack_params
(params)Convert a list of dictionary of parameters into a single array.
pop
([index])Raise IndexError if list is empty or index is out of range.
remove
(value)S.remove(value) -- remove first occurrence of value.
reverse
()S.reverse() -- reverse IN PLACE
rotate
(*args, **kwargs)Rotate the coils about an axis.
save
(file_name[, file_format, file_mode])Save the object.
save_BNORM_file
(surface, fname[, basis_M, ...])Create BNORM-style .txt file containing Bnormal Fourier coefficients.
save_in_makegrid_format
(coilsFilename[, ...])Save CoilSet as a MAKEGRID-formatted coil txtfile.
save_mgrid
(path, Rmin, Rmax, Zmin, Zmax[, ...])Save the magnetic field to an mgrid NetCDF file in "raw" format.
to_FourierXYZ
([N, grid, s, name])Convert all coils to FourierXYZCoil representation.
to_SplineXYZ
([knots, grid, method, name])Convert all coils to SplineXYZCoil.
translate
(*args, **kwargs)Translate the coils along an axis.
Convert a single array of concatenated parameters into a dictionary.
Attributes
Number of (toroidal) field periods.
coils in the coilset.
currents in each coil.
total number of optimizable parameters.
list of dictionary of integers of sizes of each parameter.
Name of the curve.
string names of parameters that have been declared optimizable.
list of dictionary of arrays of optimizable parameters.
Whether this coil set is stellarator symmetric.
list of dict of arrays of idx for each param in concatenated array.