Accel curve help needed by math wiz.
T Chap
Posts: 4,223
I have been searching here and google for a while with no luck finding accel formulas that could easily apply (no extra cogs for float) to fix this curve shown below.
Can anyone suggest a quick easy formula to adjust fix the red curve to look more like the blue one?
The idea is, the fix needs to be spread over 4320 loops, and maintain the same start value(0) and end value(MaxSpeed) so that the curve still ends up at the same place at the same time it always did to preserve the profile.
It seems if there is no better way to fix the main curve, then the offset would simply count up to some number, then count back down, possibly even into the negative to retain the same MaxSpeed/Time end point.
Post Edited (Originator) : 10/25/2008 10:31:12 PM GMT
Can anyone suggest a quick easy formula to adjust fix the red curve to look more like the blue one?
The idea is, the fix needs to be spread over 4320 loops, and maintain the same start value(0) and end value(MaxSpeed) so that the curve still ends up at the same place at the same time it always did to preserve the profile.
It seems if there is no better way to fix the main curve, then the offset would simply count up to some number, then count back down, possibly even into the negative to retain the same MaxSpeed/Time end point.
Post Edited (Originator) : 10/25/2008 10:31:12 PM GMT
Comments
·
This is an image of x2 and x1/2 . The former is on the bottom, and the latter is above. I may be able to come up with a solution on how to convert, but it will take a little while.
Post Edited (SRLM) : 10/26/2008 12:54:24 AM GMT
This is crude but effective to put the curve on the top side.
So, that said, let's begin.
You have two curves:
The given curve: xn = c
The desired curve: x1/n = a
Where c and a are the values given at point x (the point in your sample list)
So to convert, just use x 1 / logxc· to get the value that you want.
I'll give an example of how to use it:
And, truth be told, I mostly looked at your graph, and skimmed over the rest. Without the full background, it's difficult to make the project in my mind. But, with the graph I can still do the math. [noparse]:)[/noparse]
I have a better idea now, either predefine 10 reference points over the distance of the accel curve, or, define one point as the 'knee' and calculate the rest using a curve/angle value to determine the sharpness/roundness of the curve.
I like the idea much better to be able to semi-graphically define the curve, only in this case the graphic is on paper rather than a GUI.
Post Edited (Originator) : 10/26/2008 9:55:11 PM GMT
Actually the code above is what is working out fine for 10 predefined points, it take the 10 points and calculates the 10 ranges of offset values, there are no other if statements needed as the counter bumps up the index keeping everything working at the right time.
Thanks for the advice, very helpful.