Induction motor control strategy  [SOLVED]

User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Induction motor control strategy

Post by catphish »

Is there any discussion I can read regarding the strategy that openinverter uses to control induction motors? I understand from the documentation that the strategy is to run the motor at a fixed slip, and control torque using voltage, up to 50% throttle, and after this, increase slip.

I am interested to know how this voltage based control of torque compares to a slip cased control of torque, where the full range of the throttle controls slip. I assume this is the result of years of Johannes's experience, but I'm interested to learn more about it.

My naive approach would be to control slip first, and then set voltage on a fixed curve. Sorry if this is a vague question with a complicated answer. I'm hoping something has already been written about all this that I can read.
User avatar
johu
Site Admin
Posts: 5682
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Induction motor control strategy  [SOLVED]

Post by johu »

Nope, not experience, just simple math ;)
Both, raising voltage and raising slip contributes to torque generation. But slip causes additional losses, a rough approximation is efficiency=100%-slip . Where slip in this case is expressed in percent of rotor speed. So say rotor speed is 100 Hz and slip is 1 Hz then slip causes 1% loss.

Therefor voltage is raised first, then slip.
Voltage can't be raised indefinitely because that will saturate the stator iron and cause ridiculous, useless current.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

Thank you. I will have another look at the maths, and I look forward to having a go at tuning my own motor and seeing what I find experimentally too.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

I've spend a few hours(!) reading up on this again. Information is annoyingly sparse on the subject of deliberate torque control of induction motors using voltage and slip control.

What I have found suggests that the optimum slip frequency increases along with current (in the ideal case, keeping slip angle constant). This certainly correlates with the fact that openinverter increases slip once torque/current increases beyond a certain point, but I'd expect this to hold true from 0A up to Imax. While it's certainly true that less slip is more efficient, I wonder if this is only because torque would also usually be less in this case.

Anyway, I'm new here, so I'm certainly not claiming an authority on this topic, and my own testing has never amounted to more than 250W, so just a thought!

This is the only real experimental data I could find on the subject - from this paper: https://www.researchgate.net/publicatio ... -_A_Review
Image

If you have any source for the maths you mentioned, I'll certainly go and read more.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

The more I read about this, the more I am convinced that for maximum efficiency, slip should scale linearly with demanded torque, and voltage should follow. I realise this is complicated topic and I may be mistaken! I'd love to talk about this all day, but instead, when I have an opportunity, I will test for myself and see how it compares.

* Slip = requested torque
* Voltage = v/Hz * stator frequency + boost (this boost may have a constant factor and a factor relative to slip)
User avatar
EV_Builder
Posts: 1199
Joined: Tue Apr 28, 2020 3:50 pm
Location: The Netherlands
Has thanked: 16 times
Been thanked: 33 times
Contact:

Re: Induction motor control strategy

Post by EV_Builder »

Given an inductance from the motor how fast are you out of voltage?
Only slip left to play with?
Converting an Porsche Panamera
see http://www.wdrautomatisering.nl for bespoke BMS modules.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

EV_Builder wrote: Wed Dec 15, 2021 10:29 am Given an inductance from the motor how fast are you out of voltage?
Only slip left to play with?
Yes. There are essentially 2 points at which you "run out of voltage":

1) The point at which there is not enough voltage to maintain maximum torque. Up to this point, at full throttle, torque is constant and power increases with RPM. Above this speed, the difference between back EMF generated by the motor, and the battery voltage is not enough to create maximum torque, but is still enough to create *some* torque. The magnetic fields gradually weaken above this speed. Above this point, torque gradually reduces but RPM continues to increase. You are then at maximum voltage and can control using slip frqeuency only.

2) The point where there is no longer enough voltage to generate enough torque to accelerate any faster further. When this occurs will depend on the load on the motor. With an unloaded motor this will far exceed the mechanical speed limits of the motor.

