Commit c6a96a01 authored by SiqiLing's avatar SiqiLing
Browse files

parh and tarh specification finished

parent aa918db3
......@@ -128,10 +128,67 @@ The concrete structure is given in the table below:
\end{longtable}
\section{The pARH file format}
To describe the distribution of macro elements and the partition of a macro mesh among several processors a container format is defined. This can be used to improve performance of parallel file reading. The file consists of four section:
To describe the distribution of macro elements and the partition of a macro mesh among several processors a container format is defined. This can be used to improve performance of parallel file reading. The file consists of four sections:
\begin{enumerate}
\item The first section contains a file descriptor and version information, as in the sARH file.
\item In the second part information about the
\item The first section contains a file descriptor and version information, as in the sARH file. But the format is a little bit different.
\item The second part specifies the information about the sARH files this pARH file includes.
\item The third part is related to the macro file or any other file which contains the information about macro meshes.
\item The Last section contains a partition table for all the macro elements.
\end{enumerate}
The concrete structure is given in the table below:
\begin{longtable}{p{.01\linewidth}p{.18\linewidth}|p{.1\linewidth}|p{.09\linewidth}|p{.55\linewidth}}
&\textbf{Field} & \textbf{Size (B)} & \textbf{Type} & \textbf{Description} \\\hline\hline
%\endfirsthead &\textbf{Field} & \textbf{Size (B)} & \textbf{Type} & \textbf{Description} \\\hline\hline
%\multicolumn{5}{r}{\textit{(Continued from last page)}}\\\endhead
%\multicolumn{5}{r}{\textit{(Continued on next page)}}\\\endfoot
%\multicolumn{5}{r}{\textit{(End of header)}}\\\endlastfoot
\first{fd} & 16 & string & Format descriptor (lower case) [\texttt{parh\_[0-9].[0-9]}] \footnote{First [0-9] is major version, second is minor version. The rest is padding of blanks.} \\\hline
\first{ln\_basedir} & 4 & uint & length of the base directory \\
\first{basedir} & ln\_basedir & string & sARH base directory relative to this pARH file \\
\first{n\_files} & 4 & uint & number of sARH files \\\hline
& & & & \\
\first{ln\_macrofile} & 4 & uint & length of the macro file name \footnote{If len\_macrofile is zero, then no macro mesh information is specified.}\\
\first{macrofile} & ln\_macrofile & uint & macro file name \newline [\texttt{(this|macro\_fn)($\epsilon$|:pos)$(\epsilon\mid$;(this|periodic\_fn)($\epsilon$|:pos)$)$}] \footnote{The first part is the macro file name (does not necessary to be the macro file, it can be any file which contains the macro mesh information). Either we give a explicit file name or we use ``this" which means the current pARH file. An optional argument ``pos" is followed, which means the offset of the location of macro mesh data in the file. It is separated by ``:". The third part is an optional periodic data information, which has the same format as macro file and it is separated by ``;".}\\\hline
& & & & \\
\first{\#macro} & 4 & uint & number of macro elements \\
\first{\for $i=0,\ldots,$\#macro-1} & & &\\
& & & & \\
\ldelim[{1}{1mm} & macro[i]$\rightarrow$rank & 4 & uint & rank of the macro element \\
& & & & \\\hline
\end{longtable}
\section{The tARH file format}
For instationary problems, there is a need to store the animation frames like the ParaView Data File Format (PVD). For ARH file, we designed a similar container format called tARH. The file consists of three sections:
\begin{enumerate}
\item The first section contains a file descriptor and version information, exactly as in the pARH file.
\item The second part specifies the information about the pARH files this tARH file includes.
\item The third part provides a table of timestep values.
\end{enumerate}
The concrete structure is given in the table below:
\newpage
\begin{longtable}{p{.01\linewidth}p{.18\linewidth}|p{.1\linewidth}|p{.09\linewidth}|p{.55\linewidth}}
&\textbf{Field} & \textbf{Size (B)} & \textbf{Type} & \textbf{Description} \\
\hline\hline\endfirsthead
%&\textbf{Field} & \textbf{Size (B)} & \textbf{Type} & \textbf{Description} \\\hline\hline
%\multicolumn{5}{r}{\textit{(Continued from last page)}}\\\endhead
%\multicolumn{5}{r}{\textit{(Continued on next page)}}\\\endfoot
%\multicolumn{5}{r}{\textit{(End of header)}}\\\endlastfoot
\first{fd} & 16 & string & Format descriptor (lower case) [\texttt{tarh\_[0-9].[0-9]}] \\\hline
\first{ln\_basedir} & 4 & uint & length of the base directory \\
\first{basedir} & ln\_basedir & string & pARH base directory relative to this tARH file \\
\first{length} & 4 & uint & total length of appended time index \\
\first{decimals} & 4 & uint & number of decimals in time index \\
\hline
& & & & \\
\first{\for $i=0,\ldots,EOF$} & & &\\
& & & & \\
\ldelim[{1}{1mm} & timestep[i] & 8 & double & timestep values until the end of file\\
& & & & \\\hline
\end{longtable}
\end{document}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment