MagnetType11 (class)

Method code available at https://github.com/Eomys/pyleecan/tree/master/pyleecan/Methods/Machine/MagnetType11

class MagnetType11(Wmag=0.002, Hmag=0.001, mat_type=-1, type_magnetization=0, Lmag=0.95, init_dict=None, init_str=None)[source]

Bases: pyleecan.Classes.MagnetPolar.MagnetPolar

single magnet with polar shape

VERSION = 1
IS_FLAT_BOT = 0
IS_FLAT_TOP = 0
build_geometry(alpha=0, delta=0, is_simplified=False)

Compute the curve (Segment, Arc1) needed to plot the Magnet. The list represents a closed surface. The ending point of a curve is always the starting point of the next curve in the list

Parameters
  • self (Magnet_Type_11) – A Magnet_Type_11 object

  • alpha (float) – Angle for rotation [rad]

  • delta (complex) – Complex value for translation

  • is_simplified (bool) – True to avoid line superposition

Returns

surf_list – list of surfaces needed to draw the magnet

Return type

list

comp_height()

Compute the height of the magnet

Parameters

self (MagnetType11) – A MagnetType11 object

Returns

Hmag – The magnet’s height [m]

Return type

float

comp_surface()

Compute the Magnet surface (by numerical computation)

Parameters

self (MagnetType11) – A MagnetType11 object

Returns

S – Magnet surface [m**2]

Return type

float

save(save_path='', is_folder=False)

Save the object to the save_path

Parameters
  • self – A pyleecan object

  • save_path (str) – path to the folder to save the object

  • is_folder (bool) – to split the object in different files: separate simulation machine and materials

copy()

Return a copy of the class

get_logger()

Get the object logger or its parent’s one

Parameters

obj – A pyleecan object

Returns

logger – Pyleecan object dedicated logger

Return type

logging.Logger

as_dict()[source]

Convert this object in a json seriable dict (can be use in __init__)

property Wmag

magnet bottom width [rad]

Type

float

Min

0

property Hmag

magnet radial height [m]

Type

float

Min

0