The tricky part is calculating the optimal voltage and slip for every possible throttle position and RPM. The only thing that's certain is that above a particular RPM, one can stop worrying about voltage, since it's maxed out.
User avatar
EV_Builder
Posts: 1199
Joined: Tue Apr 28, 2020 3:50 pm
Location: The Netherlands
Has thanked: 16 times
Been thanked: 33 times
Contact:

Re: Induction motor control strategy

Post by EV_Builder »

The tricky part is calculating the optimal voltage and slip for every possible throttle position and RPM.
Are you sure?
If RPM is the result of all parameters?
Isn't it optimal voltage and slip at certain load?
Converting an Porsche Panamera
see http://www.wdrautomatisering.nl for bespoke BMS modules.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

There are essentially 5 factors at work:
* Voltage - the magnitude of the sine wave applied to the motor - we can control this
* Frequency - the frequency of the sine wave applies to the motor - we can control this
* The speed of the motor - we can measure this but we can't control it
* Throttle position - a driver will expect this to control the torque of the motor
* The mechanical load on the motor, ie the force coming from the wheels

We cannot reasonably measure or predict the mechanical load. This is subject to change due to hills, air resistance, and who knows what else, so we ignore it.

Therefore, the goal is to use the 2 things we can measure (motor sped and throttle position), to set the 2 things we can control (voltage and frequency), in such a way as to make the motor torque proportional to the throttle position.

So the algorithm must take throttle position, and rpm and output voltage and frequency. For every throttle position and RPM combination, there will be an optimal combination of voltage and frequency that produces the desired torque with the minimal amount of electrical power.

Slip is just an expression of the difference between motor rpm and frequency, so we often talk about controlling slip rather than controlling frequency, but the 2 concepts are identical once you've done a simple addition.

There are a number of different ways to look at this, but at its simplest, you treat the AC motor like a DC motor, by giving some voltage to overcome the back EMF, and then some more voltage to create torque. Slip then needs to be set to make sure the motor is running efficiently, too much or too little will cause more energy to be wasted as heat.

With that in mind, the question can be rearranged as: what is the most efficient amount of slip for a given RPM and voltage. The answer is of course not simple.
User avatar
johu
Site Admin
Posts: 5682
Joined: Thu Nov 08, 2018 10:52 pm
Location: Kassel/Germany
Has thanked: 153 times
Been thanked: 960 times
Contact:

Re: Induction motor control strategy

Post by johu »

I think you're overcomplicating it (aka being very German about it) ;)
The question is also, what's in it? Even with the current "good enuff" algorithm we are reaching OEM like energy efficiency and little heating. For further improvement you'd need a test rig that can measure every .1% of improved efficiency because I think it's hard to beat your own confirmation bias when testing in a vehicle.

Ok, that was demotivating, actually I think it's very cool you're spending further thought on it. As Jon Volk has proven, things can still be improved even after 10 years.
Support R/D and forum on Patreon: https://patreon.com/openinverter - Subscribe on odysee: https://odysee.com/@openinverter:9
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

I'm glad you're getting such good results. I certainly don't want to criticize, as your algorithm is clearly working very well. I just thought it was interesting that we have come to different conclusions about the best approach. The other difference is that you have a lot of experience with real large motors, and I do not!

You're quite right that it will be difficult to measure efficiency with any degree of accuracy. I hope to spend some time testing soon, and will of course contribute if I find anything of value.
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Induction motor control strategy

Post by Peter »

Would the testing be possible by employing a motor coupled to a generator with an adjustable load. Monitoring the motor input power and generator output power? Depends on the type of motor being used too, what would be the best option ?
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

Peter wrote: Thu Dec 16, 2021 4:22 pm Would the testing be possible by employing a motor coupled to a generator with an adjustable load. Monitoring the motor input power and generator output power? Depends on the type of motor being used too, what would be the best option ?
Yes, this would be a great approach. Could potentially optimize both the motor and generator sides that way too, but I'm not sure if and when I'd have the opportunity to build such a setup!
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Induction motor control strategy

