\hypertarget{interfacemom__array__transform_1_1rotate__vector}{}\section{mom\+\_\+array\+\_\+transform\+:\+:rotate\+\_\+vector Interface Reference}
\label{interfacemom__array__transform_1_1rotate__vector}\index{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}}


\subsection{Detailed Description}
Rotate an array pair representing the components of a vector. Rotation is applied across the first and second axes of the array. This rotation should be applied when the fields satisfy vector transformation rules. For example, the u and v components of a velocity will map from one to the other for quarter turns, with a sign change in one component. A half turn will map elements onto themselves with sign changes in both components. 

Definition at line 55 of file M\+O\+M\+\_\+array\+\_\+transform.\+F90.

\subsection*{Private functions}
\begin{DoxyCompactItemize}
\item 
subroutine \mbox{\hyperlink{interfacemom__array__transform_1_1rotate__vector_a66b9b3f66a821857b24c80d15a5a8139}{rotate\+\_\+vector\+\_\+real\+\_\+2d}} (A\+\_\+in, B\+\_\+in, turns, A, B)
\begin{DoxyCompactList}\small\item\em Rotate the elements of a 2d real vector along first and second axes. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__array__transform_1_1rotate__vector_a0a22e9772c447f566c205f55507ec88c}{rotate\+\_\+vector\+\_\+real\+\_\+3d}} (A\+\_\+in, B\+\_\+in, turns, A, B)
\begin{DoxyCompactList}\small\item\em Rotate the elements of a 3d real vector along first and second axes. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__array__transform_1_1rotate__vector_aba4772e4bd244862ebf9ff6e62670580}{rotate\+\_\+vector\+\_\+real\+\_\+4d}} (A\+\_\+in, B\+\_\+in, turns, A, B)
\begin{DoxyCompactList}\small\item\em Rotate the elements of a 4d real vector along first and second axes. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Rotate an array pair representing the components of a vector. Rotation is applied across the first and second axes of the array. This rotation should be applied when the fields satisfy vector transformation rules. For example, the u and v components of a velocity will map from one to the other for quarter turns, with a sign change in one component. A half turn will map elements onto themselves with sign changes in both components. 

Definition at line 55 of file M\+O\+M\+\_\+array\+\_\+transform.\+F90.



\subsection{Functions and subroutines}
\mbox{\Hypertarget{interfacemom__array__transform_1_1rotate__vector_a66b9b3f66a821857b24c80d15a5a8139}\label{interfacemom__array__transform_1_1rotate__vector_a66b9b3f66a821857b24c80d15a5a8139}} 
\index{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}!rotate\+\_\+vector\+\_\+real\+\_\+2d@{rotate\+\_\+vector\+\_\+real\+\_\+2d}}
\index{rotate\+\_\+vector\+\_\+real\+\_\+2d@{rotate\+\_\+vector\+\_\+real\+\_\+2d}!mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}}
\subsubsection{\texorpdfstring{rotate\+\_\+vector\+\_\+real\+\_\+2d()}{rotate\_vector\_real\_2d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector\+::rotate\+\_\+vector\+\_\+real\+\_\+2d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:), intent(in)}]{A\+\_\+in,  }\item[{real, dimension(\+:,\+:), intent(in)}]{B\+\_\+in,  }\item[{integer, intent(in)}]{turns,  }\item[{real, dimension(\+:,\+:), intent(out)}]{A,  }\item[{real, dimension(\+:,\+:), intent(out)}]{B }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Rotate the elements of a 2d real vector along first and second axes. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em a\+\_\+in} & First component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em b\+\_\+in} & Second component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em turns} & Number of quarter turns\\
\hline
\mbox{\tt out}  & {\em a} & First component of rotated vector\\
\hline
\mbox{\tt out}  & {\em b} & Second component of unrotated vector \\
\hline
\end{DoxyParams}


Definition at line 231 of file M\+O\+M\+\_\+array\+\_\+transform.\+F90.


\begin{DoxyCode}
231   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: A\_in(:,:)\textcolor{comment}{ !< First component of unrotated vector}
232   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: B\_in(:,:)\textcolor{comment}{ !< Second component of unrotated vector}
233   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)} :: turns\textcolor{comment}{  !< Number of quarter turns}
234   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: A(:,:)\textcolor{comment}{   !< First component of rotated vector}
235   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: B(:,:)\textcolor{comment}{   !< Second component of unrotated vector}
236 
237   \textcolor{keyword}{call }rotate\_array\_pair(a\_in, b\_in, turns, a, b)
238 
239   \textcolor{keywordflow}{if} (modulo(turns, 4) == 1 .or. modulo(turns, 4) == 2) &
240     a(:,:) = -a(:,:)
241 
242   \textcolor{keywordflow}{if} (modulo(turns, 4) == 2 .or. modulo(turns, 4) == 3) &
243     b(:,:) = -b(:,:)
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__array__transform_1_1rotate__vector_a0a22e9772c447f566c205f55507ec88c}\label{interfacemom__array__transform_1_1rotate__vector_a0a22e9772c447f566c205f55507ec88c}} 
\index{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}!rotate\+\_\+vector\+\_\+real\+\_\+3d@{rotate\+\_\+vector\+\_\+real\+\_\+3d}}
\index{rotate\+\_\+vector\+\_\+real\+\_\+3d@{rotate\+\_\+vector\+\_\+real\+\_\+3d}!mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}}
\subsubsection{\texorpdfstring{rotate\+\_\+vector\+\_\+real\+\_\+3d()}{rotate\_vector\_real\_3d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector\+::rotate\+\_\+vector\+\_\+real\+\_\+3d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:), intent(in)}]{A\+\_\+in,  }\item[{real, dimension(\+:,\+:,\+:), intent(in)}]{B\+\_\+in,  }\item[{integer, intent(in)}]{turns,  }\item[{real, dimension(\+:,\+:,\+:), intent(out)}]{A,  }\item[{real, dimension(\+:,\+:,\+:), intent(out)}]{B }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Rotate the elements of a 3d real vector along first and second axes. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em a\+\_\+in} & First component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em b\+\_\+in} & Second component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em turns} & Number of quarter turns\\
\hline
\mbox{\tt out}  & {\em a} & First component of rotated vector\\
\hline
\mbox{\tt out}  & {\em b} & Second component of unrotated vector \\
\hline
\end{DoxyParams}


