1 | \hypertarget{classEKFfixed}{ |
---|
2 | \section{EKFfixed Class Reference} |
---|
3 | \label{classEKFfixed}\index{EKFfixed@{EKFfixed}} |
---|
4 | } |
---|
5 | {\tt \#include $<$ekf\_\-obj.h$>$} |
---|
6 | |
---|
7 | Inheritance diagram for EKFfixed::\begin{figure}[H] |
---|
8 | \begin{center} |
---|
9 | \leavevmode |
---|
10 | \includegraphics[height=3cm]{classEKFfixed} |
---|
11 | \end{center} |
---|
12 | \end{figure} |
---|
13 | |
---|
14 | |
---|
15 | \subsection{Detailed Description} |
---|
16 | Extended Kalman Filter with full matrices in fixed point arithmetic. |
---|
17 | |
---|
18 | An approximation of the exact Bayesian filter with Gaussian noices and non-linear evolutions of their mean. \subsection*{Public Member Functions} |
---|
19 | \begin{CompactItemize} |
---|
20 | \item |
---|
21 | \hypertarget{classEKFfixed_cece920bbf58fc72b25a6417b3ef0259}{ |
---|
22 | void \textbf{init\_\-ekf} (double Tv)} |
---|
23 | \label{classEKFfixed_cece920bbf58fc72b25a6417b3ef0259} |
---|
24 | |
---|
25 | \item |
---|
26 | \hypertarget{classEKFfixed_491e636b259dda3b876b7bd492df6b7c}{ |
---|
27 | void \textbf{ekf} (double ux, double uy, double isxd, double isyd)} |
---|
28 | \label{classEKFfixed_491e636b259dda3b876b7bd492df6b7c} |
---|
29 | |
---|
30 | \item |
---|
31 | \hypertarget{classEKFfixed_e77b35e1a11356dbfb1fdfa3017f60d3}{ |
---|
32 | void \textbf{prediction} (int $\ast$ux)} |
---|
33 | \label{classEKFfixed_e77b35e1a11356dbfb1fdfa3017f60d3} |
---|
34 | |
---|
35 | \item |
---|
36 | \hypertarget{classEKFfixed_83ed56b86a056d7dbdd6ce44145fa5f3}{ |
---|
37 | void \textbf{correction} (void)} |
---|
38 | \label{classEKFfixed_83ed56b86a056d7dbdd6ce44145fa5f3} |
---|
39 | |
---|
40 | \item |
---|
41 | \hypertarget{classEKFfixed_dce43355681cfe8f1905db207b4dde8d}{ |
---|
42 | void \textbf{update\_\-psi} (void)} |
---|
43 | \label{classEKFfixed_dce43355681cfe8f1905db207b4dde8d} |
---|
44 | |
---|
45 | \item |
---|
46 | \hypertarget{classEKFfixed_05d1f11bd56305420b56fe83ada6e586}{ |
---|
47 | \hyperlink{classEKFfixed_05d1f11bd56305420b56fe83ada6e586}{EKFfixed} ()} |
---|
48 | \label{classEKFfixed_05d1f11bd56305420b56fe83ada6e586} |
---|
49 | |
---|
50 | \begin{CompactList}\small\item\em Default constructor. \item\end{CompactList}\item |
---|
51 | \hypertarget{classEKFfixed_ddf5334bc1207658fd53698fffbac028}{ |
---|
52 | void \hyperlink{classEKFfixed_ddf5334bc1207658fd53698fffbac028}{bayes} (const vec \&dt)} |
---|
53 | \label{classEKFfixed_ddf5334bc1207658fd53698fffbac028} |
---|
54 | |
---|
55 | \begin{CompactList}\small\item\em Here dt = \mbox{[}yt;ut\mbox{]} of appropriate dimensions. \item\end{CompactList}\item |
---|
56 | \hypertarget{classEKFfixed_f3979e5514fe4278a519ba4481e287ac}{ |
---|
57 | \hyperlink{classbdm_1_1epdf}{epdf} \& \hyperlink{classEKFfixed_f3979e5514fe4278a519ba4481e287ac}{posterior} ()} |
---|
58 | \label{classEKFfixed_f3979e5514fe4278a519ba4481e287ac} |
---|
59 | |
---|
60 | \begin{CompactList}\small\item\em dummy! \item\end{CompactList}\item |
---|
61 | \hypertarget{classEKFfixed_c7fee79e75ad7f0c0e96c5a322cbf44e}{ |
---|
62 | void \hyperlink{classEKFfixed_c7fee79e75ad7f0c0e96c5a322cbf44e}{condition} (const vec \&Q0)} |
---|
63 | \label{classEKFfixed_c7fee79e75ad7f0c0e96c5a322cbf44e} |
---|
64 | |
---|
65 | \begin{CompactList}\small\item\em Substitute {\tt val} for {\tt rvc}. \item\end{CompactList}\item |
---|
66 | \hypertarget{classbdm_1_1BMcond_7506910f93250b44fea505ec4ffb19dc}{ |
---|
67 | const RV \& \hyperlink{classbdm_1_1BMcond_7506910f93250b44fea505ec4ffb19dc}{\_\-rvc} () const } |
---|
68 | \label{classbdm_1_1BMcond_7506910f93250b44fea505ec4ffb19dc} |
---|
69 | |
---|
70 | \begin{CompactList}\small\item\em access function \item\end{CompactList}\end{CompactItemize} |
---|
71 | \begin{Indent}{\bf Constructors}\par |
---|
72 | \begin{CompactItemize} |
---|
73 | \item |
---|
74 | virtual BM $\ast$ \hyperlink{classbdm_1_1BM_c0f027ff91d8459937c6f60ff8e553ff}{\_\-copy\_\-} () |
---|
75 | \end{CompactItemize} |
---|
76 | \end{Indent} |
---|
77 | \begin{Indent}{\bf Mathematical operations}\par |
---|
78 | \begin{CompactItemize} |
---|
79 | \item |
---|
80 | \hypertarget{classbdm_1_1BM_1dee3fddaf021e62d925289660a707dc}{ |
---|
81 | virtual void \hyperlink{classbdm_1_1BM_1dee3fddaf021e62d925289660a707dc}{bayesB} (const mat \&Dt)} |
---|
82 | \label{classbdm_1_1BM_1dee3fddaf021e62d925289660a707dc} |
---|
83 | |
---|
84 | \begin{CompactList}\small\item\em Batch Bayes rule (columns of Dt are observations). \item\end{CompactList}\item |
---|
85 | virtual double \hyperlink{classbdm_1_1BM_50257e0c1e5b5c73153ea6e716ad8ae0}{logpred} (const vec \&dt) const |
---|
86 | \item |
---|
87 | \hypertarget{classbdm_1_1BM_0e8ebe61fb14990abe1254bd3dda5fae}{ |
---|
88 | vec \hyperlink{classbdm_1_1BM_0e8ebe61fb14990abe1254bd3dda5fae}{logpred\_\-m} (const mat \&dt) const } |
---|
89 | \label{classbdm_1_1BM_0e8ebe61fb14990abe1254bd3dda5fae} |
---|
90 | |
---|
91 | \begin{CompactList}\small\item\em Matrix version of logpred. \item\end{CompactList}\item |
---|
92 | \hypertarget{classbdm_1_1BM_688d7a2aced1e06aa1c468d73a9e5eba}{ |
---|
93 | virtual epdf $\ast$ \hyperlink{classbdm_1_1BM_688d7a2aced1e06aa1c468d73a9e5eba}{epredictor} () const } |
---|
94 | \label{classbdm_1_1BM_688d7a2aced1e06aa1c468d73a9e5eba} |
---|
95 | |
---|
96 | \begin{CompactList}\small\item\em Constructs a predictive density $ f(d_{t+1} |d_{t}, \ldots d_{0}) $. \item\end{CompactList}\item |
---|
97 | \hypertarget{classbdm_1_1BM_598b25e3f3d96a5bc00a5faeb5b3c912}{ |
---|
98 | virtual mpdf $\ast$ \hyperlink{classbdm_1_1BM_598b25e3f3d96a5bc00a5faeb5b3c912}{predictor} () const } |
---|
99 | \label{classbdm_1_1BM_598b25e3f3d96a5bc00a5faeb5b3c912} |
---|
100 | |
---|
101 | \begin{CompactList}\small\item\em Constructs a conditional density 1-step ahead predictor. \item\end{CompactList}\end{CompactItemize} |
---|
102 | \end{Indent} |
---|
103 | \begin{Indent}{\bf Access to attributes}\par |
---|
104 | \begin{CompactItemize} |
---|
105 | \item |
---|
106 | \hypertarget{classbdm_1_1BM_ff2d8755ba0b3def927d31305c03b09c}{ |
---|
107 | const RV \& \textbf{\_\-drv} () const } |
---|
108 | \label{classbdm_1_1BM_ff2d8755ba0b3def927d31305c03b09c} |
---|
109 | |
---|
110 | \item |
---|
111 | \hypertarget{classbdm_1_1BM_f135ae6dce7e9f30c9f88229c7930b96}{ |
---|
112 | void \textbf{set\_\-drv} (const RV \&rv)} |
---|
113 | \label{classbdm_1_1BM_f135ae6dce7e9f30c9f88229c7930b96} |
---|
114 | |
---|
115 | \item |
---|
116 | \hypertarget{classbdm_1_1BM_b38d92f17620813ad872d86e01a26e5e}{ |
---|
117 | void \textbf{set\_\-rv} (const RV \&rv)} |
---|
118 | \label{classbdm_1_1BM_b38d92f17620813ad872d86e01a26e5e} |
---|
119 | |
---|
120 | \item |
---|
121 | \hypertarget{classbdm_1_1BM_5be65d37dedfe33a3671e7065f523a70}{ |
---|
122 | double \textbf{\_\-ll} () const } |
---|
123 | \label{classbdm_1_1BM_5be65d37dedfe33a3671e7065f523a70} |
---|
124 | |
---|
125 | \item |
---|
126 | \hypertarget{classbdm_1_1BM_236b3abbcc93594fc97cd86d82c1a83f}{ |
---|
127 | void \textbf{set\_\-evalll} (bool evl0)} |
---|
128 | \label{classbdm_1_1BM_236b3abbcc93594fc97cd86d82c1a83f} |
---|
129 | |
---|
130 | \item |
---|
131 | \hypertarget{classbdm_1_1BM_bb7b0065d6cb722a66b371a8260121e1}{ |
---|
132 | virtual const epdf \& \textbf{posterior} () const =0} |
---|
133 | \label{classbdm_1_1BM_bb7b0065d6cb722a66b371a8260121e1} |
---|
134 | |
---|
135 | \item |
---|
136 | \hypertarget{classbdm_1_1BM_4ed0f8b880e606316ae800f3a011c3a6}{ |
---|
137 | virtual const epdf $\ast$ \textbf{\_\-e} () const =0} |
---|
138 | \label{classbdm_1_1BM_4ed0f8b880e606316ae800f3a011c3a6} |
---|
139 | |
---|
140 | \end{CompactItemize} |
---|
141 | \end{Indent} |
---|
142 | \subsection*{Public Attributes} |
---|
143 | \begin{CompactItemize} |
---|
144 | \item |
---|
145 | \hypertarget{classEKFfixed_d04ddf049475a15e1ba93161aa5586ab}{ |
---|
146 | int \textbf{Q} \mbox{[}16\mbox{]}} |
---|
147 | \label{classEKFfixed_d04ddf049475a15e1ba93161aa5586ab} |
---|
148 | |
---|
149 | \item |
---|
150 | \hypertarget{classEKFfixed_d914213d413b4d8f8d7bb728c5063d5e}{ |
---|
151 | int \textbf{R} \mbox{[}4\mbox{]}} |
---|
152 | \label{classEKFfixed_d914213d413b4d8f8d7bb728c5063d5e} |
---|
153 | |
---|
154 | \item |
---|
155 | \hypertarget{classEKFfixed_7fd20a80b00e9782da676e48eb5b54b3}{ |
---|
156 | int \textbf{x\_\-est} \mbox{[}4\mbox{]}} |
---|
157 | \label{classEKFfixed_7fd20a80b00e9782da676e48eb5b54b3} |
---|
158 | |
---|
159 | \item |
---|
160 | \hypertarget{classEKFfixed_9518fa723d7324f75df7822a589ee196}{ |
---|
161 | int \textbf{x\_\-pred} \mbox{[}4\mbox{]}} |
---|
162 | \label{classEKFfixed_9518fa723d7324f75df7822a589ee196} |
---|
163 | |
---|
164 | \item |
---|
165 | \hypertarget{classEKFfixed_0b731c546a474433c1ea6f36f0125774}{ |
---|
166 | int \textbf{P\_\-pred} \mbox{[}16\mbox{]}} |
---|
167 | \label{classEKFfixed_0b731c546a474433c1ea6f36f0125774} |
---|
168 | |
---|
169 | \item |
---|
170 | \hypertarget{classEKFfixed_b9ec9cb2d092ca3f4ad2a3b4420867ac}{ |
---|
171 | int \textbf{P\_\-est} \mbox{[}16\mbox{]}} |
---|
172 | \label{classEKFfixed_b9ec9cb2d092ca3f4ad2a3b4420867ac} |
---|
173 | |
---|
174 | \item |
---|
175 | \hypertarget{classEKFfixed_5a8040cdb8bb5dca753485dc67db3287}{ |
---|
176 | int \textbf{Y\_\-mes} \mbox{[}2\mbox{]}} |
---|
177 | \label{classEKFfixed_5a8040cdb8bb5dca753485dc67db3287} |
---|
178 | |
---|
179 | \item |
---|
180 | \hypertarget{classEKFfixed_9292e43fb8e6fedfabb3a9b3c2118e33}{ |
---|
181 | int \textbf{ukalm} \mbox{[}2\mbox{]}} |
---|
182 | \label{classEKFfixed_9292e43fb8e6fedfabb3a9b3c2118e33} |
---|
183 | |
---|
184 | \item |
---|
185 | \hypertarget{classEKFfixed_f754902bb769d3b58b89108c76d9a394}{ |
---|
186 | int \textbf{Kalm} \mbox{[}8\mbox{]}} |
---|
187 | \label{classEKFfixed_f754902bb769d3b58b89108c76d9a394} |
---|
188 | |
---|
189 | \item |
---|
190 | \hypertarget{classEKFfixed_bf4b3d55c8d277673bf77f37f6590217}{ |
---|
191 | int \textbf{PSI} \mbox{[}16\mbox{]}} |
---|
192 | \label{classEKFfixed_bf4b3d55c8d277673bf77f37f6590217} |
---|
193 | |
---|
194 | \item |
---|
195 | \hypertarget{classEKFfixed_8a677b253b54696701c1ca0cb6f7a622}{ |
---|
196 | int \textbf{temp15a} \mbox{[}16\mbox{]}} |
---|
197 | \label{classEKFfixed_8a677b253b54696701c1ca0cb6f7a622} |
---|
198 | |
---|
199 | \item |
---|
200 | \hypertarget{classEKFfixed_6d4354dad09286a7a209983732853c5b}{ |
---|
201 | int \textbf{cA}} |
---|
202 | \label{classEKFfixed_6d4354dad09286a7a209983732853c5b} |
---|
203 | |
---|
204 | \item |
---|
205 | \hypertarget{classEKFfixed_eac752adfb921c1c525f8c3b3fd15dad}{ |
---|
206 | int \textbf{cB}} |
---|
207 | \label{classEKFfixed_eac752adfb921c1c525f8c3b3fd15dad} |
---|
208 | |
---|
209 | \item |
---|
210 | \hypertarget{classEKFfixed_2f35ef3dce13131ae9b4427309a1d005}{ |
---|
211 | int \textbf{cC}} |
---|
212 | \label{classEKFfixed_2f35ef3dce13131ae9b4427309a1d005} |
---|
213 | |
---|
214 | \item |
---|
215 | \hypertarget{classEKFfixed_50b31e70bb17cbdde2e28c83b9612c47}{ |
---|
216 | int \textbf{cG}} |
---|
217 | \label{classEKFfixed_50b31e70bb17cbdde2e28c83b9612c47} |
---|
218 | |
---|
219 | \item |
---|
220 | \hypertarget{classEKFfixed_086e18ad28d139b0a2c0f77badc77a9a}{ |
---|
221 | int \textbf{cH}} |
---|
222 | \label{classEKFfixed_086e18ad28d139b0a2c0f77badc77a9a} |
---|
223 | |
---|
224 | \item |
---|
225 | \hypertarget{classEKFfixed_540046e3ab4d0bed4791f397062a626f}{ |
---|
226 | long \textbf{temp30a} \mbox{[}4\mbox{]}} |
---|
227 | \label{classEKFfixed_540046e3ab4d0bed4791f397062a626f} |
---|
228 | |
---|
229 | \item |
---|
230 | \hypertarget{classEKFfixed_ea92b06e2b66c6771828e689bb727b76}{ |
---|
231 | \hyperlink{classbdm_1_1enorm}{enorm}$<$ \hyperlink{classfsqmat}{fsqmat} $>$ \textbf{E}} |
---|
232 | \label{classEKFfixed_ea92b06e2b66c6771828e689bb727b76} |
---|
233 | |
---|
234 | \item |
---|
235 | \hypertarget{classEKFfixed_6e5552506214757d24e59e508f91c8aa}{ |
---|
236 | mat \textbf{Ry}} |
---|
237 | \label{classEKFfixed_6e5552506214757d24e59e508f91c8aa} |
---|
238 | |
---|
239 | \end{CompactItemize} |
---|
240 | \subsection*{Protected Attributes} |
---|
241 | \begin{CompactItemize} |
---|
242 | \item |
---|
243 | \hypertarget{classbdm_1_1BM_c400357e37d27a4834b2b1d9211009ed}{ |
---|
244 | RV \hyperlink{classbdm_1_1BM_c400357e37d27a4834b2b1d9211009ed}{drv}} |
---|
245 | \label{classbdm_1_1BM_c400357e37d27a4834b2b1d9211009ed} |
---|
246 | |
---|
247 | \begin{CompactList}\small\item\em Random variable of the data (optional). \item\end{CompactList}\item |
---|
248 | \hypertarget{classbdm_1_1BM_4064b6559d962633e4372b12f4cd204a}{ |
---|
249 | double \hyperlink{classbdm_1_1BM_4064b6559d962633e4372b12f4cd204a}{ll}} |
---|
250 | \label{classbdm_1_1BM_4064b6559d962633e4372b12f4cd204a} |
---|
251 | |
---|
252 | \begin{CompactList}\small\item\em Logarithm of marginalized data likelihood. \item\end{CompactList}\item |
---|
253 | \hypertarget{classbdm_1_1BM_faff0ad12556fe7dc0e2807d4fd938ee}{ |
---|
254 | bool \hyperlink{classbdm_1_1BM_faff0ad12556fe7dc0e2807d4fd938ee}{evalll}} |
---|
255 | \label{classbdm_1_1BM_faff0ad12556fe7dc0e2807d4fd938ee} |
---|
256 | |
---|
257 | \begin{CompactList}\small\item\em If true, the filter will compute likelihood of the data record and store it in {\tt ll} . Set to false if you want to save computational time. \item\end{CompactList}\item |
---|
258 | \hypertarget{classbdm_1_1BMcond_1164a90f782a2a323b1ee17242100b39}{ |
---|
259 | int \hyperlink{classbdm_1_1BMcond_1164a90f782a2a323b1ee17242100b39}{dimc}} |
---|
260 | \label{classbdm_1_1BMcond_1164a90f782a2a323b1ee17242100b39} |
---|
261 | |
---|
262 | \begin{CompactList}\small\item\em dimension of the conditioning variable \item\end{CompactList}\item |
---|
263 | \hypertarget{classbdm_1_1BMcond_9a12750776d977408aada06a70093297}{ |
---|
264 | RV \hyperlink{classbdm_1_1BMcond_9a12750776d977408aada06a70093297}{rvc}} |
---|
265 | \label{classbdm_1_1BMcond_9a12750776d977408aada06a70093297} |
---|
266 | |
---|
267 | \begin{CompactList}\small\item\em Identificator of the conditioning variable. \item\end{CompactList}\end{CompactItemize} |
---|
268 | |
---|
269 | |
---|
270 | \subsection{Member Function Documentation} |
---|
271 | \hypertarget{classbdm_1_1BM_c0f027ff91d8459937c6f60ff8e553ff}{ |
---|
272 | \index{EKFfixed@{EKFfixed}!\_\-copy\_\-@{\_\-copy\_\-}} |
---|
273 | \index{\_\-copy\_\-@{\_\-copy\_\-}!EKFfixed@{EKFfixed}} |
---|
274 | \subsubsection[\_\-copy\_\-]{\setlength{\rightskip}{0pt plus 5cm}virtual BM$\ast$ bdm::BM::\_\-copy\_\- ()\hspace{0.3cm}{\tt \mbox{[}inline, virtual, inherited\mbox{]}}}} |
---|
275 | \label{classbdm_1_1BM_c0f027ff91d8459937c6f60ff8e553ff} |
---|
276 | |
---|
277 | |
---|
278 | Copy function required in vectors, Arrays of \hyperlink{classbdm_1_1BM}{BM} etc. Have to be DELETED manually! Prototype: |
---|
279 | |
---|
280 | \begin{Code}\begin{verbatim} BM* _copy_(){return new BM(*this);} |
---|
281 | \end{verbatim} |
---|
282 | \end{Code} |
---|
283 | |
---|
284 | |
---|
285 | |
---|
286 | Reimplemented in \hyperlink{classbdm_1_1ARX_60c40b5c6abc4c7e464b4ccae64a5a61}{bdm::ARX}.\hypertarget{classbdm_1_1BM_50257e0c1e5b5c73153ea6e716ad8ae0}{ |
---|
287 | \index{EKFfixed@{EKFfixed}!logpred@{logpred}} |
---|
288 | \index{logpred@{logpred}!EKFfixed@{EKFfixed}} |
---|
289 | \subsubsection[logpred]{\setlength{\rightskip}{0pt plus 5cm}virtual double bdm::BM::logpred (const vec \& {\em dt}) const\hspace{0.3cm}{\tt \mbox{[}inline, virtual, inherited\mbox{]}}}} |
---|
290 | \label{classbdm_1_1BM_50257e0c1e5b5c73153ea6e716ad8ae0} |
---|
291 | |
---|
292 | |
---|
293 | Evaluates predictive log-likelihood of the given data record I.e. marginal likelihood of the data with the posterior integrated out. |
---|
294 | |
---|
295 | Reimplemented in \hyperlink{classbdm_1_1ARX_080a7e531e3aa06694112863b15bc6a4}{bdm::ARX}, \hyperlink{classbdm_1_1MixEF_da724da464a75e07521941e430929efa}{bdm::MixEF}, and \hyperlink{classbdm_1_1multiBM_e157b607c1e3fa91d42aeea44458e2bf}{bdm::multiBM}. |
---|
296 | |
---|
297 | Referenced by bdm::BM::logpred\_\-m(). |
---|
298 | |
---|
299 | The documentation for this class was generated from the following files:\begin{CompactItemize} |
---|
300 | \item |
---|
301 | \hyperlink{ekf__obj_8h}{ekf\_\-obj.h}\item |
---|
302 | ekf\_\-obj.cpp\end{CompactItemize} |
---|