Main Content

singermeas

Measurement function for Singer acceleration motion model

Since R2020b

Description

measurement = singermeas(state) returns the expected measurement for state based on the Singer acceleration motion model, which assumes the target acceleration decays over time. You can also use it as a measurement function in a Kalman filter. The states argument specifies the current states.

example

measurements = singermeas(state,frame) specifies the measurement output coordinate system, frame.

measurement = singermeas(state,frame,sensorpos,sensorvel) also specifies the sensor position, sensorpos, and the sensor velocity, sensorvel.

measurement = singermeas(state,frame,sensorpos,sensorvel,laxes) specifies the local sensor axes orientation, laxes.

measurement = singermeas(state,measurementParameters) specifies the measurement parameters, measurementParameters.

[measurement,bounds] = singermeas(___) returns the measurement bounds, used by a tracking filter (trackingEKF, trackingUKF, trackingCKF,trackingIMM, trackingMSCEKF, or trackingGSF) in residual calculations.

example

Examples

collapse all

Define a state for a 2-D Singer acceleration motion.

state = [1;10;3;2;20;5];

Obtain the measurement in a rectangular frame.

measurement = singermeas(state)
measurement = 3×1

     1
     2
     0

Obtain the measurement in a spherical frame.

measurement = singermeas(state, 'spherical')
measurement = 4×1

   63.4349
         0
    2.2361
   22.3607

Obtain the measurement in a spherical frame relative to a stationary sensor located at [1;-2;0].

measurement = singermeas(state, 'spherical', [1;-2;0], [0;0;0])
measurement = 4×1

    90
     0
     4
    20

Obtain the measurement in a spherical frame relative to a stationary sensor located at [1;-2;0] that is rotated by 90 degrees around the z axis relative to the global frame.

laxes = [0 -1 0; 1 0 0; 0 0 1];
measurement = singermeas(state, 'spherical', [1;-2;0], [0;0;0], laxes)
measurement = 4×1

     0
     0
     4
    20

Obtain measurements from multiple 2D states in a rectangular frame.

states = [1 2 3; 10 20 30; 2 4 5; 20 30 40; 5 6 11; 1 3 1.5];
measurements = singermeas(states)
measurements = 3×3

     1     2     3
    20    30    40
     0     0     0

Specify a 2-D state and specify a measurement structure such that the function outputs azimuth, range, and range-rate measurements.

state = [10 1 0 10 1 0]'; % [x vx ax y vy ay]'
mp = struct("Frame","Spherical", ...
    "HasAzimuth",true, ...
    "HasElevation",false, ...
    "HasRange",true, ...
    "HasVelocity",false);

Output the measurement and wrapping bounds using the singermeas function.

[measure,bounds] = singermeas(state,mp)
measure = 2×1

   45.0000
   14.1421

bounds = 2×2

  -180   180
  -Inf   Inf

Input Arguments

collapse all

Current state for Singer acceleration motion model, specified as a real-valued 3N-by-1 vector or a real-valued 3N-by-M matrix. N is the spatial degree of the state, and M is the number of states.

The state vector in each column takes different forms based on its spatial dimensions.

Spatial DegreesState Vector Structure
1-D[x;vx;ax]
2-D[x;vx;ax;y;vy;ay]
3-D[x;vx;ax;y;vy;ay;z;vz;az]

For example, x represents the x-coordinate, vx represents the velocity in the x-direction, and ax represents the acceleration in the x-direction. If the motion model is in one-dimensional space, the y- and z-axes are assumed to be zero. If the motion model is in two-dimensional space, values along the z-axis are assumed to be zero. Position coordinates are in meters. Velocity coordinates are in meters/second. Acceleration coordinates are in m/s2.

Example: [5;0.1;0.01;0;-0.2;-0.01;-3;0.05;0]

Frame to report measurements, specified as 'rectangular' or 'spherical'. When you specify frame as 'rectangular', a measurement consists of x, y, and z Cartesian coordinates. When you specify frame as 'spherical', a measurement consists of azimuth, elevation, range, and range rate.

Data Types: char | string

Sensor position with respect to the navigation frame, specified as a real-valued 3-by-1 column vector. Units are in meters.

Data Types: single | double

Sensor velocity with respect to the navigation frame, specified as a real-valued 3-by-1 column vector. Units are in m/s.

Data Types: single | double

