-- Animación de un Generador de Corriente Alterna mediante FEMM. -- ACGenerator Animation by FEMM. -- -- Código creado por Sebastián Jardi Estadella -- Coded by Sebastián Jardi Estadella -- SEUTec -- http://www.tinet.cat/~sje/index_sp.htm -- sje@tinet.org -- dAlfa=5 -- Increase of Alfa ( Degrees of rotor rotation by step ) dAlfa=9 -- Reduce dAlfa to increase number of created images. -- dAlfa=18 -- dAlfa=36 -- dAlfa=45 -- dAlfa=90 -- dAlfa=180 open("ACGenerator.fem") mi_saveas("temp.fem") -- Temp file for save the original mi_seteditmode("group") for n=1,(180/dAlfa+1) do mi_analyse() mi_loadsolution() mo_showdensityplot(0,0,0.5,0,"mag") -- Obtain Image alfa=dAlfa*(n-1) mo_savebitmap(format("acgen_%1$d.bmp",alfa)) -- Save Image mo_close() mi_selectgroup(1) -- Select Rotor mi_move_rotate(0,0,dAlfa) -- Rotate the rotor end