1 | \hypertarget{classenorm}{ |
---|
2 | \section{enorm$<$ sq\_\-T $>$ Class Template Reference} |
---|
3 | \label{classenorm}\index{enorm@{enorm}} |
---|
4 | } |
---|
5 | Gaussian density with positive definite (decomposed) covariance matrix. |
---|
6 | |
---|
7 | |
---|
8 | {\tt \#include $<$libEF.h$>$} |
---|
9 | |
---|
10 | Inheritance diagram for enorm$<$ sq\_\-T $>$:\nopagebreak |
---|
11 | \begin{figure}[H] |
---|
12 | \begin{center} |
---|
13 | \leavevmode |
---|
14 | \includegraphics[width=171pt]{classenorm__inherit__graph} |
---|
15 | \end{center} |
---|
16 | \end{figure} |
---|
17 | Collaboration diagram for enorm$<$ sq\_\-T $>$:\nopagebreak |
---|
18 | \begin{figure}[H] |
---|
19 | \begin{center} |
---|
20 | \leavevmode |
---|
21 | \includegraphics[width=69pt]{classenorm__coll__graph} |
---|
22 | \end{center} |
---|
23 | \end{figure} |
---|
24 | \subsection*{Public Member Functions} |
---|
25 | \begin{CompactItemize} |
---|
26 | \item |
---|
27 | \hypertarget{classenorm_0caf54fed9e48f9fe28b534b2027df2f}{ |
---|
28 | \hyperlink{classenorm_0caf54fed9e48f9fe28b534b2027df2f}{enorm} (const \hyperlink{classRV}{RV} \&\hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv})} |
---|
29 | \label{classenorm_0caf54fed9e48f9fe28b534b2027df2f} |
---|
30 | |
---|
31 | \begin{CompactList}\small\item\em Default constructor. \item\end{CompactList}\item |
---|
32 | \hypertarget{classenorm_1394a65caa6e00d42e00cc99b12227af}{ |
---|
33 | void \hyperlink{classenorm_1394a65caa6e00d42e00cc99b12227af}{set\_\-parameters} (const vec \&\hyperlink{classenorm_71fde0d54bba147e00f612577f95ad20}{mu}, const sq\_\-T \&\hyperlink{classenorm_4ccc8d8514d644ef1c98d8ab023748a1}{R})} |
---|
34 | \label{classenorm_1394a65caa6e00d42e00cc99b12227af} |
---|
35 | |
---|
36 | \begin{CompactList}\small\item\em Set mean value {\tt mu} and covariance {\tt R}. \item\end{CompactList}\item |
---|
37 | \hypertarget{classenorm_5bf185e31e5954fceb90ada3debd2ff2}{ |
---|
38 | void \hyperlink{classenorm_5bf185e31e5954fceb90ada3debd2ff2}{dupdate} (mat \&v, double nu=1.0)} |
---|
39 | \label{classenorm_5bf185e31e5954fceb90ada3debd2ff2} |
---|
40 | |
---|
41 | \begin{CompactList}\small\item\em dupdate in exponential form (not really handy) \item\end{CompactList}\item |
---|
42 | \hypertarget{classenorm_60b47544f6181ffd4530d3e415ce12c5}{ |
---|
43 | vec \hyperlink{classenorm_60b47544f6181ffd4530d3e415ce12c5}{sample} () const } |
---|
44 | \label{classenorm_60b47544f6181ffd4530d3e415ce12c5} |
---|
45 | |
---|
46 | \begin{CompactList}\small\item\em Returns a sample, $x$ from density $epdf(rv)$. \item\end{CompactList}\item |
---|
47 | \hypertarget{classenorm_60f0f3bfa53d6e65843eea9532b16d36}{ |
---|
48 | mat \hyperlink{classenorm_60f0f3bfa53d6e65843eea9532b16d36}{sample} (int N) const } |
---|
49 | \label{classenorm_60f0f3bfa53d6e65843eea9532b16d36} |
---|
50 | |
---|
51 | \begin{CompactList}\small\item\em TODO is it used? \item\end{CompactList}\item |
---|
52 | \hypertarget{classenorm_50cb0a083d97a7adbbd97c92e712c46c}{ |
---|
53 | double \hyperlink{classenorm_50cb0a083d97a7adbbd97c92e712c46c}{evallog\_\-nn} (const vec \&val) const } |
---|
54 | \label{classenorm_50cb0a083d97a7adbbd97c92e712c46c} |
---|
55 | |
---|
56 | \begin{CompactList}\small\item\em Evaluate normalized log-probability. \item\end{CompactList}\item |
---|
57 | \hypertarget{classenorm_b289a36a69db59d182bb6eba9c05d4a8}{ |
---|
58 | double \hyperlink{classenorm_b289a36a69db59d182bb6eba9c05d4a8}{lognc} () const } |
---|
59 | \label{classenorm_b289a36a69db59d182bb6eba9c05d4a8} |
---|
60 | |
---|
61 | \begin{CompactList}\small\item\em logarithm of the normalizing constant, $\mathcal{I}$ \item\end{CompactList}\item |
---|
62 | \hypertarget{classenorm_50fa84da7bae02f7af17a98f37566899}{ |
---|
63 | vec \hyperlink{classenorm_50fa84da7bae02f7af17a98f37566899}{mean} () const } |
---|
64 | \label{classenorm_50fa84da7bae02f7af17a98f37566899} |
---|
65 | |
---|
66 | \begin{CompactList}\small\item\em return expected value \item\end{CompactList}\item |
---|
67 | \hypertarget{classenorm_d4b4bfec464fe971bf57e69d71a1cf2e}{ |
---|
68 | vec \hyperlink{classenorm_d4b4bfec464fe971bf57e69d71a1cf2e}{variance} () const } |
---|
69 | \label{classenorm_d4b4bfec464fe971bf57e69d71a1cf2e} |
---|
70 | |
---|
71 | \begin{CompactList}\small\item\em return expected variance (not covariance!) \item\end{CompactList}\item |
---|
72 | \hypertarget{classenorm_921024bd6d5a0e65f2af2e39bf38dfca}{ |
---|
73 | \hyperlink{classmpdf}{mpdf} $\ast$ \hyperlink{classenorm_921024bd6d5a0e65f2af2e39bf38dfca}{condition} (const \hyperlink{classRV}{RV} \&rvn) const } |
---|
74 | \label{classenorm_921024bd6d5a0e65f2af2e39bf38dfca} |
---|
75 | |
---|
76 | \begin{CompactList}\small\item\em Return conditional density on the given \hyperlink{classRV}{RV}, the remaining rvs will be in conditioning. \item\end{CompactList}\item |
---|
77 | \hypertarget{classenorm_af50a6102846060bcb23a670bf38117b}{ |
---|
78 | \hyperlink{classepdf}{epdf} $\ast$ \hyperlink{classenorm_af50a6102846060bcb23a670bf38117b}{marginal} (const \hyperlink{classRV}{RV} \&\hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv}) const } |
---|
79 | \label{classenorm_af50a6102846060bcb23a670bf38117b} |
---|
80 | |
---|
81 | \begin{CompactList}\small\item\em Return marginal density on the given \hyperlink{classRV}{RV}, the remainig rvs are intergrated out. \item\end{CompactList}\item |
---|
82 | \hypertarget{classenorm_0b8cb284e5af920a1b64a21d057ec5ac}{ |
---|
83 | vec \& \hyperlink{classenorm_0b8cb284e5af920a1b64a21d057ec5ac}{\_\-mu} ()} |
---|
84 | \label{classenorm_0b8cb284e5af920a1b64a21d057ec5ac} |
---|
85 | |
---|
86 | \begin{CompactList}\small\item\em returns a pointer to the internal mean value. Use with Care! \item\end{CompactList}\item |
---|
87 | \hypertarget{classenorm_d892a38f03be12e572ea57d9689cef6b}{ |
---|
88 | void \hyperlink{classenorm_d892a38f03be12e572ea57d9689cef6b}{set\_\-mu} (const vec mu0)} |
---|
89 | \label{classenorm_d892a38f03be12e572ea57d9689cef6b} |
---|
90 | |
---|
91 | \begin{CompactList}\small\item\em access function \item\end{CompactList}\item |
---|
92 | \hypertarget{classenorm_7a5034b25771a84450a990d10fc40ac9}{ |
---|
93 | sq\_\-T \& \hyperlink{classenorm_7a5034b25771a84450a990d10fc40ac9}{\_\-R} ()} |
---|
94 | \label{classenorm_7a5034b25771a84450a990d10fc40ac9} |
---|
95 | |
---|
96 | \begin{CompactList}\small\item\em returns pointers to the internal variance and its inverse. Use with Care! \item\end{CompactList}\item |
---|
97 | \hypertarget{classenorm_d01385983048ece700b426549bbaee56}{ |
---|
98 | const sq\_\-T \& \textbf{\_\-R} () const } |
---|
99 | \label{classenorm_d01385983048ece700b426549bbaee56} |
---|
100 | |
---|
101 | \item |
---|
102 | \hypertarget{classeEF_a89bef8996410609004fa019b5b48964}{ |
---|
103 | virtual void \hyperlink{classeEF_a89bef8996410609004fa019b5b48964}{dupdate} (mat \&v)} |
---|
104 | \label{classeEF_a89bef8996410609004fa019b5b48964} |
---|
105 | |
---|
106 | \begin{CompactList}\small\item\em TODO decide if it is really needed. \item\end{CompactList}\item |
---|
107 | \hypertarget{classeEF_357512dd565e199904d367294b7dd862}{ |
---|
108 | virtual double \hyperlink{classeEF_357512dd565e199904d367294b7dd862}{evallog} (const vec \&val) const } |
---|
109 | \label{classeEF_357512dd565e199904d367294b7dd862} |
---|
110 | |
---|
111 | \begin{CompactList}\small\item\em Evaluate normalized log-probability. \item\end{CompactList}\item |
---|
112 | \hypertarget{classeEF_cff03a658aec11b806c3e3d48f37b81f}{ |
---|
113 | virtual vec \hyperlink{classeEF_cff03a658aec11b806c3e3d48f37b81f}{evallog} (const mat \&Val) const } |
---|
114 | \label{classeEF_cff03a658aec11b806c3e3d48f37b81f} |
---|
115 | |
---|
116 | \begin{CompactList}\small\item\em Evaluate normalized log-probability for many samples. \item\end{CompactList}\item |
---|
117 | \hypertarget{classeEF_4f8385dd1cc9740522dc373b1dc3cbf5}{ |
---|
118 | virtual void \hyperlink{classeEF_4f8385dd1cc9740522dc373b1dc3cbf5}{pow} (double p)} |
---|
119 | \label{classeEF_4f8385dd1cc9740522dc373b1dc3cbf5} |
---|
120 | |
---|
121 | \begin{CompactList}\small\item\em Power of the density, used e.g. to flatten the density. \item\end{CompactList}\item |
---|
122 | \hypertarget{classepdf_76608914c3b19e150292d5c56e93e508}{ |
---|
123 | virtual mat \hyperlink{classepdf_76608914c3b19e150292d5c56e93e508}{sample\_\-m} (int N) const } |
---|
124 | \label{classepdf_76608914c3b19e150292d5c56e93e508} |
---|
125 | |
---|
126 | \begin{CompactList}\small\item\em Returns N samples from density $epdf(rv)$. \item\end{CompactList}\item |
---|
127 | \hypertarget{classepdf_2495a04bbacb9b55fe5a3a59b78affca}{ |
---|
128 | virtual vec \hyperlink{classepdf_2495a04bbacb9b55fe5a3a59b78affca}{evallog\_\-m} (const mat \&Val) const } |
---|
129 | \label{classepdf_2495a04bbacb9b55fe5a3a59b78affca} |
---|
130 | |
---|
131 | \begin{CompactList}\small\item\em Compute log-probability of multiple values argument {\tt val}. \item\end{CompactList}\item |
---|
132 | \hypertarget{classepdf_ca0d32aabb4cbba347e0c37fe8607562}{ |
---|
133 | const \hyperlink{classRV}{RV} \& \hyperlink{classepdf_ca0d32aabb4cbba347e0c37fe8607562}{\_\-rv} () const } |
---|
134 | \label{classepdf_ca0d32aabb4cbba347e0c37fe8607562} |
---|
135 | |
---|
136 | \begin{CompactList}\small\item\em access function, possibly dangerous! \item\end{CompactList}\item |
---|
137 | \hypertarget{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5}{ |
---|
138 | void \hyperlink{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5}{\_\-renewrv} (const \hyperlink{classRV}{RV} \&in\_\-rv)} |
---|
139 | \label{classepdf_7fb94ce90d1ac7077d29f7d6a6c3e0a5} |
---|
140 | |
---|
141 | \begin{CompactList}\small\item\em modifier function - useful when copying epdfs \item\end{CompactList}\end{CompactItemize} |
---|
142 | \subsection*{Protected Attributes} |
---|
143 | \begin{CompactItemize} |
---|
144 | \item |
---|
145 | \hypertarget{classenorm_71fde0d54bba147e00f612577f95ad20}{ |
---|
146 | vec \hyperlink{classenorm_71fde0d54bba147e00f612577f95ad20}{mu}} |
---|
147 | \label{classenorm_71fde0d54bba147e00f612577f95ad20} |
---|
148 | |
---|
149 | \begin{CompactList}\small\item\em mean value \item\end{CompactList}\item |
---|
150 | \hypertarget{classenorm_4ccc8d8514d644ef1c98d8ab023748a1}{ |
---|
151 | sq\_\-T \hyperlink{classenorm_4ccc8d8514d644ef1c98d8ab023748a1}{R}} |
---|
152 | \label{classenorm_4ccc8d8514d644ef1c98d8ab023748a1} |
---|
153 | |
---|
154 | \begin{CompactList}\small\item\em Covariance matrix in decomposed form. \item\end{CompactList}\item |
---|
155 | \hypertarget{classenorm_6938fc390a19cdaf6ad4503fcbaada4e}{ |
---|
156 | int \hyperlink{classenorm_6938fc390a19cdaf6ad4503fcbaada4e}{dim}} |
---|
157 | \label{classenorm_6938fc390a19cdaf6ad4503fcbaada4e} |
---|
158 | |
---|
159 | \begin{CompactList}\small\item\em dimension (redundant from rv.count() for easier coding ) \item\end{CompactList}\item |
---|
160 | \hypertarget{classepdf_74da992e3f5d598da8850b646b79b9d9}{ |
---|
161 | \hyperlink{classRV}{RV} \hyperlink{classepdf_74da992e3f5d598da8850b646b79b9d9}{rv}} |
---|
162 | \label{classepdf_74da992e3f5d598da8850b646b79b9d9} |
---|
163 | |
---|
164 | \begin{CompactList}\small\item\em Identified of the random variable. \item\end{CompactList}\end{CompactItemize} |
---|
165 | |
---|
166 | |
---|
167 | \subsection{Detailed Description} |
---|
168 | \subsubsection*{template$<$class sq\_\-T$>$ class enorm$<$ sq\_\-T $>$} |
---|
169 | |
---|
170 | Gaussian density with positive definite (decomposed) covariance matrix. |
---|
171 | |
---|
172 | More?... |
---|
173 | |
---|
174 | The documentation for this class was generated from the following file:\begin{CompactItemize} |
---|
175 | \item |
---|
176 | work/git/mixpp/bdm/stat/\hyperlink{libEF_8h}{libEF.h}\end{CompactItemize} |
---|