pleiades.CurrentArray

class pleiades.CurrentArray(**kwargs)[source]

A rectangular current array

Parameters:
  • loc (tuple, optional) – The (R, Z) location of the centroid of the CurrentArray. Defaults to (1.0m, 1.0m).
  • current (float, optional) – The current in each current of the CurrentArray in amps (i.e power supply current). Defaults to 1 amp.
  • nr (float, optional) – The number of current filaments in the R direction. Defaults to 10.
  • nz (float, optional) – The number of current filaments in the Z direction. Defaults to 10.
  • dr (float, optional) – The distance between current filaments in the R direction. Defaults to 0.01 m
  • dz (float, optional) – The distance between current filaments in the Z direction. Defaults to 0.01 m
  • angle (float, optional) – The angle of the CurrentArray if it is not aligned with the RZ coordinate system. The angle is measured in degrees from the z axis. Defaults to 0 degrees.
  • patchcls (matplotlib.patches.Patch type) – The patch object class representing the CurrentArray for plotting
Variables:
  • loc (tuple) – The (R, Z) location of the centroid of the CurrentArray. Defaults to (1.0m, 1.0m).
  • current (float) – The current in each current of the CurrentArray in amps (i.e power supply current). Defaults to 1 amp.
  • nr (float) – The number of current filaments in the R direction. Defaults to 10.
  • nz (float) – The number of current filaments in the Z direction. Defaults to 10.
  • dr (float) – The distance between current filaments in the R direction. Defaults to 0.01 m
  • dz (float) – The distance between current filaments in the Z direction. Defaults to 0.01 m
  • angle (float) – The angle of the CurrentArray if it is not aligned with the RZ coordinate system. The angle is measured in degrees from the z axis. Defaults to 0 degrees.
  • obj_list (list) – The list of Current objects that comprise the CurrentArray
  • rzdir (np.array) – An Nx3 array whos rows are rzdir[i, :] = rloc, zloc, current which describe the current location and current value for each current in the CurrentArray
  • patchcls (matplotlib.patches.Patch type) – The patch object class representing the CurrentArray for plotting
  • patch (matplotlib.patches.Patch object) – The patch object representing the CurrentArray for plotting
  • patchkwargs (dict) – The keyword arguments used for the patch attribute
build_patchargs(**kwargs)[source]

Build argument tuple for patchcls

rotate(angle)[source]

Rotate the CurrentArray by a given angle around the centroid

Parameters:angle (float) – The angle of the rotation in degrees as measured from the z axis
to_dict()[source]

Represent the CurrentArray with a dictionary

translate(dr, dz)[source]

Translate the CurrentArray by the vector (dr, dz)

Parameters:
  • dr (float) – The displacement in the R direction for the translation
  • dz (float) – The displacement in the Z direction for the translation
update_patch()[source]

Update the patch for the CurrentArray