The code for the algorithm has already been published at: "Peak Efficiency" Control Mode? - Page 10 - vedder.se forums

-------------------------

Efficiency Control Algorithm For BLDC Electric Motors Proof

The basic concept underlying the algorithm is there is always a ratio between electrical watts and mechanical watts which can be both calculated and manipulated.

For example if instantaneous values for one motor are the following, then electrical to mechanical conversion efficiency is 50%:

Electrical Watts: 500w

Mechanical Watts 250w

This ratio is represented by the equation:

(250/500)*100=50%

The discovery underlying the invention is that at each particular rpm, this ratio can be increased or decreased by applying more or less wattage at the same rpm.

As a result, a constant "desired efficiency" can be achieved by applying a different amount of electrical wattage at every RPM as the motor accelerates, by varying the "duty cycle" control variable.

It turns out that at very low rpms, lower wattage must be applied to maintain a "constant efficiency" value compared to when the motor is spinning faster.

So I begin the mathematical scenario as follows (& these values are numerically close to the values of the motors under development at SteelHubs.com):

Suppose I have a BLDC motor that is 93kv (93 rpm per applied volt), with 0.09ohm resistance lead-to-lead. If the motor is turning at 2000rpm, and I want an exactly 80% conversion efficiency of electrical to mechanical watts, then exactly how many electrical watts must I apply to the motor to achieve the 80% conversion efficiency?

The method of answering this question is the "heart" of my algorithm (with additional features added in to make it more "practically usable" -- such as throttle control and wattage limits, etc).