ElmerCSC / elmer-elmag

Development repository for electromagnetics tutorial and verification cases
45 stars 20 forks source link

Interior Permanent Magnet Motor Example #12

Closed mon-kev closed 1 year ago

mon-kev commented 1 year ago

Hi,

@raback asked me to share the example I have created for simulating an Interior Permanet Magnet motor in Elmer together with the help of @db434, @tpgillam and @eva-knight.

I set up the same simulation in Ansys Maxwell and the results for torque and core loss are matching reasonably well (view README).

I got a couple of comments/questions related to this case:

Thanks Kevin

jvela018 commented 1 year ago

Hi @mon-kev ,

The circuit in the InductionMachine2D example, should not be used as a circuit example. The reason is that it's hard to make a description of that circuit in term of their nodal connections. The circuit is defined in terms of loops. Long story short, the method used to generate that circuit is loop based (and dated pre-CircuitBuilder), and the one of the circuit builder is nodal based. The latter (nodal base) is comparable to describing a circuit like you'd do it on paper or as schematics.

I would use this as a more suitable example: 2D stranded circuit - conductors connected in series . Note that in the example we have two ElmerComponents. This is similar to the idea you'd do in an electrical machine where one of the coils would be in one direction and the other would be the return path. See main.py under the example.

Here's an explanation on how to use the CircuitBuilder: https://www.youtube.com/watch?v=Z_MBIt1pApU&t=2252s

If you're still struggling with this let me know and maybe I can offer you some additional help.

BR,

Jon

cc @raback

mon-kev commented 1 year ago

Hi @jvela018,

Thanks for sharing this.

In the example you shared the positive and negative coil are both modelled in Elmer. In my model only the positive (or negative) coil is modelled for each phase. Is it still possible to use the CircuitBuilder in this case or do I have to model 180° instead of 90° so I get a return coil for every phase? If it is possible without changing the periodicity: How would I have to adjust the circuit?

Thanks Kevin

jvela018 commented 1 year ago

Hi @mon-kev ,

I'm not available for most of this month. To help you in depth. I don't know if there's any sense of urgency here so I'll leave you with some pointers, and if when I get back from my holidays you're still struggling with this I can try to figure it out together with you. Here are my pointers with respect to your questions/concerns:

1) Is it still possible to use the CircuitBuilder in this case or do I have to model 180° instead of 90° so I get a return coil for every phase?

You can still use the circuit builder without needing to model half of your model. I'd suggest looking into the circuit related models in the CircuitBuilder repo. For example here we have how to set up a Voltage source https://github.com/ElmerCSC/elmer-elmag/tree/main/CircuitBuilder/2D/circuit_examples/voltage_source . Sure, it works with Massive conductors, but that you'd have to change to Stranded to suit your model. Note that this is a single Voltage source, if you've got a three phase machine, you'll have adapt it accordingly. Let us say your source supply is a Y-connected, you only have to create a single common node, and apply the phase shift on each V() in the python script (0, -120 and 120).

2) If it is possible without changing the periodicity: How would I have to adjust the circuit?

The periodicity is obtained simply by applying the same boundary conditions as you saw in the 2D induction machine model. However, the circuit will probably have to be scaled by the amount of slots. This part I'm not completely sure how it should be, however my guess is:

AND/OR

To figure it out, it's best to start with a simpler model. My suggestion would be the following:

Since this model works and we know the values we should get, I'd suggest re-creating this model using half of the model. Then if you get the same torque, and so on, you can for sure know how the scaling works and use the circuit directly on a model of your own.

I hope this helps. Let me know if you're able to do this and perhaps share it with us so that we can help others in the future. If you can't do this. I'll give this a show when I'm back form my holidays.

BR,

Jon

mon-kev commented 1 year ago

Hi @jvela018,

Thanks for sharing the resources. This is not particularly urgent right now, it's more of a nice to have. When I find the time, I'll do what you recommended and see if I can get this to work for this machine. If so, I'll create a new PR with the changes.

Thanks Kevin