pleiades.Magnet¶
-
class
pleiades.Magnet(**kwargs)[source]¶ Represent a Rectangular cross-section dipole magnet with axisymmetric surface currents.
Parameters: - rz_pts (iterable, optional) – Nx2 iterable representing R,Z current centroids. Defaults to None
- current (float, optional) – The current in all the current ring in amps, defaults to 1 amp.
- kwargs (matplotlib patch keyword arguments) –
Variables: - loc (tuple) – The (R, Z) location of the centroid of the magnet.
- width (float, optional) – The width of the magnet. Defaults to 0.01 m.
- height (float, optional) – The height of the magnet. Defaults to 0.01 m.
- mu_hat (float, optional) – The angle of the magnetic moment of the magnet in degrees from the z axis. Defaults to 0 degrees clockwise from Z axis (i.e. north pole points in the +z direction).
- current_prof (integer or array_like) – The current profile along the side of the magnet. Defaults to np.ones(8) i.e. 8 equal surface currents per side.
- current (float) – The current in the magnet in amps.
- obj_list (list) – The list of Current objects that comprise the Magnet
- 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 Magnet
- patch (matplotlib.patches.Patch object) – The patch object representing the Magnet for plotting
- patchkwargs (dict) – The keyword arguments used for the patch attribute
-
rotate(angle)[source]¶ Rotate the magnet by a given angle around the magnet centroid
Parameters: angle (float) – The angle of the rotation in degrees as measured from the z axis