\hypertarget{interfacemom__debugging_1_1check__redundant__b}{}\doxysection{mom\+\_\+debugging\+::check\+\_\+redundant\+\_\+b Interface Reference}
\label{interfacemom__debugging_1_1check__redundant__b}\index{mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}}


\doxysubsection{Detailed Description}
Check for consistency between the duplicated points of a B-\/grid vector or scalar. 

Definition at line 41 of file M\+O\+M\+\_\+debugging.\+F90.

\doxysubsection*{Private functions}
\begin{DoxyCompactItemize}
\item 
subroutine \mbox{\hyperlink{interfacemom__debugging_1_1check__redundant__b_a56967d708c3e74dc2d55d3d36e908f6c}{check\+\_\+redundant\+\_\+vb3d}} (mesg, u\+\_\+comp, v\+\_\+comp, G, is, ie, js, je, direction)
\begin{DoxyCompactList}\small\item\em Check for consistency between the duplicated points of a 3-\/D B-\/grid vector. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__debugging_1_1check__redundant__b_a2c8ef9557d48b4923c6000a617420904}{check\+\_\+redundant\+\_\+vb2d}} (mesg, u\+\_\+comp, v\+\_\+comp, G, is, ie, js, je, direction)
\begin{DoxyCompactList}\small\item\em Check for consistency between the duplicated points of a 2-\/D B-\/grid vector. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__debugging_1_1check__redundant__b_a7090c768bf3fff64104af2dc58228bed}{check\+\_\+redundant\+\_\+sb3d}} (mesg, array, G, is, ie, js, je)
\begin{DoxyCompactList}\small\item\em Check for consistency between the duplicated points of a 3-\/D scalar at corner points. \end{DoxyCompactList}\item 
subroutine \mbox{\hyperlink{interfacemom__debugging_1_1check__redundant__b_a4ab3f8caf17f1ada504efe4e431d3519}{check\+\_\+redundant\+\_\+sb2d}} (mesg, array, G, is, ie, js, je)
\begin{DoxyCompactList}\small\item\em Check for consistency between the duplicated points of a 2-\/D scalar at corner points. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
Check for consistency between the duplicated points of a B-\/grid vector or scalar. 

Definition at line 41 of file M\+O\+M\+\_\+debugging.\+F90.



\doxysubsection{Functions and subroutines}
\mbox{\Hypertarget{interfacemom__debugging_1_1check__redundant__b_a4ab3f8caf17f1ada504efe4e431d3519}\label{interfacemom__debugging_1_1check__redundant__b_a4ab3f8caf17f1ada504efe4e431d3519}} 
\index{mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}!check\_redundant\_sb2d@{check\_redundant\_sb2d}}
\index{check\_redundant\_sb2d@{check\_redundant\_sb2d}!mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}}
\doxysubsubsection{\texorpdfstring{check\_redundant\_sb2d()}{check\_redundant\_sb2d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+debugging\+::check\+\_\+redundant\+\_\+b\+::check\+\_\+redundant\+\_\+sb2d (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{mesg,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:), intent(in)}]{array,  }\item[{type(ocean\+\_\+grid\+\_\+type), intent(inout)}]{G,  }\item[{integer, intent(in), optional}]{is,  }\item[{integer, intent(in), optional}]{ie,  }\item[{integer, intent(in), optional}]{js,  }\item[{integer, intent(in), optional}]{je }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Check for consistency between the duplicated points of a 2-\/D scalar at corner points. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em mesg} & An identifying message \\
\hline
\mbox{\texttt{ in,out}}  & {\em g} & The ocean\textquotesingle{}s grid structure \\
\hline
\mbox{\texttt{ in}}  & {\em array} & The array to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em is} & The starting i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em ie} & The ending i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em js} & The starting j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em je} & The ending j-\/index to check \\
\hline
\end{DoxyParams}