Definition at line 249 of file M\+O\+M\+\_\+array\+\_\+transform.\+F90.


\begin{DoxyCode}
249   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: A\_in(:,:,:)\textcolor{comment}{ !< First component of unrotated vector}
250   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: B\_in(:,:,:)\textcolor{comment}{ !< Second component of unrotated vector}
251   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)} :: turns\textcolor{comment}{    !< Number of quarter turns}
252   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: A(:,:,:)\textcolor{comment}{   !< First component of rotated vector}
253   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: B(:,:,:)\textcolor{comment}{   !< Second component of unrotated vector}
254 
255   \textcolor{keywordtype}{integer} :: k
256 
257   \textcolor{keywordflow}{do} k = 1, \textcolor{keyword}{size}(a\_in, 3)
258     \textcolor{keyword}{call }rotate\_vector(a\_in(:,:,k), b\_in(:,:,k), turns, a(:,:,k), b(:,:,k))
259 \textcolor{keywordflow}{  enddo}
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__array__transform_1_1rotate__vector_aba4772e4bd244862ebf9ff6e62670580}\label{interfacemom__array__transform_1_1rotate__vector_aba4772e4bd244862ebf9ff6e62670580}} 
\index{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}!rotate\+\_\+vector\+\_\+real\+\_\+4d@{rotate\+\_\+vector\+\_\+real\+\_\+4d}}
\index{rotate\+\_\+vector\+\_\+real\+\_\+4d@{rotate\+\_\+vector\+\_\+real\+\_\+4d}!mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector@{mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector}}
\subsubsection{\texorpdfstring{rotate\+\_\+vector\+\_\+real\+\_\+4d()}{rotate\_vector\_real\_4d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+array\+\_\+transform\+::rotate\+\_\+vector\+::rotate\+\_\+vector\+\_\+real\+\_\+4d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:,\+:), intent(in)}]{A\+\_\+in,  }\item[{real, dimension(\+:,\+:,\+:,\+:), intent(in)}]{B\+\_\+in,  }\item[{integer, intent(in)}]{turns,  }\item[{real, dimension(\+:,\+:,\+:,\+:), intent(out)}]{A,  }\item[{real, dimension(\+:,\+:,\+:,\+:), intent(out)}]{B }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Rotate the elements of a 4d real vector along first and second axes. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em a\+\_\+in} & First component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em b\+\_\+in} & Second component of unrotated vector\\
\hline
\mbox{\tt in}  & {\em turns} & Number of quarter turns\\
\hline
\mbox{\tt out}  & {\em a} & First component of rotated vector\\
\hline
\mbox{\tt out}  & {\em b} & Second component of unrotated vector \\
\hline
\end{DoxyParams}


Definition at line 265 of file M\+O\+M\+\_\+array\+\_\+transform.\+F90.


\begin{DoxyCode}
265   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: A\_in(:,:,:,:)\textcolor{comment}{ !< First component of unrotated vector}
266   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(in)} :: B\_in(:,:,:,:)\textcolor{comment}{ !< Second component of unrotated vector}
267   \textcolor{keywordtype}{integer}, \textcolor{keywordtype}{intent(in)} :: turns\textcolor{comment}{      !< Number of quarter turns}
268   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: A(:,:,:,:)\textcolor{comment}{   !< First component of rotated vector}
269   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{intent(out)} :: B(:,:,:,:)\textcolor{comment}{   !< Second component of unrotated vector}
270 
271   \textcolor{keywordtype}{integer} :: n
272 
273   \textcolor{keywordflow}{do} n = 1, \textcolor{keyword}{size}(a\_in, 4)
274     \textcolor{keyword}{call }rotate\_vector(a\_in(:,:,:,n), b\_in(:,:,:,n), turns, &
275         a(:,:,:,n), b(:,:,:,n))
276 \textcolor{keywordflow}{  enddo}
\end{DoxyCode}


The documentation for this interface was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
/home/cermak/src/\+M\+O\+M6.\+devrob/src/framework/M\+O\+M\+\_\+array\+\_\+transform.\+F90\end{DoxyCompactItemize}
