Borrar filtros
Borrar filtros

Weighted spline for calculating trajectory with lowest possible lateral acceleration

3 visualizaciones (últimos 30 días)
I have the following five vectors of equal length for a road user travelling on a specific path:
t: time point (s)
(x,y): position (m)
v: speed (m/s)
e: estimation, boolean. If 0, the values in the data point (t,x,y,v) are more accurate
I want to create a trajectory for the positions and with an overall small lateral acceleration (a = v^2 / r).
The estimated points should have a lower weight than the other points.
Is there a function available in Matlab for this task?
Thans in advance,
  3 comentarios
Sava Iancovici
Sava Iancovici el 25 de Feb. de 2019
I cound't get spap2, but I hope to be able to use this function:
[v,p,V,VAR,CI] = csapsGCV(x,y,p,xx,W)
Here, the W should be a vector of the standard deviations associated with the oberserved variables. So,as you mentioned, I need to convert 0/1 to standard deviations. In some datasets there are gaps due to missing datapoints, so maybe the inverse of the distance to the nearest gap could be used for these data sets.
Bjorn Gustavsson
Bjorn Gustavsson el 25 de Feb. de 2019
Well if you have completely missing data-points, then I think you should simply remove them from both x and y, since they should have no influence on the fitting curve at all. The weights W should be the standard deviation (or standard deviation squared, or the inverse of that, I don't have the csapsGVC function).

Iniciar sesión para comentar.

Respuestas (2)

Greg Dionne
Greg Dionne el 25 de Feb. de 2019
I'm not certain if I understood your question correctly, but you could try adapting the approach in the drivingScenario trajectory method if you have the Automated Driving Toolbox.
That uses a clothoid curve interpolant, which I think may be what you are after.

Sava Iancovici
Sava Iancovici el 26 de Feb. de 2019
Thanks fo the input.
I want to find a simple function for the "standard deviation" as an increasing function of the lateral accelerarion without downloading toolboxes etc.
In the example below, the standard deviation should be much higher for the point ((x,y) where the corresponding acceleration has a high peak.
My idea is that if the lateral acceleration in a specific point is equal or very close to the average value in the data set (all points in all trajectories), the standard deviation is set to 1 in that point. The standard deviation could e.g. be a staircase function with a constant value for lateral accelerations in a certain interval.


Más información sobre Spline Postprocessing en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by