\section{gear\-:\-:Material\-Map\-Factory Class Reference}
\label{classgear_1_1MaterialMapFactory}\index{gear\-::\-Material\-Map\-Factory@{gear\-::\-Material\-Map\-Factory}}


Factory to create material maps using \doxyref{Gear\-Distance\-Properties}{p.}{classgear_1_1GearDistanceProperties}.  




{\ttfamily \#include $<$Material\-Map\-Factory.\-h$>$}

\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
{\bfseries Material\-Map\-Factory} ({\bf Gear\-Mgr} $\ast$gear\-Mgr)\label{classgear_1_1MaterialMapFactory_a4d81eb13ead14ca80fdf2a9243daa682}

\item 
virtual {\bf $\sim$\-Material\-Map\-Factory} ()\label{classgear_1_1MaterialMapFactory_a107fd10abcacb8749b6356ac69c24218}

\begin{DoxyCompactList}\small\item\em Destructor. \end{DoxyCompactList}\item 
{\bf Material\-Map} $\ast$ {\bf create\-Material\-Map} (double xmin, double xmax, int nxsteps, double ymin, double ymax, int nysteps, double zmin, double zmax, int nzsteps, int coord)
\begin{DoxyCompactList}\small\item\em Creating a material map in memory. \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Protected Attributes}
\begin{DoxyCompactItemize}
\item 
{\bf Gear\-Mgr} $\ast$ {\bfseries \-\_\-gear\-Mgr}\label{classgear_1_1MaterialMapFactory_a1e3935c165f3f68dfa4dafaeb73f0732}

\item 
std\-::map$<$ std\-::vector$<$ double $>$\\*
, {\bf Material\-Map} $\ast$ $>$ {\bfseries \-\_\-manager\-Map}\label{classgear_1_1MaterialMapFactory_a01116319324f9d8aeee22bdf533314e6}

\end{DoxyCompactItemize}


\subsection{Detailed Description}
Factory to create material maps using \doxyref{Gear\-Distance\-Properties}{p.}{classgear_1_1GearDistanceProperties}. 

\begin{DoxyAuthor}{Author}
A. Muennich, C\-E\-R\-N The intention of this utility is to save computing time, if an application has to call \doxyref{Gear\-Distance\-Properties}{p.}{classgear_1_1GearDistanceProperties} 1000s of times it is slow. If the application can live with some approximation of material budget thi utility provides a map of the material in memory that can then be querried by the application. The creation of the map happens once and will take some time, but its usage by the application is then fast. The idea is to use the factory to create a map in the interseting region which the precision required. If possible one should make use of detector symmetries to limit the size of the map and gaining in computing time or invest in more granularity. Run time examples\-: If \doxyref{Gear\-Distance\-Properties}{p.}{classgear_1_1GearDistanceProperties} are implemented with T\-Geo my\-Map\-Factory-\/$>$create\-Material\-Map(-\/200,200, 10,-\/200,200,10 ,-\/200, 200, 10, 0) takes 7.\-2 s for 1331 entries (10x10x10 steps), 5 s of that is needed to load in the geometry from gdml into R\-O\-O\-T. Creating a map with 100x10x10 takes 22s and 100x100x100 already 28 min. 
\end{DoxyAuthor}
\begin{DoxyVersion}{Version}

\end{DoxyVersion}
\begin{DoxyParagraph}{Id\-:}
\doxyref{Material\-Map\-Factory.\-h}{p.}{MaterialMapFactory_8h_source} 380 2011-\/08-\/26 12\-:24\-:46\-Z gaede 
\end{DoxyParagraph}


Definition at line 30 of file Material\-Map\-Factory.\-h.



\subsection{Member Function Documentation}
\index{gear\-::\-Material\-Map\-Factory@{gear\-::\-Material\-Map\-Factory}!create\-Material\-Map@{create\-Material\-Map}}
\index{create\-Material\-Map@{create\-Material\-Map}!gear::MaterialMapFactory@{gear\-::\-Material\-Map\-Factory}}
\subsubsection[{create\-Material\-Map}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Material\-Map} $\ast$ gear\-::\-Material\-Map\-Factory\-::create\-Material\-Map (
\begin{DoxyParamCaption}
\item[{double}]{xmin, }
\item[{double}]{xmax, }
\item[{int}]{nxsteps, }
\item[{double}]{ymin, }
\item[{double}]{ymax, }
\item[{int}]{nysteps, }
\item[{double}]{zmin, }
\item[{double}]{zmax, }
\item[{int}]{nzsteps, }
\item[{int}]{coord}
\end{DoxyParamCaption}
)}\label{classgear_1_1MaterialMapFactory_a4336a66033c6f736356224e34501fc38}


Creating a material map in memory. 

Three coordinate systems are supported\-: coord=0 \-: C\-A\-R\-T\-E\-S\-I\-A\-N (x,y,z) coord=1 \-: C\-Y\-L\-I\-N\-D\-R\-I\-C\-A\-L (r,phi,z) with r$>$0, 0$<$phi$<$2\-Pi coord=2 \-: S\-P\-E\-R\-I\-C\-A\-L (r,theta,phi) with r$>$0, 0$<$theta$<$Pi 0$<$phi$<$2\-Pi With min and max the beginning and the end are defined and step is the number of steps that defines the granularity of the map. 

Definition at line 14 of file Material\-Map\-Factory.\-cc.



The documentation for this class was generated from the following files\-:\begin{DoxyCompactItemize}
\item 
Material\-Map\-Factory.\-h\item 
Material\-Map\-Factory.\-cc\end{DoxyCompactItemize}
