How to find a function from real data?

  • Thread starter Thread starter DrummingAtom
  • Start date Start date
  • Tags Tags
    Data Function
AI Thread Summary
To find a function representing car velocity from real data, piecewise quadratic functions are a viable approach, especially as velocity changes with gear shifts. Analyzing the data's derivatives can provide insights into acceleration patterns, which may lead to linear or cubic models for velocity. It's common in various fields to fit functions to data by adjusting parameters based on expected distributions, like Gaussian for height measurements. While a non-piecewise function may be challenging to derive, exploring combinations of linear and periodic functions could yield useful approximations. Overall, modeling velocity accurately requires careful analysis of the underlying data trends and behaviors.
DrummingAtom
Messages
657
Reaction score
2
I was driving the other day and thought how I could find the function of my velocity. This would be a rough sketch of data from the velocity of the car. What method could I use to create a function from that graph?

I could assume that the concave parts are x2 then separate them from the flatter parts. That would give me a piecewise function but is there a way to combine all the functions into one?

I drew the red line (y = x) in because that seems like a close approximation. I have learned power and Taylor series but anytime I used those I already knew the function and then came up with the series by taking derivatives. I guess this is more of the numbers only flavor. Any help would be appreciated, thanks.
 

Attachments

  • CarVelocity.jpg
    CarVelocity.jpg
    5.9 KB · Views: 456
Mathematics news on Phys.org
This sort of analysis is carried out all the time in many subjects (physics, economics, cognitive science, etc.), hence there are multiple techniques. Generally in physics, one at least has an idea of the form of the function and therefore just plays with the parameters until a good fit to the data is found. For example, if I measured the height of everyone in a large classes, I would expect the distribution of their height to follow a Gaussian function, so my two parameters are the mean and standard deviation. Then I could change those until I found a good fit to my data. (Of course, there are better ways to find the parameters than manually changing them.)

I think you are on the right course by trying to model this as piecewise quadratic functions. From your data, it looks like you are changing to progressively higher gears. Each time you do, your acceleration drops to zero (giving a relatively constant velocity for awhile) then begins to increase as the engine gets up to speed.

One useful thing you could do to get a better idea of what is going on is to take the derivative of your data to get the acceleration. Maybe you'll find the acceleration in each gear is a linear function, in which case the use of quadratics for velocity is justified (the integral of a linear acceleration will give you a quadratic velocity). Or maybe you'll find you have to take the derivative of your data again before getting a linear function, in which case your velocity would be best modeled as piecewise cubic functions. Yet perhaps you'll never get a linear function no matter how many derivatives you take, in which case it's more complicated. I don't know how the power output of an engine changes as it gets up to speed.

I doubt you'll be able to get a non-piecewise function that describes this, but you can certainly try. It looks like a linear function multiplied by some kind of periodic function.
 
Suppose ,instead of the usual x,y coordinate system with an I basis vector along the x -axis and a corresponding j basis vector along the y-axis we instead have a different pair of basis vectors ,call them e and f along their respective axes. I have seen that this is an important subject in maths My question is what physical applications does such a model apply to? I am asking here because I have devoted quite a lot of time in the past to understanding convectors and the dual...
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Back
Top