Local sensor axes coordinates, specified as a 3-by-3 orthogonal matrix. Each column specifies the direction of the local x-, y-, and z-axes, respectively, with respect to the navigation frame. The matrix is the rotation matrix from the global frame to the sensor frame.

Data Types: single | double

Measurement parameters, specified as a structure or an array of structures. For more details, see Measurement Parameters.

Data Types: struct

Output Arguments

collapse all

Measurement vector, returned as an N-element real-valued row vector or an M-by-N real-valued matrix. M, the size of each measurement, can vary depending on the syntax. For more information, see the following table. N, the number of measurements, is the same as the number of states. The format of the measurement vector depends on the syntax.

  • When you do not specify the measurementParameters argument and set the frame argument to 'rectangular', the function outputs measurement vectors in the format of [x;y;z].

  • When you do not specify the measurementParameters argument and set the frame argument to 'spherical', the function outputs measurement vectors in the format of [az;el;r;rr].

  • When you specify the measurementParameters argument and set the frame field to 'rectangular', the size of the measurement vector depends on the value of the HasVelocity field in the measurementParameters structure. The measurement vector includes the Cartesian position and velocity coordinates of the tracked object with respect to the ego vehicle coordinate system.

    Rectangular Measurements

    HasVelocity = 'false'[x;y;z]
    HasVelocity = 'true'[x;y;z;vx;vy;vz]

    Position units are in meters and velocity units are in m/s.

  • When you specify the measurementParameters argument and set the frame field to 'spherical', the size of the measurement vector depends on the value of the HasVelocity, HasRange, and HasElevation fields in the measurementParameters structure. The measurement vector includes the azimuth angle, az, elevation angle, el, range, r, and range rate, rr, of the object with respect to the local ego vehicle coordinate system. Positive values for range rate indicate that an object is moving away from the sensor.

    Spherical Measurements

     HasRange = 'true'HasRange = 'false'
     HasElevation = 'false'HasElevation = 'true'HasElevation = 'false'HasElevation = 'true'
    HasVelocity = 'false'[az;r][az;el;r][az][az;el]
    HasVelocity = 'true'[az;r;rr][az;el;r;rr][az][az;el]

    Angle units are in degrees, range units are in meters, and range rate units are in m/s.

Data Types: double

Measurement residual wrapping bounds, returned as a two-element real-valued row vector or an M-by-2 real-valued matrix, where M is the size of each measurement. Each row of the matrix corresponds to the lower and upper bounds, respectively, of each measurement in the measurement output.

The function returns different bound values based on the frame input.

  • If you specify frame as 'Rectangular', each row of the matrix is [-Inf Inf], indicating that the filter did not wrap the measurement residual.

  • If you specify frame as 'Spherical', the function returns bounds for each measurement based on the following:

    • When HasAzimuth = true, the matrix includes a row of [-180 180], indicating that the filter wrapped the azimuth residual in the range of [-180 180] in degrees.

    • When HasElevation = true, the matrix includes a row of [-90 90], indicating that the filter wrapped the elevation residual in the range of [-90 90] in degrees.

    • When HasRange = true, the matrix includes a row of [-Inf Inf], indicating that the filter did not wrap the range residual.

    • When HasVelocity = true, the matrix includes a row of [-Inf Inf], indicating that the filter did not wrap the range rate residual.

If you set any of the fields to false, the returned bounds do not contain the corresponding row. For example, if HasAzimuth = true, HasElevation = false, HasRange = true, HasVelocity = true, then the function returns the bounds as:

  -180   180
  -Inf   Inf
  -Inf   Inf

The filter wraps the measuring residuals based on this equation:

xwrap=mod(xab2,ba)+ab2

where x is the residual to wrap, a is the lower bound, b is the upper bound, mod is the remainder after division, and xwrap is the wrapped residual.

Data Types: single | double

More About

collapse all

References

[1] Singer, Robert A. "Estimating optimal tracking filter performance for manned maneuvering targets." IEEE Transactions on Aerospace and Electronic Systems 4 (1970): 473-483.

[2] Blackman, Samuel S., and Robert Popoli. "Design and analysis of modern tracking systems." (1999).

[3] Li, X. Rong, and Vesselin P. Jilkov. "Survey of maneuvering target tracking: dynamic models." Signal and Data Processing of Small Targets 2000, vol. 4048, pp. 212-235. International Society for Optics and Photonics, 2000.

Extended Capabilities

expand all

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

Version History

Introduced in R2020b