\section{Diagonal\+Constraint Class Reference}
\label{classmlpack_1_1gmm_1_1DiagonalConstraint}\index{Diagonal\+Constraint@{Diagonal\+Constraint}}


Force a covariance matrix to be diagonal.  


\subsection*{Static Public Member Functions}
\begin{DoxyCompactItemize}
\item 
static void \textbf{ Apply\+Constraint} (arma\+::mat \&covariance)
\begin{DoxyCompactList}\small\item\em Force a covariance matrix to be diagonal. \end{DoxyCompactList}\item 
static void \textbf{ Apply\+Constraint} (arma\+::vec \&diag\+Covariance)
\begin{DoxyCompactList}\small\item\em Apply the diagonal constraint to the given diagonal covariance matrix (which is represented as a vector), and ensure each value on the diagonal is at least 1e-\/10. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename Archive $>$ }\\static void \textbf{ serialize} (Archive \&, const unsigned int)
\begin{DoxyCompactList}\small\item\em Serialize the constraint (which holds nothing, so, nothing to do). \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Force a covariance matrix to be diagonal. 

Definition at line 23 of file diagonal\+\_\+constraint.\+hpp.



\subsection{Member Function Documentation}
\mbox{\label{classmlpack_1_1gmm_1_1DiagonalConstraint_a1e68c9489180b84b3a8d1e265a3d8a8f}} 
\index{mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}!Apply\+Constraint@{Apply\+Constraint}}
\index{Apply\+Constraint@{Apply\+Constraint}!mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}}
\subsubsection{Apply\+Constraint()\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily static void Apply\+Constraint (\begin{DoxyParamCaption}\item[{arma\+::mat \&}]{covariance }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Force a covariance matrix to be diagonal. 



Definition at line 27 of file diagonal\+\_\+constraint.\+hpp.

\mbox{\label{classmlpack_1_1gmm_1_1DiagonalConstraint_a5262e4a927a389167cfc7714de4df883}} 
\index{mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}!Apply\+Constraint@{Apply\+Constraint}}
\index{Apply\+Constraint@{Apply\+Constraint}!mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}}
\subsubsection{Apply\+Constraint()\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily static void Apply\+Constraint (\begin{DoxyParamCaption}\item[{arma\+::vec \&}]{diag\+Covariance }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Apply the diagonal constraint to the given diagonal covariance matrix (which is represented as a vector), and ensure each value on the diagonal is at least 1e-\/10. 



Definition at line 38 of file diagonal\+\_\+constraint.\+hpp.

\mbox{\label{classmlpack_1_1gmm_1_1DiagonalConstraint_a850673001b3b9a94949b71644ccd063f}} 
\index{mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}!serialize@{serialize}}
\index{serialize@{serialize}!mlpack\+::gmm\+::\+Diagonal\+Constraint@{mlpack\+::gmm\+::\+Diagonal\+Constraint}}
\subsubsection{serialize()}
{\footnotesize\ttfamily static void serialize (\begin{DoxyParamCaption}\item[{Archive \&}]{,  }\item[{const unsigned}]{int }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}, {\ttfamily [static]}}



Serialize the constraint (which holds nothing, so, nothing to do). 



Definition at line 47 of file diagonal\+\_\+constraint.\+hpp.



The documentation for this class was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
/var/www/mlpack.\+ratml.\+org/mlpack.\+org/\+\_\+src/mlpack-\/3.\+3.\+1/src/mlpack/methods/gmm/\textbf{ diagonal\+\_\+constraint.\+hpp}\end{DoxyCompactItemize}
