Magnetics (class)

Method code available at https://github.com/Eomys/pyleecan/tree/master/pyleecan/Methods/Simulation/Magnetics

class Magnetics(is_remove_slotS=False, is_remove_slotR=False, is_remove_vent=False, is_mmfs=True, is_mmfr=True, type_BH_stator=0, type_BH_rotor=0, is_periodicity_t=False, is_periodicity_a=False, angle_stator_shift=0, angle_rotor_shift=0, logger_name='Pyleecan.Magnetics', init_dict=None, init_str=None)[source]

Bases: pyleecan.Classes._frozen.FrozenClass

Magnetic module abstract object

VERSION = 1
run()

Run the Magnetics module

comp_axes(output)

Compute the axes required in any Magnetics module

Parameters
  • self (Magnetic) – a Magnetic object

  • output (Output) – an Output object (to update)

Returns

axes_dict – Dict containing Time and Angle axes including (anti-)periodicties used in any Magnetics module

Return type

{Data}

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(**kwargs)

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

compare(other, name='self')[source]

Compare two objects and return list of differences

as_dict(**kwargs)[source]

Convert this object in a json serializable dict (can be use in __init__). Optional keyword input parameter is for internal use only and may prevent json serializability.

property is_remove_slotS

1 to artificially remove stator slotting effects in permeance mmf calculations

Type

bool

property is_remove_slotR

1 to artificially remove rotor slotting effects in permeance mmf calculations

Type

bool

property is_remove_vent

1 to artificially remove the ventilations duct

Type

bool

property is_mmfs

1 to compute the stator magnetomotive force / stator armature magnetic field

Type

bool

property is_mmfr

1 to compute the rotor magnetomotive force / rotor magnetic field

Type

bool

property type_BH_stator

0 to use the B(H) curve, 1 to use linear B(H) curve according to mur_lin, 2 to enforce infinite permeability (mur_lin =100000)

Type

int

Min

0

Max

2

property type_BH_rotor

0 to use the B(H) curve, 1 to use linear B(H) curve according to mur_lin, 2 to enforce infinite permeability (mur_lin =100000)

Type

int

Min

0

Max

2

property is_periodicity_t

True to compute only on one time periodicity (use periodicities defined in output.mag.Time)

Type

bool

property is_periodicity_a

True to compute only on one angle periodicity (use periodicities defined in output.mag.Angle)

Type

bool

property angle_stator_shift

Shift angle to appy to the stator in magnetic model

Type

float

property angle_rotor_shift

Shift angle to appy to the rotor in magnetic model

Type

float

property logger_name

Name of the logger to use

Type

str