PDA

View Full Version : Thoughts on Improving Autotune and calculating remainder values



Draco
February 6th, 2006, 09:12 AM
Hi folks,

First of all excuse the length of this post, just wondering about ways to improve the Autotune process. Specifically I'd like to reduce the number of iterations, need for smoothing, and increase accuracy of results. I realize the existing Autotune process works well enough over several iterations but if there is a better way I want to expore it.

Any ideas on how to calculate the remainder value for calculated PIDs? What I want to do is weight values that are closest to the VE table cell values heavily, and remove weighting from values that are close to borders between cells. I believe this can be used to more accurately calculate the final BEN values, and reduce the number of iterations required and the need to use smoothing.

An example: Take two cells at 45 MAP and 50 MAP (both at 2000 RPM). Give them values of 40% and 50% VE . If the car is cruising at 47.4 MAP and 2000 RPM and the BEN value is 1.05, then to my knowledge the BEN value result will affect the 45 MAP cell. I believe that this particular BEN value result should either be ignored completely (if we could filter this in our AutoTune Maps this would be great but I do not see how), or weighted very lightly using an improved calculated PID. My idea would be to calculate 47.4 Divided by 5, which would yield a remainder of 2.4. A 2.5 would be the worst possible remainder (ignore completely), with a 0.00 remainder being the best possible, since it sits squarely on a cell.

Now from here, we could have two options and not sure if either are possible.

Option 1 (Ideal but complicated):

So, looking at our initially counted BEN of 1.05, with a 2.4 remainder, I'd like to somehow reduce the weighting of this BEN value. Unfortunately, we cannot simply manipulate the BEN value because each BEN value is weighted the same when put into the average that gets displayed in the autotune Map. We would have to have the scanner keep track of a running BEN value for each cell in the VE table, and manipulate it after each cell is processed. Then at the end, output these values to a autotune map. I haven't thought of the formula yet, or how to track the hundreds of individual BEN numbers and I suck at math :).

Option 2 (simple but hopefully 90% as effective):
Use a map filter to ignore any cells with a remainder between a certain pair of values. Since a 2.5 remainder is the worst, an example would be to filter out cells with remainders greater then 2 and less then 3.

P.S. I realize we are dealing with a 2-dimensional map and that my example really only explores 1-D, but I wanted to keep my example simple. To handle 2-D we would use 2 remainder values and/or 2 'flags' per frame (1 for MAP and 1 for RPM).


So - any way to calculate remainders? :) If not with decimal numbers, how about with integers?

Cheers,

Craig