PMSM Simulation with Symmetry BC

Numerical methods and mathematical models of Elmer
Post Reply
zmladen
Posts: 43
Joined: 28 Apr 2013, 17:15
Antispam: Yes

PMSM Simulation with Symmetry BC

Post by zmladen »

Hello,

after reading both tutorials from Pavel, for a PMSM and IM i tried to model a PMSM with the 6 pole 9 slots configuration and symmetry boundary conditions. The static case looks good and the results are compatible with Ansys Maxwell (see images below). For static case please run "case_static.sif"
Stationary_B_field.png
Stationary_B_field.png (242.35 KiB) Viewed 1201 times
Ansys_Maxwell_transent.png
Ansys_Maxwell_transent.png (79.09 KiB) Viewed 1201 times
In case of the transient simulation (case_transient_MUMPS.sif) the results, based on the flux density and field lines distribution seem to be wrong. It looks like the flux lines are retreating from the permanent magnet area after some simulation time.
Transient_result_with_field_lines_jumping.jpg
Transient_result_with_field_lines_jumping.jpg (125.65 KiB) Viewed 1201 times
What am I doing wrong? I am using the current version of the elmerFEM 9.0. The simulations are running on the ubuntu virtual machine.

Thanks,
Mladen
zmladen
Posts: 43
Joined: 28 Apr 2013, 17:15
Antispam: Yes

Re: PMSM Simulation with Symmetry BC

Post by zmladen »

Here the missing model files.
Attachments
pmsm_symm_project.zip
(256.28 KiB) Downloaded 105 times
kevinarden
Posts: 2310
Joined: 25 Jan 2019, 01:28
Antispam: Yes

Re: PMSM Simulation with Symmetry BC

Post by kevinarden »

Have you checked the boundary target numbers using something like ElmerGUI? I don't understand why boundary 6 is mortared to boundary 7.
bc6.png
(344.23 KiB) Not downloaded yet
bc7.png
(259.82 KiB) Not downloaded yet
BC 4 targets boundary 6 and mortars it to BC 5 which is targeted to boundary 7
zmladen
Posts: 43
Joined: 28 Apr 2013, 17:15
Antispam: Yes

Re: PMSM Simulation with Symmetry BC

Post by zmladen »

Yes, I have checked the boundaries using ElmerGUI. Boundary 6 is a so-called master of the rotor and boundary 7 is the slave boundary where the values are projected. I have the same pair of boundaries on the stator side as well. I used the induction machine example form Pavel as a reference.

Mladen
raback
Site Admin
Posts: 4827
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: PMSM Simulation with Symmetry BC

Post by raback »

Hi,

This sounds funny. Maybe you could try to analyze more closely where the time is consumed.

Is the number of nonlinear iterations increased, or the time used for linear solves increased? The assembly time should trivially decrease.

Basically the quadratic elements and mortars may not like each other that much. I would start from linear (and denser) mesh and go quadratic maybe using p-elements (p:2).

When your systems come bigger iterative solvers will beat the direct ones. This may still be faster with direct ones.

Particularly for iterative ones you could try adding "Mortar BCs Additive = Logical True" to mgdyn solver. This sums up the constraints related to same dof which makes sense usually but is not the default because backward compatibility issues.

-Peter
zmladen
Posts: 43
Joined: 28 Apr 2013, 17:15
Antispam: Yes

Re: PMSM Simulation with Symmetry BC

Post by zmladen »

Hello Perer,

you probably wanted to answer the post "PMSM Simulation Symmetric vs Full Model". I use direct solvers in both cases. In the case of the full model the mortar elements are used on the sliding boundary due to rotation as well. In the symm model additional mortar BC are used on the symmetry boundaries. In Maxwell the full model is much slower to calculate, so I expected to have the same result in elmer as well. What worries me is that the full model converges to ~10-7 after 5 iterations:

Code: Select all

ComputeChange: NS (ITER=5) (NRM,RELC): (  1.3283151     0.67824760E-07 ) :: mgdyn2d
whereas the symm model shows orders of 1.

Code: Select all

ComputeChange: NS (ITER=20) (NRM,RELC): ( 0.21519202E+10  1.9652685     ) :: mgdyn2d
I don't know if I am interpreting these messages the right way.

The problem in this post is that the model is not working properly using symmetry BC. Can someone check the model to see if the setup is right? The meshes are not confoming as advised in the previous posts.

Mladen
dapu
Posts: 19
Joined: 16 Jan 2022, 12:35
Antispam: Yes

Re: PMSM Simulation with Symmetry BC

Post by dapu »

Hi,

have you found out the reason for the problem of the periodic BC? I have the same problem. The first time step seems to be ok. But after the first step, I got the same behavior. It is decribed in this post. viewtopic.php?t=7680. Thanks.

Best Regards
Dapu
raback
Site Admin
Posts: 4827
Joined: 22 Aug 2009, 11:57
Antispam: Yes
Location: Espoo, Finland
Contact:

Re: PMSM Simulation with Symmetry BC

Post by raback »

Hi

Did you try to set "Mortar BCs Additive = Logical True" for the mgdyn solver.

Also, obviously the nonlinear system is not converging.

Code: Select all

ComputeChange: NS (ITER=20) (NRM,RELC): ( 0.21519202E+10  1.9652685     ) :: mgdyn2d
This means that your L2 norm is almost 1e10 and relative change between iterations is ~2 i.e. not good ;-) Try to set "Nonlinear System Relaxation Factor" to 0.5--0.7 or so.

-Peter
Post Reply