\hypertarget{a00419}{
\section{mln::value::float01 Class Reference}
\label{d3/d29/a00419}\index{mln::value::float01@{mln::value::float01}}
}


Class for floating values restricted to the interval \mbox{[}0..1\mbox{]} and discretized with n bits.  




{\ttfamily \#include $<$float01.hh$>$}



Inherits mln::value::Floating$<$ float01 $>$.

\subsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
typedef std::pair$<$ unsigned, unsigned long $>$ \hyperlink{a00419_a53dbc71d645e3ee93350eac6ca62104f}{enc}
\begin{DoxyCompactList}\small\item\em Encoding associated type. \item\end{DoxyCompactList}\item 
typedef float \hyperlink{a00419_a7fcec3437ee58050178b99758307b476}{equiv}
\begin{DoxyCompactList}\small\item\em Equivalent associated type. \item\end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{a00419_a4c54a202ea4f352d202adc198f0b2d47}{float01} ()
\begin{DoxyCompactList}\small\item\em Ctor. \item\end{DoxyCompactList}\item 
{\footnotesize template$<$unsigned n$>$ }\\\hyperlink{a00419_ab28c0e08014a5d3866038edb095daf23}{float01} (const float01\_\-$<$ n $>$ \&val)
\begin{DoxyCompactList}\small\item\em Ctor. \item\end{DoxyCompactList}\item 
\hyperlink{a00419_ae3604b585d8dc4c23c813449b37f12a3}{float01} (unsigned nbits, float val)
\begin{DoxyCompactList}\small\item\em Ctor. \item\end{DoxyCompactList}\item 
unsigned \hyperlink{a00419_a90e176b751de8a32d802dce2ce5fcf1c}{nbits} () const 
\begin{DoxyCompactList}\small\item\em Access to the encoding size. \item\end{DoxyCompactList}\item 
\hyperlink{a00419_a57aaff68479ceb307cb3bc83f505b85f}{operator float} () const 
\begin{DoxyCompactList}\small\item\em Conversion to float. \item\end{DoxyCompactList}\item 
\hyperlink{a00419}{float01} \& \hyperlink{a00419_a7f0047cd08e3870fc318c210ce135ddc}{set\_\-nbits} (unsigned nbits)
\begin{DoxyCompactList}\small\item\em Set the encoding size to nbits. \item\end{DoxyCompactList}\item 
const \hyperlink{a00419}{float01} \hyperlink{a00419_a2579cd4bdb1ca987b420839ff6403a30}{to\_\-nbits} (unsigned nbits) const 
\begin{DoxyCompactList}\small\item\em Return an equivalent gray encoded on {\ttfamily nbits} bits. \item\end{DoxyCompactList}\item 
float \hyperlink{a00419_a630cfac2b78237a0c6ed28ed10d84bcd}{value} () const 
\begin{DoxyCompactList}\small\item\em Access to std type. \item\end{DoxyCompactList}\item 
unsigned long \hyperlink{a00419_a237b3e1876bd42f1c6af4814a1063a74}{value\_\-ind} () const 
\begin{DoxyCompactList}\small\item\em Access to the position in the quantized interval. \item\end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Class for floating values restricted to the interval \mbox{[}0..1\mbox{]} and discretized with n bits. 

Definition at line 56 of file float01.hh.



\subsection{Member Typedef Documentation}
\hypertarget{a00419_a53dbc71d645e3ee93350eac6ca62104f}{
\index{mln::value::float01@{mln::value::float01}!enc@{enc}}
\index{enc@{enc}!mln::value::float01@{mln::value::float01}}
\subsubsection[{enc}]{\setlength{\rightskip}{0pt plus 5cm}typedef std::pair$<$unsigned, unsigned long$>$ {\bf mln::value::float01::enc}}}
\label{d3/d29/a00419_a53dbc71d645e3ee93350eac6ca62104f}


Encoding associated type. 



Definition at line 61 of file float01.hh.

\hypertarget{a00419_a7fcec3437ee58050178b99758307b476}{
\index{mln::value::float01@{mln::value::float01}!equiv@{equiv}}
\index{equiv@{equiv}!mln::value::float01@{mln::value::float01}}
\subsubsection[{equiv}]{\setlength{\rightskip}{0pt plus 5cm}typedef float {\bf mln::value::float01::equiv}}}
\label{d3/d29/a00419_a7fcec3437ee58050178b99758307b476}


Equivalent associated type. 



Definition at line 64 of file float01.hh.



\subsection{Constructor \& Destructor Documentation}
\hypertarget{a00419_a4c54a202ea4f352d202adc198f0b2d47}{
\index{mln::value::float01@{mln::value::float01}!float01@{float01}}
\index{float01@{float01}!mln::value::float01@{mln::value::float01}}
\subsubsection[{float01}]{\setlength{\rightskip}{0pt plus 5cm}mln::value::float01::float01 (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a4c54a202ea4f352d202adc198f0b2d47}


Ctor. 



Definition at line 151 of file float01.hh.

\hypertarget{a00419_ab28c0e08014a5d3866038edb095daf23}{
\index{mln::value::float01@{mln::value::float01}!float01@{float01}}
\index{float01@{float01}!mln::value::float01@{mln::value::float01}}
\subsubsection[{float01}]{\setlength{\rightskip}{0pt plus 5cm}template$<$unsigned n$>$ mln::value::float01::float01 (
\begin{DoxyParamCaption}
\item[{const float01\_\-$<$ n $>$ \&}]{ val}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_ab28c0e08014a5d3866038edb095daf23}


Ctor. 



Definition at line 158 of file float01.hh.

\hypertarget{a00419_ae3604b585d8dc4c23c813449b37f12a3}{
\index{mln::value::float01@{mln::value::float01}!float01@{float01}}
\index{float01@{float01}!mln::value::float01@{mln::value::float01}}
\subsubsection[{float01}]{\setlength{\rightskip}{0pt plus 5cm}mln::value::float01::float01 (
\begin{DoxyParamCaption}
\item[{unsigned}]{ nbits, }
\item[{float}]{ val}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_ae3604b585d8dc4c23c813449b37f12a3}


Ctor. 



Definition at line 165 of file float01.hh.



\subsection{Member Function Documentation}
\hypertarget{a00419_a90e176b751de8a32d802dce2ce5fcf1c}{
\index{mln::value::float01@{mln::value::float01}!nbits@{nbits}}
\index{nbits@{nbits}!mln::value::float01@{mln::value::float01}}
\subsubsection[{nbits}]{\setlength{\rightskip}{0pt plus 5cm}unsigned mln::value::float01::nbits (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a90e176b751de8a32d802dce2ce5fcf1c}


Access to the encoding size. 



Definition at line 186 of file float01.hh.

\hypertarget{a00419_a57aaff68479ceb307cb3bc83f505b85f}{
\index{mln::value::float01@{mln::value::float01}!operator float@{operator float}}
\index{operator float@{operator float}!mln::value::float01@{mln::value::float01}}
\subsubsection[{operator float}]{\setlength{\rightskip}{0pt plus 5cm}mln::value::float01::operator float (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a57aaff68479ceb307cb3bc83f505b85f}


Conversion to float. 



Definition at line 224 of file float01.hh.

\hypertarget{a00419_a7f0047cd08e3870fc318c210ce135ddc}{
\index{mln::value::float01@{mln::value::float01}!set\_\-nbits@{set\_\-nbits}}
\index{set\_\-nbits@{set\_\-nbits}!mln::value::float01@{mln::value::float01}}
\subsubsection[{set\_\-nbits}]{\setlength{\rightskip}{0pt plus 5cm}{\bf float01} \& mln::value::float01::set\_\-nbits (
\begin{DoxyParamCaption}
\item[{unsigned}]{ nbits}
\end{DoxyParamCaption}
)\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a7f0047cd08e3870fc318c210ce135ddc}


Set the encoding size to nbits. 



Definition at line 193 of file float01.hh.



Referenced by to\_\-nbits().

\hypertarget{a00419_a2579cd4bdb1ca987b420839ff6403a30}{
\index{mln::value::float01@{mln::value::float01}!to\_\-nbits@{to\_\-nbits}}
\index{to\_\-nbits@{to\_\-nbits}!mln::value::float01@{mln::value::float01}}
\subsubsection[{to\_\-nbits}]{\setlength{\rightskip}{0pt plus 5cm}const {\bf float01} mln::value::float01::to\_\-nbits (
\begin{DoxyParamCaption}
\item[{unsigned}]{ nbits}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a2579cd4bdb1ca987b420839ff6403a30}


Return an equivalent gray encoded on {\ttfamily nbits} bits. 



Definition at line 214 of file float01.hh.



References set\_\-nbits().

\hypertarget{a00419_a630cfac2b78237a0c6ed28ed10d84bcd}{
\index{mln::value::float01@{mln::value::float01}!value@{value}}
\index{value@{value}!mln::value::float01@{mln::value::float01}}
\subsubsection[{value}]{\setlength{\rightskip}{0pt plus 5cm}float mln::value::float01::value (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a630cfac2b78237a0c6ed28ed10d84bcd}


Access to std type. 



Definition at line 172 of file float01.hh.

\hypertarget{a00419_a237b3e1876bd42f1c6af4814a1063a74}{
\index{mln::value::float01@{mln::value::float01}!value\_\-ind@{value\_\-ind}}
\index{value\_\-ind@{value\_\-ind}!mln::value::float01@{mln::value::float01}}
\subsubsection[{value\_\-ind}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long mln::value::float01::value\_\-ind (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
) const\hspace{0.3cm}{\ttfamily  \mbox{[}inline\mbox{]}}}}
\label{d3/d29/a00419_a237b3e1876bd42f1c6af4814a1063a74}


Access to the position in the quantized interval. 



Definition at line 179 of file float01.hh.