Definition at line 235 of file M\+O\+M\+\_\+debugging.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{236   \textcolor{keywordtype}{character(len=*)},                 \textcolor{keywordtype}{intent(in)}    :: mesg\textcolor{comment}{  !< An identifying message}}
\DoxyCodeLine{237   \textcolor{keywordtype}{type}(ocean\_grid\_type),            \textcolor{keywordtype}{intent(inout)} :: G\textcolor{comment}{     !< The ocean's grid structure}}
\DoxyCodeLine{238 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:)}, \textcolor{keywordtype}{intent(in)}    :: array\textcolor{comment}{ !< The array to be checked for consistency}}
\DoxyCodeLine{239   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: is\textcolor{comment}{    !< The starting i-\/index to check}}
\DoxyCodeLine{240   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: ie\textcolor{comment}{    !< The ending i-\/index to check}}
\DoxyCodeLine{241   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: js\textcolor{comment}{    !< The starting j-\/index to check}}
\DoxyCodeLine{242   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: je\textcolor{comment}{    !< The ending j-\/index to check}}
\DoxyCodeLine{243   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{244 \textcolor{keywordtype}{  real} :: a\_nonsym(G\%isd:G\%ied,G\%jsd:G\%jed)}
\DoxyCodeLine{245 \textcolor{keywordtype}{  real} :: a\_resym(G\%IsdB:G\%IedB,G\%JsdB:G\%JedB)}
\DoxyCodeLine{246   \textcolor{keywordtype}{character(len=128)} :: mesg2}
\DoxyCodeLine{247   \textcolor{keywordtype}{integer} :: i, j, is\_ch, ie\_ch, js\_ch, je\_ch}
\DoxyCodeLine{248   \textcolor{keywordtype}{integer} :: Isq, Ieq, Jsq, Jeq, isd, ied, jsd, jed, IsdB, IedB, JsdB, JedB}
\DoxyCodeLine{249 }
\DoxyCodeLine{250   isq = g\%IscB ; ieq = g\%IecB ; jsq = g\%JscB ; jeq = g\%JecB}
\DoxyCodeLine{251   isd = g\%isd ; ied = g\%ied ; jsd = g\%jsd ; jed = g\%jed}
\DoxyCodeLine{252   isdb = g\%IsdB ; iedb = g\%IedB ; jsdb = g\%JsdB ; jedb = g\%JedB}
\DoxyCodeLine{253 }
\DoxyCodeLine{254   \textcolor{keywordflow}{if} (.not.(\textcolor{keyword}{present}(is) .or. \textcolor{keyword}{present}(ie) .or. \textcolor{keyword}{present}(js) .or. \textcolor{keyword}{present}(je))) \textcolor{keywordflow}{then}}
\DoxyCodeLine{255     \textcolor{comment}{! This only works with symmetric memory, so otherwise return.}}
\DoxyCodeLine{256     \textcolor{keywordflow}{if} ((isd == isdb) .and. (jsd == jsdb)) \textcolor{keywordflow}{return}}
\DoxyCodeLine{257 \textcolor{keywordflow}{  endif}}
\DoxyCodeLine{258 }
\DoxyCodeLine{259   \textcolor{keywordflow}{do} i=isd,ied ; \textcolor{keywordflow}{do} j=jsd,jed}
\DoxyCodeLine{260     a\_nonsym(i,j) = array(i,j)}
\DoxyCodeLine{261 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{262 }
\DoxyCodeLine{263   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(g\%Domain\_aux)) \textcolor{keyword}{call }mom\_error(fatal,\textcolor{stringliteral}{" check\_redundant"}//\&}
\DoxyCodeLine{264     \textcolor{stringliteral}{" called with a non-\/associated auxiliary domain the grid type."})}
\DoxyCodeLine{265   \textcolor{keyword}{call }pass\_vector(a\_nonsym, a\_nonsym, g\%Domain\_aux, \&}
\DoxyCodeLine{266                    direction=to\_all+scalar\_pair, stagger=bgrid\_ne)}
\DoxyCodeLine{267 }
\DoxyCodeLine{268   \textcolor{keywordflow}{do} i=isdb,iedb ; \textcolor{keywordflow}{do} j=jsdb,jedb ; a\_resym(i,j) = array(i,j) ;\textcolor{keywordflow}{ enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{269   \textcolor{keywordflow}{do} i=isd,ied ; \textcolor{keywordflow}{do} j=jsd,jed}
\DoxyCodeLine{270     a\_resym(i,j) = a\_nonsym(i,j)}
\DoxyCodeLine{271 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{272   \textcolor{keyword}{call }pass\_vector(a\_resym, a\_resym, g\%Domain, direction=to\_all+scalar\_pair, \&}
\DoxyCodeLine{273                    stagger=bgrid\_ne)}
\DoxyCodeLine{274 }
\DoxyCodeLine{275   is\_ch = isq ; ie\_ch = ieq ; js\_ch = jsq ; je\_ch = jeq}
\DoxyCodeLine{276   \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(is)) is\_ch = is ; \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(ie)) ie\_ch = ie}
\DoxyCodeLine{277   \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(js)) js\_ch = js ; \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(js)) je\_ch = je}
\DoxyCodeLine{278 }
\DoxyCodeLine{279   \textcolor{keywordflow}{do} i=is\_ch,ie\_ch ; \textcolor{keywordflow}{do} j=js\_ch,je\_ch}
\DoxyCodeLine{280     \textcolor{keywordflow}{if} (a\_resym(i,j) /= array(i,j) .and. \&}
\DoxyCodeLine{281         redundant\_prints(2) < max\_redundant\_prints) \textcolor{keywordflow}{then}}
\DoxyCodeLine{282       \textcolor{keyword}{write}(mesg2,\textcolor{stringliteral}{'(" Redundant points",2(1pe12.4)," differ by ", \&}}
\DoxyCodeLine{283 \textcolor{stringliteral}{}\textcolor{stringliteral}{                    \& 1pe12.4," at i,j = ",2i4," on pe ",i4)'}) \&}
\DoxyCodeLine{284            array(i,j), a\_resym(i,j),array(i,j)-\/a\_resym(i,j),i,j,pe\_here()}
\DoxyCodeLine{285       \textcolor{keyword}{write}(0,\textcolor{stringliteral}{'(A130)'}) trim(mesg)//trim(mesg2)}
\DoxyCodeLine{286       redundant\_prints(2) = redundant\_prints(2) + 1}
\DoxyCodeLine{287 \textcolor{keywordflow}{    endif}}
\DoxyCodeLine{288 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{289 }

\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__debugging_1_1check__redundant__b_a7090c768bf3fff64104af2dc58228bed}\label{interfacemom__debugging_1_1check__redundant__b_a7090c768bf3fff64104af2dc58228bed}} 
\index{mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}!check\_redundant\_sb3d@{check\_redundant\_sb3d}}
\index{check\_redundant\_sb3d@{check\_redundant\_sb3d}!mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}}
\doxysubsubsection{\texorpdfstring{check\_redundant\_sb3d()}{check\_redundant\_sb3d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+debugging\+::check\+\_\+redundant\+\_\+b\+::check\+\_\+redundant\+\_\+sb3d (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{mesg,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:,\+:), intent(in)}]{array,  }\item[{type(ocean\+\_\+grid\+\_\+type), intent(inout)}]{G,  }\item[{integer, intent(in), optional}]{is,  }\item[{integer, intent(in), optional}]{ie,  }\item[{integer, intent(in), optional}]{js,  }\item[{integer, intent(in), optional}]{je }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Check for consistency between the duplicated points of a 3-\/D scalar at corner points. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em mesg} & An identifying message \\
\hline
\mbox{\texttt{ in,out}}  & {\em g} & The ocean\textquotesingle{}s grid structure \\
\hline
\mbox{\texttt{ in}}  & {\em array} & The array to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em is} & The starting i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em ie} & The ending i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em js} & The starting j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em je} & The ending j-\/index to check \\
\hline
\end{DoxyParams}


