v_from_r

ssapy.utils.v_from_r(r, t)[source][source]

Calculate the velocity from position and time data.

Parameters:

r (ndarray): Array of position data with shape (N, D),

where N is the number of time steps and D is the number of dimensions.

t (array-like): Array of time data corresponding to the position data.

If the first element is of type Time, it will be converted to GPS time.

Returns:

ndarray: Array of velocity data with shape (N, D), calculated as the rate of change of position

over time. The last row of the velocity array is repeated to match the input shape.