Post by Peter »

The motor type based on its frame is the issue unless a 3ph induction motor can be used or a suitable alternative found. Any ideas?
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

Best case scenario: I had the resources, my approach would be to set up 2 identical 3 phase induction motors, and 2 identical inverters, run one with positive torque, and the other with negative torque (regen). This would allow tuning both modes, and give plenty of control over the parameters of the tests.
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Induction motor control strategy

Post by Peter »

I have one Enova 90kw motor and no doubt someone else will have one lying around but their efficiency may be well below anything we use i.e. Tesla
That’s where the issue lies for my thinking, the technology
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Induction motor control strategy

Post by Peter »

Let’s say we have two Tesla SDU complete. Lock one side of the diff output on each and connect both SDU via the unlocked diff outputs. One then run as a motor the other as regen as you suggest. Use one set of batteries and both SDU utilise those. I guess that would be the ideal?
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

That sounds like a good setup. You'd of course also need the will to actually do the tuning!
User avatar
Peter
Posts: 310
Joined: Fri Dec 14, 2018 9:07 pm
Location: North West Lancs, UK
Been thanked: 8 times

Re: Induction motor control strategy

Post by Peter »

And raid the beer fund for the parts !
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

I've written my (completely speculative) control strategy into some code! Some key concepts:
  • Slip is always 100% proportional to throttle (positive or negative)
  • Rotor speed is calculated using a moving average over 256 PWM cycles (15ms) and added to slip to generate stator frequency. It's s shame that the low resolution of the encoder necessitates this.
  • Voltage is proportional to stator frequency (no boost yet, but assume some will be needed, ideally proportional to throttle)
  • There is no explicit concept of stopped, forward, reverse, or regen. These are all dynamically created based on the rules above, with the aim of being completely stateless and avoiding any sharp transition.
  • The unusual state 0v 0Hz is considered as valid as any other and will not shut down the inverter.
  • There is no regen yet, apart from a fixed 1Hz "engine braking". However, i hope that regen can be created simply by commanding throttle in the opposite direction to the rotor's current rotation.
  • All calculations are carried out on every PWM cycle
  • Obvious lack of web interface, contactor control, temperature monitoring, etc right now!
Now, the bad news is that I haven't tested this at all! I hope to do so, but for now I'm quite apprehensive of doing so, and my day time, when I have access to the SDU, I'm busy with mechanical work. However I thought I'd post it for general interest and comment!

https://github.com/catphish/sdu-basic/b ... ter/main.c
User avatar
EV_Builder
Posts: 1199
Joined: Tue Apr 28, 2020 3:50 pm
Location: The Netherlands
Has thanked: 16 times
Been thanked: 33 times
Contact:

Re: Induction motor control strategy

Post by EV_Builder »

catphish wrote: Sun Apr 17, 2022 12:44 am
  • There is no regen yet, apart from a fixed 1Hz "engine braking". However, i hope that regen can be created simply by commanding throttle in the opposite direction to the rotor's current rotation.
  • All calculations are carried out on every PWM cycle
Now, the bad news is that I haven't tested this at all! I hope to do so, but for now I'm quite apprehensive of doing so, and my day time, when I have access to the SDU, I'm busy with mechanical work. However I thought I'd post it for general interest and comment!

https://github.com/catphish/sdu-basic/b ... ter/main.c
This point feels to violate other points and I think it's incorrect. Regen is a lower Freq. (Negative Slip) then the engine is doing. With PWM we have fine control over power amount. Slip feels as a course parameter.

I think that one of the most important things is that what ever parameter is changed its changed with a slow S curve (internally). In that way the engine operates smooth.

So if you ask me we need a operational/active parameter layer, then a layer of parameter smoothness(change over time) and then a layer of the user/operational parameter.

If we build it this way up we can choose with different strategies how to forward parameters into the operation. It always could be 1:1 (like pass through)
Converting an Porsche Panamera
see http://www.wdrautomatisering.nl for bespoke BMS modules.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