Definition at line 210 of file M\+O\+M\+\_\+debugging.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{211   \textcolor{keywordtype}{character(len=*)},                     \textcolor{keywordtype}{intent(in)}    :: mesg\textcolor{comment}{  !< An identifying message}}
\DoxyCodeLine{212   \textcolor{keywordtype}{type}(ocean\_grid\_type),                \textcolor{keywordtype}{intent(inout)} :: G\textcolor{comment}{     !< The ocean's grid structure}}
\DoxyCodeLine{213 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:,:)},   \textcolor{keywordtype}{intent(in)}    :: array\textcolor{comment}{ !< The array to be checked for consistency}}
\DoxyCodeLine{214   \textcolor{keywordtype}{integer},                    \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: is\textcolor{comment}{    !< The starting i-\/index to check}}
\DoxyCodeLine{215   \textcolor{keywordtype}{integer},                    \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: ie\textcolor{comment}{    !< The ending i-\/index to check}}
\DoxyCodeLine{216   \textcolor{keywordtype}{integer},                    \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: js\textcolor{comment}{    !< The starting j-\/index to check}}
\DoxyCodeLine{217   \textcolor{keywordtype}{integer},                    \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: je\textcolor{comment}{    !< The ending j-\/index to check}}
\DoxyCodeLine{218 }
\DoxyCodeLine{219   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{220   \textcolor{keywordtype}{character(len=24)} :: mesg\_k}
\DoxyCodeLine{221   \textcolor{keywordtype}{integer} :: k}
\DoxyCodeLine{222 }
\DoxyCodeLine{223   \textcolor{keywordflow}{do} k=1,\textcolor{keyword}{size}(array,3)}
\DoxyCodeLine{224     \textcolor{keywordflow}{if} (k < 10) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i2," ")'}) k}
\DoxyCodeLine{225     \textcolor{keywordflow}{elseif} (k < 100) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i3," ")'}) k}
\DoxyCodeLine{226     \textcolor{keywordflow}{elseif} (k < 1000) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i4," ")'}) k}
\DoxyCodeLine{227     \textcolor{keywordflow}{else} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i9," ")'}) k ;\textcolor{keywordflow}{ endif}}
\DoxyCodeLine{228 }
\DoxyCodeLine{229     \textcolor{keyword}{call }check\_redundant\_sb2d(trim(mesg)//trim(mesg\_k), array(:,:,k), \&}
\DoxyCodeLine{230                               g, is, ie, js, je)}
\DoxyCodeLine{231 \textcolor{keywordflow}{  enddo}}

\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__debugging_1_1check__redundant__b_a2c8ef9557d48b4923c6000a617420904}\label{interfacemom__debugging_1_1check__redundant__b_a2c8ef9557d48b4923c6000a617420904}} 
\index{mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}!check\_redundant\_vb2d@{check\_redundant\_vb2d}}
\index{check\_redundant\_vb2d@{check\_redundant\_vb2d}!mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}}
\doxysubsubsection{\texorpdfstring{check\_redundant\_vb2d()}{check\_redundant\_vb2d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+debugging\+::check\+\_\+redundant\+\_\+b\+::check\+\_\+redundant\+\_\+vb2d (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{mesg,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:), intent(in)}]{u\+\_\+comp,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:), intent(in)}]{v\+\_\+comp,  }\item[{type(ocean\+\_\+grid\+\_\+type), intent(inout)}]{G,  }\item[{integer, intent(in), optional}]{is,  }\item[{integer, intent(in), optional}]{ie,  }\item[{integer, intent(in), optional}]{js,  }\item[{integer, intent(in), optional}]{je,  }\item[{integer, intent(in), optional}]{direction }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Check for consistency between the duplicated points of a 2-\/D B-\/grid vector. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em mesg} & An identifying message \\
\hline
\mbox{\texttt{ in,out}}  & {\em g} & The ocean\textquotesingle{}s grid structure \\
\hline
\mbox{\texttt{ in}}  & {\em u\+\_\+comp} & The u-\/component of the vector to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em v\+\_\+comp} & The v-\/component of the vector to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em is} & The starting i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em ie} & The ending i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em js} & The starting j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em je} & The ending j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em direction} & the direction flag to be passed to pass\+\_\+vector \\
\hline
\end{DoxyParams}


