summaryrefslogtreecommitdiff
path: root/MathSymbols.mdwn
blob: 6b19addeffa3eb1fb40faac9e9fec27442780c42 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
# Mathematical Symbols and Notation

([[See also our page on coordinate systems|CoordinateSystem]])

----

## Notation used in State Space control and Kalman filtering

The basic state space formulation of a dynamic system expresses the system as a linear first order differential equation with respect to time

- $$ \\bf\{x'\} = \\bf\{F\\ x\} + \\bf\{G\} \\pmatrix\{\\bf\{u\} \\cr \\bf\{w\}\} $$

or

- $$ \\bf\{x'\} = \\bf\{\\Phi\\ x\} + \\bf\{\\Gamma\} \\pmatrix\{\\bf\{u\} \\cr \\bf\{w\}\} $$

The first form is used for continuous time systems, the second form is usually reserved for systems modeled in discreet time.

**Summary of State Space Symbols**

<div>
  <table>
    <tbody>
      <tr>
        <td>
          <p><strong>Symbol</strong></p>
        </td>
        <td>
          <p><strong>Dimension</strong></p>
        </td>
        <td>
          <p><strong>Name</strong></p>
        </td>
      </tr>
      <tr>
        <td>
          <p><strong>x</strong></p>
        </td>
        <td>
          <p>n&times;1</p>
        </td>
        <td>
          <p>state vector</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><strong>F</strong></p>
        </td>
        <td>
          <p>n&times;n</p>
        </td>
        <td>
          <p>state transition matrix</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><big>&Phi;</big></p>
        </td>
        <td>
          <p>n&times;n</p>
        </td>
        <td>
          <p>discreet state transition matrix</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><strong>G</strong></p>
        </td>
        <td>
          <p>n&times;q</p>
        </td>
        <td>
          <p>input matrix</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><big>&Gamma;</big></p>
        </td>
        <td>
          <p>n&times;q</p>
        </td>
        <td>
          <p>discreet input matrix</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><strong>u</strong></p>
        </td>
        <td>
          <p>q<sub>u</sub>&times;1</p>
        </td>
        <td>
          <p>input vector</p>
        </td>
      </tr>
      <tr>
        <td>
          <p><strong>w</strong></p>
        </td>
        <td>
          <p>q<sub>w</sub>&times;1</p>
        </td>
        <td>
          <p>process noise vector</p>
        </td>
      </tr>
    </tbody>
  </table>
</div>

The vector lengths of (**u**) and (**w**) are given as (q<sub>u</sub>) and (q<sub>w</sub>) respectively. The total length of the combined input vector is (q = q<sub>u</sub> + q<sub>w</sub>), which conforms correctly to the dimensions of the input matrix (**G**) or (<big>Γ</big>).

Perhaps awkwardly, in this formulation we have both distinguished and combined the input vector (**u**) and the process noise vector (**w**). The distinction is that (**u**) is usually treated as a controlled input, like a knob on a machine or the rudder of a ship. The process noise vector (**w**), though still an input to the system, is not under the control of any part of the system. The process noise input represents such things as random disturbances in the movement of a vehicle, or errors in modeling of the system.

An alternate approach is to write the two inputs as separate terms. This requires the introduction of a new matrix like so

- **x<sup>'</sup>** = **F x + G u + L w**

or

- **x<sup>'</sup>** = <big>Φ</big> **x** + <big>Γ</big> **u** + <big>Λ</big> **w**

The new matrices (**L**) and (<big>Λ</big>) might as well be called _process noise input matrices_. They are exactly analogous to (**G**) and (<big>Γ</big>) but operating on the process noise rather than the control input.

## Estimates, Measurements, and Updates

State space systems commonly make use of a _predictor-corrector_ loop. Basically this means that the information available at the present time is used to predict the state of the system in the future. When new measurements of the system become available they are compared to the predicted values and any difference forms an error-feedback signal which is used to adjust the system model so that the predicted outputs are closer to the latest measurements.

As a notational side effect the predictor-corrector loop creates many distinctions between similar variables. For example the state vector (**x**) now comes in a predicted form, a measured form, and extrapolated form, among others. To keep track of the various forms we attempt to follow the most common convention for decorating the symbols, like so:

**Update decorations**

<div>
  <table>
    <tbody>
      <tr>
        <td>
          <p><strong>Example</strong></p>
        </td>
        <td>
          <p><strong>Decoration</strong></p>
        </td>
        <td>
          <p><strong>Meaning</strong></p>
        </td>
      </tr>
      <tr>
        <td>
          <p>x</p>
        </td>
        <td>
          <p>none</p>
        </td>
        <td>
          <p>exact or &quot;truth&quot; value</p>
        </td>
      </tr>
      <tr>
        <td>
          <p>$\bf{\hat x}$</p>
        </td>
        <td>
          <p>hat</p>
        </td>
        <td>
          <p>estimate or measurement update</p>
        </td>
      </tr>
      <tr>
        <td>
          <p>x<sup>-</sup></p>
        </td>
        <td>
          <p>minus</p>
        </td>
        <td>
          <p>time update or extrapolation</p>
        </td>
      </tr>
      <tr>
        <td>
          <p>$\bf{\tilde x}$</p>
        </td>
        <td>
          <p>tilde</p>
        </td>
        <td>
          <p>measurement</p>
        </td>
      </tr>
    </tbody>
  </table>
</div>

There's no doubt that using the update decorations can be confusing. As an aid we humbly suggest these mnemonics:

The truth value is pure and perfect, needing no decoration. The estimate is the best value we can realistically get. It's the value that the pointy headed smart people calculate, the ones with the wizard hats. The extrapolation is not as good a value as the estimate, thus the minus sign. The minus sign also signifies that the extrapolation is the value that is used _before_ the measurements come in. Once there are new measurements they can be used to generate estimates. This is why the estimates are also called "measurement updates". Extrapolations are called "time updates" because they are generated by running the system model forward in time using the current estimate as a starting point. Finally, the measurements are "tilde"(~) because, although they're good, they're only approximate, being corrupted by noise and error, they're somewhat wishy-washy.

Note: Another common convention is to denote extrapolations with over-bars. This is visually similar to the superscript-minus used here. We prefer the minus because it seems easier to follow, and the over-bar conflicts with several other common conventions, particularly for the average value.

Note: The sign convention for error terms is rarely consistent between authors. To us it seems preferable to write the measured value as the sum of the true value and the measurement error. Thus measurements which are too large have a positive error, and the true value is the measured value minus the error.

Symbolically we define the error as

- $$ \\bf \\epsilon\_x \\equiv \\bf\{ \\tilde x - x\} $$