EV_Builder wrote: Sun Apr 17, 2022 6:41 am This point feels to violate other points and I think it's incorrect. Regen is a lower Freq. (Negative Slip) then the engine is doing. With PWM we have fine control over power amount. Slip feels as a course parameter.
You're correct that this fixed 1Hz is extremely crude. It doesn't really fit with the rest of the scheme and should not need to be there. Regen should instead by created by negative torque request (ie negative throttle).

However your comment has also made me realise something more unpleasant. The low resolution of the encoder means that even with the smoothing I do, the rotational speed of the motor is only accurate to 1Hz. This means the slip will oscillate by 1Hz, which is a fairly serious problem because voltage follows slip, and 1Hz is about 20% throttle!

In *theory* slip is an extremely precise parameter, but in reality, it may not be possible to use it as such. Sadly I think it is therefore clear that voltage needs to be somewhat decoupled from frequency to avoid these oscillations.
EV_Builder wrote: Sun Apr 17, 2022 6:41 am I think that one of the most important things is that what ever parameter is changed its changed with a slow S curve (internally). In that way the engine operates smooth.

So if you ask me we need a operational/active parameter layer, then a layer of parameter smoothness(change over time) and then a layer of the user/operational parameter.
I absolutely agree there should be multiple layers, at least user input (the translation of throttle position to requested torque), and motor control (the translation of requested torque to voltage and frequency). These serve different purposes and should ideally be configured separately (as is already the case in openinverter).

Smoothing is a more complicated question. The best case scenario would actually be no smoothing at all on the motor control, because the optimal output depends on the instantaneous state of the motor (which is already smooth because of mechanical inertia). However, the reality is much more complicated, mostly because of the problem of the low resolution encoder input discussed above, which makes it impossible to know the instantaneous speed of the rotor.

With all of the above in mind, I might go back and look at the scheme again and see what other methods I can use to maintain a smooth current. I previously did this successfully by measuring the current and applying negative feedback to the voltage, however that's completely different to what I was proposing in this thread, which is interesting in theory, but I fear may have to be written off due to practical limitations.

Thanks!
User avatar
EV_Builder
Posts: 1199
Joined: Tue Apr 28, 2020 3:50 pm
Location: The Netherlands
Has thanked: 16 times
Been thanked: 33 times
Contact:

Re: Induction motor control strategy

Post by EV_Builder »

What makes you think that the encoder isn't of a high resolution enough?

It's quadruple.

How many PPR does it has?
Converting an Porsche Panamera
see http://www.wdrautomatisering.nl for bespoke BMS modules.
User avatar
catphish
Posts: 954
Joined: Fri Oct 08, 2021 11:02 pm
Location: Dorset, UK
Has thanked: 93 times
Been thanked: 179 times

Re: Induction motor control strategy

Post by catphish »

EV_Builder wrote: Sun Apr 17, 2022 12:21 pm What makes you think that the encoder isn't of a high resolution enough?

It's quadruple.

How many PPR does it has?
It has 36 teeth. That means 144 increments per revolution, or 72 per sine wave period. This is enough to keep the output in sync, but only to an accuracy of about 1Hz (assuming 10ms period of calculation).

PS. this really only matters if you are trying to use the frequency to set the voltage as I am.
User avatar
EV_Builder
Posts: 1199
Joined: Tue Apr 28, 2020 3:50 pm
Location: The Netherlands
Has thanked: 16 times
Been thanked: 33 times
Contact:

Re: Induction motor control strategy

Post by EV_Builder »

This picture gives me the idea that the encoder is driven with a ratio in relation to the motor?
Screenshot_2022-04-17-15-26-19-76_40deb401b9ffe8e1df2f1cc5ba480b12.jpg
Converting an Porsche Panamera
see http://www.wdrautomatisering.nl for bespoke BMS modules.
Post Reply