Definition at line 323 of file M\+O\+M\+\_\+debugging.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{325   \textcolor{keywordtype}{character(len=*)},                 \textcolor{keywordtype}{intent(in)}    :: mesg\textcolor{comment}{   !< An identifying message}}
\DoxyCodeLine{326   \textcolor{keywordtype}{type}(ocean\_grid\_type),            \textcolor{keywordtype}{intent(inout)} :: G\textcolor{comment}{      !< The ocean's grid structure}}
\DoxyCodeLine{327 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:)}, \textcolor{keywordtype}{intent(in)}    :: u\_comp\textcolor{comment}{ !< The u-\/component of the vector}}
\DoxyCodeLine{328 \textcolor{comment}{                                                            !! to be checked for consistency}}
\DoxyCodeLine{329 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:)}, \textcolor{keywordtype}{intent(in)}    :: v\_comp\textcolor{comment}{ !< The v-\/component of the vector}}
\DoxyCodeLine{330 \textcolor{comment}{                                                            !! to be checked for consistency}}
\DoxyCodeLine{331   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: is\textcolor{comment}{     !< The starting i-\/index to check}}
\DoxyCodeLine{332   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: ie\textcolor{comment}{     !< The ending i-\/index to check}}
\DoxyCodeLine{333   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: js\textcolor{comment}{     !< The starting j-\/index to check}}
\DoxyCodeLine{334   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: je\textcolor{comment}{     !< The ending j-\/index to check}}
\DoxyCodeLine{335   \textcolor{keywordtype}{integer},                \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: direction\textcolor{comment}{ !< the direction flag to be}}
\DoxyCodeLine{336 \textcolor{comment}{                                                            !! passed to pass\_vector}}
\DoxyCodeLine{337   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{338 \textcolor{keywordtype}{  real} :: u\_nonsym(G\%isd:G\%ied,G\%jsd:G\%jed)}
\DoxyCodeLine{339 \textcolor{keywordtype}{  real} :: v\_nonsym(G\%isd:G\%ied,G\%jsd:G\%jed)}
\DoxyCodeLine{340 \textcolor{keywordtype}{  real} :: u\_resym(G\%IsdB:G\%IedB,G\%JsdB:G\%JedB)}
\DoxyCodeLine{341 \textcolor{keywordtype}{  real} :: v\_resym(G\%IsdB:G\%IedB,G\%JsdB:G\%JedB)}
\DoxyCodeLine{342   \textcolor{keywordtype}{character(len=128)} :: mesg2}
\DoxyCodeLine{343   \textcolor{keywordtype}{integer} :: i, j, is\_ch, ie\_ch, js\_ch, je\_ch}
\DoxyCodeLine{344   \textcolor{keywordtype}{integer} :: Isq, Ieq, Jsq, Jeq, isd, ied, jsd, jed, IsdB, IedB, JsdB, JedB}
\DoxyCodeLine{345 }
\DoxyCodeLine{346   isq = g\%IscB ; ieq = g\%IecB ; jsq = g\%JscB ; jeq = g\%JecB}
\DoxyCodeLine{347   isd = g\%isd ; ied = g\%ied ; jsd = g\%jsd ; jed = g\%jed}
\DoxyCodeLine{348   isdb = g\%IsdB ; iedb = g\%IedB ; jsdb = g\%JsdB ; jedb = g\%JedB}
\DoxyCodeLine{349 }
\DoxyCodeLine{350   \textcolor{keywordflow}{if} (.not.(\textcolor{keyword}{present}(is) .or. \textcolor{keyword}{present}(ie) .or. \textcolor{keyword}{present}(js) .or. \textcolor{keyword}{present}(je))) \textcolor{keywordflow}{then}}
\DoxyCodeLine{351     \textcolor{comment}{! This only works with symmetric memory, so otherwise return.}}
\DoxyCodeLine{352     \textcolor{keywordflow}{if} ((isd == isdb) .and. (jsd == jsdb)) \textcolor{keywordflow}{return}}
\DoxyCodeLine{353 \textcolor{keywordflow}{  endif}}
\DoxyCodeLine{354 }
\DoxyCodeLine{355   \textcolor{keywordflow}{do} i=isd,ied ; \textcolor{keywordflow}{do} j=jsd,jed}
\DoxyCodeLine{356     u\_nonsym(i,j) = u\_comp(i,j) ; v\_nonsym(i,j) = v\_comp(i,j)}
\DoxyCodeLine{357 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{358 }
\DoxyCodeLine{359   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(g\%Domain\_aux)) \textcolor{keyword}{call }mom\_error(fatal,\textcolor{stringliteral}{" check\_redundant"}//\&}
\DoxyCodeLine{360     \textcolor{stringliteral}{" called with a non-\/associated auxiliary domain the grid type."})}
\DoxyCodeLine{361   \textcolor{keyword}{call }pass\_vector(u\_nonsym, v\_nonsym, g\%Domain\_aux, direction, stagger=bgrid\_ne)}
\DoxyCodeLine{362 }
\DoxyCodeLine{363   \textcolor{keywordflow}{do} i=isdb,iedb ; \textcolor{keywordflow}{do} j=jsdb,jedb}
\DoxyCodeLine{364     u\_resym(i,j) = u\_comp(i,j) ; v\_resym(i,j) = v\_comp(i,j)}
\DoxyCodeLine{365 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{366   \textcolor{keywordflow}{do} i=isd,ied ; \textcolor{keywordflow}{do} j=jsd,jed}
\DoxyCodeLine{367     u\_resym(i,j) = u\_nonsym(i,j) ; v\_resym(i,j) = v\_nonsym(i,j)}
\DoxyCodeLine{368 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{369   \textcolor{keyword}{call }pass\_vector(u\_resym, v\_resym, g\%Domain, direction, stagger=bgrid\_ne)}
\DoxyCodeLine{370 }
\DoxyCodeLine{371   is\_ch = isq ; ie\_ch = ieq ; js\_ch = jsq ; je\_ch = jeq}
\DoxyCodeLine{372   \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(is)) is\_ch = is ; \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(ie)) ie\_ch = ie}
\DoxyCodeLine{373   \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(js)) js\_ch = js ; \textcolor{keywordflow}{if} (\textcolor{keyword}{present}(js)) je\_ch = je}
\DoxyCodeLine{374 }
\DoxyCodeLine{375   \textcolor{keywordflow}{do} i=is\_ch,ie\_ch ; \textcolor{keywordflow}{do} j=js\_ch,je\_ch}
\DoxyCodeLine{376     \textcolor{keywordflow}{if} (u\_resym(i,j) /= u\_comp(i,j) .and. \&}
\DoxyCodeLine{377         redundant\_prints(2) < max\_redundant\_prints) \textcolor{keywordflow}{then}}
\DoxyCodeLine{378       \textcolor{keyword}{write}(mesg2,\textcolor{stringliteral}{'(" redundant u-\/components",2(1pe12.4)," differ by ", \&}}
\DoxyCodeLine{379 \textcolor{stringliteral}{}\textcolor{stringliteral}{                    \& 1pe12.4," at i,j = ",2i4," on pe ",i4)'}) \&}
\DoxyCodeLine{380            u\_comp(i,j), u\_resym(i,j),u\_comp(i,j)-\/u\_resym(i,j),i,j,pe\_here()}
\DoxyCodeLine{381       \textcolor{keyword}{write}(0,\textcolor{stringliteral}{'(A130)'}) trim(mesg)//trim(mesg2)}
\DoxyCodeLine{382       redundant\_prints(2) = redundant\_prints(2) + 1}
\DoxyCodeLine{383 \textcolor{keywordflow}{    endif}}
\DoxyCodeLine{384 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{385   \textcolor{keywordflow}{do} i=is\_ch,ie\_ch ; \textcolor{keywordflow}{do} j=js\_ch,je\_ch}
\DoxyCodeLine{386     \textcolor{keywordflow}{if} (v\_resym(i,j) /= v\_comp(i,j) .and. \&}
\DoxyCodeLine{387         redundant\_prints(2) < max\_redundant\_prints) \textcolor{keywordflow}{then}}
\DoxyCodeLine{388       \textcolor{keyword}{write}(mesg2,\textcolor{stringliteral}{'(" redundant v-\/comps",2(1pe12.4)," differ by ", \&}}
\DoxyCodeLine{389 \textcolor{stringliteral}{}\textcolor{stringliteral}{                    \& 1pe12.4," at i,j = ",2i4," x,y = ",2(1pe12.4)" on pe ",i4)'}) \&}
\DoxyCodeLine{390            v\_comp(i,j), v\_resym(i,j),v\_comp(i,j)-\/v\_resym(i,j),i,j, \&}
\DoxyCodeLine{391            g\%geoLonBu(i,j), g\%geoLatBu(i,j), pe\_here()}
\DoxyCodeLine{392       \textcolor{keyword}{write}(0,\textcolor{stringliteral}{'(A155)'}) trim(mesg)//trim(mesg2)}
\DoxyCodeLine{393       redundant\_prints(2) = redundant\_prints(2) + 1}
\DoxyCodeLine{394 \textcolor{keywordflow}{    endif}}
\DoxyCodeLine{395 \textcolor{keywordflow}{  enddo} ;\textcolor{keywordflow}{ enddo}}
\DoxyCodeLine{396 }

\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__debugging_1_1check__redundant__b_a56967d708c3e74dc2d55d3d36e908f6c}\label{interfacemom__debugging_1_1check__redundant__b_a56967d708c3e74dc2d55d3d36e908f6c}} 
\index{mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}!check\_redundant\_vb3d@{check\_redundant\_vb3d}}
\index{check\_redundant\_vb3d@{check\_redundant\_vb3d}!mom\_debugging::check\_redundant\_b@{mom\_debugging::check\_redundant\_b}}
\doxysubsubsection{\texorpdfstring{check\_redundant\_vb3d()}{check\_redundant\_vb3d()}}
{\footnotesize\ttfamily subroutine mom\+\_\+debugging\+::check\+\_\+redundant\+\_\+b\+::check\+\_\+redundant\+\_\+vb3d (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{mesg,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:,\+:), intent(in)}]{u\+\_\+comp,  }\item[{real, dimension(g\%isdb\+:,g\%jsdb\+:,\+:), intent(in)}]{v\+\_\+comp,  }\item[{type(ocean\+\_\+grid\+\_\+type), intent(inout)}]{G,  }\item[{integer, intent(in), optional}]{is,  }\item[{integer, intent(in), optional}]{ie,  }\item[{integer, intent(in), optional}]{js,  }\item[{integer, intent(in), optional}]{je,  }\item[{integer, intent(in), optional}]{direction }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Check for consistency between the duplicated points of a 3-\/D B-\/grid vector. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\texttt{ in}}  & {\em mesg} & An identifying message \\
\hline
\mbox{\texttt{ in,out}}  & {\em g} & The ocean\textquotesingle{}s grid structure \\
\hline
\mbox{\texttt{ in}}  & {\em u\+\_\+comp} & The u-\/component of the vector to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em v\+\_\+comp} & The v-\/component of the vector to be checked for consistency \\
\hline
\mbox{\texttt{ in}}  & {\em is} & The starting i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em ie} & The ending i-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em js} & The starting j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em je} & The ending j-\/index to check \\
\hline
\mbox{\texttt{ in}}  & {\em direction} & the direction flag to be passed to pass\+\_\+vector \\
\hline
\end{DoxyParams}


Definition at line 293 of file M\+O\+M\+\_\+debugging.\+F90.


\begin{DoxyCode}{0}
\DoxyCodeLine{295   \textcolor{keywordtype}{character(len=*)},                    \textcolor{keywordtype}{intent(in)}    :: mesg\textcolor{comment}{   !< An identifying message}}
\DoxyCodeLine{296   \textcolor{keywordtype}{type}(ocean\_grid\_type),               \textcolor{keywordtype}{intent(inout)} :: G\textcolor{comment}{      !< The ocean's grid structure}}
\DoxyCodeLine{297 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:,:)},  \textcolor{keywordtype}{intent(in)}    :: u\_comp\textcolor{comment}{ !< The u-\/component of the vector}}
\DoxyCodeLine{298 \textcolor{comment}{                                                           !! to be checked for consistency}}
\DoxyCodeLine{299 \textcolor{keywordtype}{  real}, \textcolor{keywordtype}{dimension(G\%IsdB:,G\%JsdB:,:)},  \textcolor{keywordtype}{intent(in)}    :: v\_comp\textcolor{comment}{ !< The v-\/component of the vector}}
\DoxyCodeLine{300 \textcolor{comment}{                                                           !! to be checked for consistency}}
\DoxyCodeLine{301   \textcolor{keywordtype}{integer},                   \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: is\textcolor{comment}{     !< The starting i-\/index to check}}
\DoxyCodeLine{302   \textcolor{keywordtype}{integer},                   \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: ie\textcolor{comment}{     !< The ending i-\/index to check}}
\DoxyCodeLine{303   \textcolor{keywordtype}{integer},                   \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: js\textcolor{comment}{     !< The starting j-\/index to check}}
\DoxyCodeLine{304   \textcolor{keywordtype}{integer},                   \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: je\textcolor{comment}{     !< The ending j-\/index to check}}
\DoxyCodeLine{305   \textcolor{keywordtype}{integer},                   \textcolor{keywordtype}{optional}, \textcolor{keywordtype}{intent(in)}    :: direction\textcolor{comment}{ !< the direction flag to be}}
\DoxyCodeLine{306 \textcolor{comment}{                                                               !! passed to pass\_vector}}
\DoxyCodeLine{307   \textcolor{comment}{! Local variables}}
\DoxyCodeLine{308   \textcolor{keywordtype}{character(len=24)} :: mesg\_k}
\DoxyCodeLine{309   \textcolor{keywordtype}{integer} :: k}
\DoxyCodeLine{310 }
\DoxyCodeLine{311   \textcolor{keywordflow}{do} k=1,\textcolor{keyword}{size}(u\_comp,3)}
\DoxyCodeLine{312     \textcolor{keywordflow}{if} (k < 10) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i2," ")'}) k}
\DoxyCodeLine{313     \textcolor{keywordflow}{elseif} (k < 100) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i3," ")'}) k}
\DoxyCodeLine{314     \textcolor{keywordflow}{elseif} (k < 1000) \textcolor{keywordflow}{then} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i4," ")'}) k}
\DoxyCodeLine{315     \textcolor{keywordflow}{else} ; \textcolor{keyword}{write}(mesg\_k,\textcolor{stringliteral}{'(" Layer",i9," ")'}) k ;\textcolor{keywordflow}{ endif}}
\DoxyCodeLine{316 }
\DoxyCodeLine{317     \textcolor{keyword}{call }check\_redundant\_vb2d(trim(mesg)//trim(mesg\_k), u\_comp(:,:,k), \&}
\DoxyCodeLine{318              v\_comp(:,:,k), g, is, ie, js, je, direction)}
\DoxyCodeLine{319 \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/diagnostics/M\+O\+M\+\_\+debugging.\+F90\end{DoxyCompactItemize}
