/[escript]/trunk/doc/user/guide_defs.tex
ViewVC logotype

Contents of /trunk/doc/user/guide_defs.tex

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3293 - (show annotations)
Thu Oct 21 23:18:32 2010 UTC (9 years, 8 months ago) by caltinay
File MIME type: application/x-tex
File size: 15314 byte(s)
user's guide builds again with new class file. The cleanup can commence...

1
2 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3 %
4 % Copyright (c) 2003-2010 by University of Queensland
5 % Earth Systems Science Computational Center (ESSCC)
6 % http://www.uq.edu.au/esscc
7 %
8 % Primary Business: Queensland, Australia
9 % Licensed under the Open Software License version 3.0
10 % http://www.opensource.org/licenses/osl-3.0.php
11 %
12 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
13
14
15 \usepackage{subfigure}
16 \usepackage{makeidx}
17
18 \graphicspath{{figures/}}
19
20 % default width for figures
21 \newcommand{\figwidth}{100mm}
22
23 % commands useful in cross-referencing
24 \newcommand{\Ref}[1]{Reference~\cite{#1}}
25 \newcommand{\Sec}[1]{Section~\ref{#1}}
26 \newcommand{\App}[1]{Appendix~\ref{#1}}
27 \newcommand{\Chap}[1]{Chapter~\ref{#1}}
28 \newcommand{\etal}{\emph{~et~al.}}
29 \newcommand{\fig}[1]{Figure~\ref{#1}}
30 \newcommand{\eqn}[1]{Equation~(\ref{#1})}
31 \newcommand{\tab}[1]{Table~\ref{#1}}
32 \newcommand{\env}[1]{\textbf{\mbox{#1}}\index{Environment!#1}}
33
34 % define some handy commands for escript stuff
35 \newcommand{\LINUX}{{\it Linux}\xspace}
36 \newcommand{\WINDOWS}{{\it MS Windows}\xspace}
37 \newcommand{\PYTHON}{{\it python}\xspace}
38 \newcommand{\netCDF}{{\it netCDF}\index{netCDF}\xspace}
39 \newcommand{\escript}{\module{esys.escript}\xspace}
40 \newcommand{\finley}{\module{esys.finley}\xspace}
41 \newcommand{\esys}{\module{esys}\xspace}
42 \newcommand{\pyvisi}{\module{esys.pyvisi}\xspace}
43 \newcommand{\pycad}{\module{esys.pycad}\xspace}
44 \newcommand{\gmsh}{\module{esys.pycad.gmsh}\xspace}
45 \newcommand{\gmshextern}{{\it Gmsh}\cite{GMSH}\index{Gmsh}\xspace}
46 \newcommand{\SCIPY}{{\it SciPy}\cite{SCIPY}\index{SciPy}\xspace}
47 \newcommand{\MPI}{{\it MPI}\index{Message Passing Interface!MPI}\xspace}
48 \newcommand{\OPENMP}{{\it OpenMP}\xspace\index{OpenMP!threading}\xspace}
49 \newcommand{\linearPDEs}{\module{esys.escript.linearPDEs}\xspace}
50 \newcommand{\LinearPDE}{\class{LinearPDE}\xspace}
51 \newcommand{\modelframe}{\module{esys.modelframe}\xspace}
52 \newcommand{\pdetools}{\module{esys.escript.pdetools}\xspace}
53 \newcommand{\False}{\constant{False}\xspace}
54 \newcommand{\True}{\constant{True}\xspace}
55 \newcommand{\warning}[1]{\emph{Warning: #1}}
56
57 \newcommand{\SolverOptions}{\class{SolverOptions}\xspace}
58 \newcommand{\Poisson}{\class{Poisson}\xspace}
59 \newcommand{\Helmholtz}{\class{Helmholtz}\xspace}
60 \newcommand{\Lame}{\class{Lame}\xspace}
61 \newcommand{\Data}{\class{Data}\xspace}
62 \newcommand{\EmptyData}{empty \class{Data}\index{empty Data}\xspace}
63 \newcommand{\Domain}{\class{Domain}\xspace}
64 \newcommand{\gnuplot}{{\it gnuplot}\cite{GNUPLOT}\index{visualization!gnuplot}\index{gnuplot}}
65 \newcommand{\finleyelement}[1]{{\it #1}\index{finley!#1}}
66 \newcommand{\PCG}{\member{SolverOptions.PCG}\xspace\index{linear solver!PCG}\index{PCG}}
67 \newcommand{\BiCGStab}{\member{SolverOptions.BICGSTAB}\xspace\index{linear solver!BiCGStab}\index{BiCGStab}}
68 \newcommand{\Direct}{\member{SolverOptions.DIRECT}\xspace\index{linear solver!Direct}\index{Direct solver}}
69 \newcommand{\GMRES}{\member{SolverOptions.GMRES}\xspace\index{linear solver!GMRES}\index{GMRES}}
70 \newcommand{\PRESTWENTY}{\member{SolverOptions.PRES20}\xspace\index{linear solver!PRES20}\index{PRES20}}
71 \newcommand{\JACOBI}{\member{SolverOptions.JACOBI}\xspace\index{preconditioner!Jacobi}\index{Jacobi}}
72 \newcommand{\ILU}{\member{SolverOptions.ILU0}\xspace\index{preconditioner!ILU0}\index{ILU0}}
73 \newcommand{\ILUT}{\member{SolverOptions.ILUT}\xspace\index{preconditioner!ILUT}\index{ILUT}}
74 \newcommand{\RILU}{\member{SolverOptions.RILU}\xspace\index{preconditioner!RILU}\index{RILU}}
75 \newcommand{\LUMPING}{\member{SolverOptions.LUMPING}\xspace\index{linear solver!lumping}\index{lumping}}
76 \newcommand{\NOREORDERING}{\member{SolverOptions.NO\hackscore REORDERING}\xspace}
77 \newcommand{\MINIMUMFILLIN}{\member{SolverOptions.MINIMUM\hackscore FILL\hackscore IN\xspace}
78 \index{linear solver!minimum fill-in ordering}\index{minimum fill-in ordering}}
79 \newcommand{\NESTEDDESCTION}{\member{SolverOptions.NESTED\hackscore DISSECTION}\xspace\index{linear solver!nested dissection ordering}\index{nested dissection}}
80 \newcommand{\AMG}{\member{SolverOptions.AMG}\xspace\index{linear solver!AMG}\index{algebraic Multi-grid}\index{AMG}}
81 \newcommand{\GAUSSSEIDEL}{\member{SolverOptions.GAUSS\hackscore SEIDEL}\xspace\index{linear solver!Gauss-Seidel}\index{preconditioner!Gauss-Seidel}\index{Gauss-Seidel Scheme}}
82 \newcommand{\LOCALGAUSSSEIDEL}{\member{SolverOptions.LOCAL\hackscore GAUSS\hackscore SEIDEL}\xspace\index{linear solver!Gauss-Seidel}\index{preconditioner!Gauss-Seidel}\index{Gauss-Seidel Scheme}}
83 \newcommand{\MKL}{\texttt{MKL}\xspace\index{packages!MKL}\index{MKL}}
84 \newcommand{\UMFPACK}{\texttt{UMFPACK}\xspace\index{packages!UMFPACK}\index{UMFPACK}}
85 \newcommand{\PASO}{\texttt{PASO}\xspace\index{packages!PASO}\index{PASO}}
86
87 \newcommand{\FunctionSpace}{\class{FunctionSpace}\xspace}
88 \newcommand{\Operator}{\class{Operator}\xspace}
89 \newcommand{\SolutionFS}{solution \class{FunctionSpace}\index{solution}\xspace}
90 \newcommand{\ReducedSolutionFS}{reduced solution \class{FunctionSpace}\index{solution!reduced}\xspace}
91 \newcommand{\FunctionOnBoundary}{boundary \class{FunctionSpace}\xspace}
92 \newcommand{\Function}{general \class{FunctionSpace}\xspace}
93 \newcommand{\FunctionOnContactZero}{contact \class{FunctionSpace} on side 0\xspace}
94 \newcommand{\FunctionOnContactOne}{contact \class{FunctionSpace} on side 1\xspace}
95 \newcommand{\ContinuousFunction}{continuous \class{FunctionSpace}\xspace}
96 \newcommand{\RankOne}{{rank-1 \Data object}\xspace}
97 \newcommand{\RankTwo}{{rank-2 \Data object}\xspace}
98 \newcommand{\RankThree}{{rank-3 \Data object}\xspace}
99 \newcommand{\RankFour}{{rank-4 \Data object}\xspace}
100 \newcommand{\Tensor}{{tensor \Data object}\xspace}
101 \newcommand{\Vector}{{vector \Data object}\xspace}
102 \newcommand{\Scalar}{{scalar \Data object}\xspace}
103 \newcommand{\DataSample}{{data sample}\index{data sample}\xspace}
104 \newcommand{\DataSamplePoints}{{data sample points}\index{data sample!points}\xspace}
105 \newcommand{\numpy}{\module{numpy}\xspace}
106 \newcommand{\numpyNDA}{\module{numpy.\class{ndarray}\xspace}}
107
108 \newcommand{\Shape}{shape\xspace\index{shape}}
109 \newcommand{\Rank}{rank\xspace\index{shape}}
110 \newcommand{\ExampleDirectory}{example directory\xspace}
111 \newcommand{\ReferenceGuide}{\url{http://esys.esscc.uq.edu.au/docs.html}\xspace}
112 \newcommand{\Point}{\class{Point}\xspace}
113 \newcommand{\PropertySet}{\class{PropertySet}\xspace}
114 \newcommand{\Design}{\class{Design}\xspace}
115 \newcommand{\TagMap}{\class{TagMap}\xspace}
116 \newcommand{\ManifoldOneD}{\class{Manifold1D}\xspace}
117 \newcommand{\ManifoldTwoD}{\class{Manifold2D}\xspace}
118 \newcommand{\ManifoldThreeD}{\class{Manifold3D}\xspace}
119
120 % handy commands related to visualization
121 \newcommand{\VTK}{{\it VTK}\index{visualization!VTK}\index{VTK}\xspace}
122 \newcommand{\SILO}{{\it SILO}\index{visualization!SILO}\index{SILO}\xspace}
123 \newcommand{\MATPLOTLIB}{\module{matplotlib}\index{visualization!matplotlib}\index{matplotlib}\xspace}
124 \newcommand{\VTKUrl}{\url{http://www.vtk.org/}\index{visualization!VTK}\index{VTK}\xspace}
125 \newcommand{\VisIt}{{\it VisIt}\index{visualization!VisIt}\index{VisIt}\xspace}
126 \newcommand{\mayavi}{{\it mayavi}\index{visualization!mayavi}\index{mayavi}\xspace}
127 \newcommand{\OpenDX}{{\it OpenDX}\index{visualization!OpenDX}\index{OpenDX}\cite{OPENDX}\xspace}
128
129 % deprecated pyvisi commands
130 \newcommand{\Scene}{\class{Scene}\xspace}
131 \newcommand{\Camera}{\class{Camera}\xspace}
132 \newcommand{\Light}{\class{Light}\xspace}
133 \newcommand{\DataCollector}{\class{DataCollector}\xspace}
134 \newcommand{\ImageReader}{\class{ImageReader}\xspace}
135 \newcommand{\TextTwoD}{\class{Text2D}\xspace}
136 \newcommand{\ActorTwoD}{\class{Actor2D}\xspace}
137 \newcommand{\ActorThreeD}{\class{Actor3D}\xspace}
138 \newcommand{\Transform}{\class{Transform}\xspace}
139 \newcommand{\Clipper}{\class{Clipper}\xspace}
140 \newcommand{\Map}{\class{Map}\xspace}
141 \newcommand{\MapOnPlaneCut}{\class{MapOnPlaneCut}\xspace}
142 \newcommand{\MapOnPlaneClip}{\class{MapOnPlaneClip}\xspace}
143 \newcommand{\MapOnScalarClip}{\class{MapOnScalarClip}\xspace}
144 \newcommand{\MapOnScalarClipWithRotation}{\class{MapOnScalarClipWithRotation}\xspace}
145 \newcommand{\GlyphThreeD}{\class{Glyph3D}\xspace}
146 \newcommand{\MaskPoints}{\class{MaskPoints}\xspace}
147 \newcommand{\Velocity}{\class{Velocity}\xspace}
148 \newcommand{\VelocityOnPlaneCut}{\class{VelocityOnPlaneCut}\xspace}
149 \newcommand{\VelocityOnPlaneClip}{\class{VelocityOnPlaneClip}\xspace}
150 \newcommand{\Sphere}{\class{Sphere}\xspace}
151 \newcommand{\TensorGlyph}{\class{TensorGlyph}\xspace}
152 \newcommand{\Ellipsoid}{\class{Ellipsoid}\xspace}
153 \newcommand{\EllipsoidOnPlaneCut}{\class{EllipsoidOnPlaneCut}\xspace}
154 \newcommand{\EllipsoidOnPlaneClip}{\class{EllipsoidOnPlaneClip}\xspace}
155 \newcommand{\ContourModule}{\class{ContourModule}\xspace}
156 \newcommand{\Contour}{\class{Contour}\xspace}
157 \newcommand{\ContourOnPlaneCut}{\class{ContourOnPlaneCut}\xspace}
158 \newcommand{\ContourOnPlaneClip}{\class{ContourOnPlaneClip}\xspace}
159 \newcommand{\PointSource}{\class{PointSource}\xspace}
160 \newcommand{\StreamLineModule}{\class{StreamLineModule}\xspace}
161 \newcommand{\Tube}{\class{Tube}\xspace}
162 \newcommand{\StreamLine}{\class{StreamLine}\xspace}
163 \newcommand{\Warp}{\class{Warp}\xspace}
164 \newcommand{\Carpet}{\class{Carpet}\xspace}
165 \newcommand{\PlaneSource}{\class{PlaneSource}\xspace}
166 \newcommand{\Image}{\class{Image}\xspace}
167 \newcommand{\Logo}{\class{Logo}\xspace}
168 \newcommand{\ImageReslice}{\class{ImageReslice}\xspace}
169 \newcommand{\Position}{\class{Position}\xspace}
170 \newcommand{\DataSetMapper}{\class{DataSetMapper}\xspace}
171 \newcommand{\Legend}{\class{Legend}\xspace}
172 \newcommand{\ScalarBar}{\class{ScalarBar}\xspace}
173 \newcommand{\Movie}{\class{Movie}\xspace}
174 \newcommand{\CubeSource}{\class{CubeSource}\xspace}
175 \newcommand{\Rectangle}{\class{Rectangle}\xspace}
176 \newcommand{\LocalPosition}{\class{LocalPosition}\xspace}
177 \newcommand{\GlobalPosition}{\class{GlobalPosition}\xspace}
178 \newcommand{\Rotation}{\class{Rotation}\xspace}
179 \newcommand{\thumbnailwidth}{50mm}
180 % end of pyvisi commands
181
182 % this stops one figure taking up a whole page and lets more text onto
183 % the one page when a figure exists
184 \renewcommand{\floatpagefraction}{0.8} % Default = 0.5
185
186 % improved version of caption handling
187 \usepackage{ccaption}
188 \captionnamefont{\scshape}
189 \captionstyle{}
190 \makeatletter
191 \renewcommand{\fnum@figure}[1]{\quad\small\textsc{\figurename~\thefigure}:}
192 \renewcommand{\@makecaption}[2]{%
193 \vskip\abovecaptionskip
194 \sbox\@tempboxa{#1: #2}%
195 \ifdim \wd\@tempboxa >\hsize
196 \def\baselinestretch{1}\@normalsize
197 #1: #2\par
198 \def\baselinestretch{1.5}\@normalsize
199 \else
200 \global \@minipagefalse
201 \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
202 \fi
203 \vskip\belowcaptionskip}
204 \makeatother
205
206 % this is for when one uses pdflatex and therefore needs to load pdf
207 % figures into \includegraphics
208 \ifpdf
209 \DeclareGraphicsExtensions{.pdf,.png} % this command defined in graphicx
210 \pdfcompresslevel=9 % 0: no compression, 9: highest compression
211 % or, set compress_level 9 in file pdftex.cfg
212 \else
213 \DeclareGraphicsExtensions{.eps}
214 \fi
215
216 % defines the colour for the background of code examples
217 \definecolor{LightGrey}{gray}{0.9}
218
219 %Some colour definitions added to keep pdflatex happy
220 %I make no claim that these values are particularly good
221 \definecolor{Purple}{rgb}{0.7, 0, 0.6}
222 \definecolor{Tan}{rgb}{0.5,0.5,0.5}
223 \definecolor{BrickRed}{rgb}{0.7, 0.2, 0.2}
224 \definecolor{Black}{rgb}{0, 0, 0}
225
226 % All the \color{x} used to be \color[named]{x}
227 %end color defs
228
229 \lstdefinestyle{myC++}{%
230 language=C++,
231 showstringspaces=false,
232 basicstyle=\small\ttfamily,
233 commentstyle=\color{BrickRed}\ttfamily,
234 keywordstyle=\color{Purple}\ttfamily,
235 %identifierstyle=\color{Blue}\ttfamily,
236 %functionstyle=\color{Blue}\ttfamily,
237 %typestyle=\color{ForestGreen}\ttfamily,
238 stringstyle=\color{Tan}\ttfamily,%
239 morekeywords={,complex,}%
240 frame=none,%
241 backgroundcolor=\color{LightGrey}%
242 }
243
244 \lstdefinestyle{myMatlab}{%
245 language=Matlab,
246 showstringspaces=false,
247 basicstyle=\small\ttfamily,
248 commentstyle=\color{BrickRed}\ttfamily,
249 keywordstyle=\color{Purple}\ttfamily,
250 %identifierstyle=\color{Blue}\ttfamily,
251 %functionstyle=\color{Blue}\ttfamily,
252 %typestyle=\color{ForestGreen}\ttfamily,
253 stringstyle=\color{Tan}\ttfamily,%
254 frame=none,%
255 backgroundcolor=\color{LightGrey}%
256 }
257
258 \lstdefinestyle{myScilab}{%
259 language=Scilab,
260 showstringspaces=false,
261 basicstyle=\small\ttfamily,
262 commentstyle=\color{BrickRed}\ttfamily,
263 keywordstyle=\color{Purple}\ttfamily,
264 %identifierstyle=\color{Blue}\ttfamily,
265 %functionstyle=\color{Blue}\ttfamily,
266 %typestyle=\color{ForestGreen}\ttfamily,
267 stringstyle=\color{Tan}\ttfamily,%
268 frame=none,%
269 backgroundcolor=\color{LightGrey}%
270 }
271
272 \lstdefinestyle{myShell}{%
273 language=ksh,
274 showstringspaces=false,
275 basicstyle=\small\ttfamily,
276 commentstyle=\color{Black}\ttfamily,
277 keywordstyle=\color{Black}\ttfamily,
278 %identifierstyle=\color{Blue}\ttfamily,
279 %functionstyle=\color{Blue}\ttfamily,
280 %typestyle=\color{ForestGreen}\ttfamily,
281 stringstyle=\color{Black}\ttfamily,%
282 frame=none,%
283 backgroundcolor=\color{LightGrey}%
284 }
285
286 \lstdefinestyle{myPython}{%
287 language=python,
288 showstringspaces=false,
289 basicstyle=\small\ttfamily,
290 commentstyle=\color{BrickRed}\ttfamily,
291 keywordstyle=\color{Purple}\ttfamily,
292 %identifierstyle=\color{Blue}\ttfamily,
293 %functionstyle=\color{Blue}\ttfamily,
294 %typestyle=\color{ForestGreen}\ttfamily,
295 stringstyle=\color{Tan}\ttfamily,%
296 frame=none,%
297 %backgroundcolor=\color{LightGrey}%
298 }
299
300 \lstdefinestyle{myhtml}{%
301 language=xml,
302 showstringspaces=false,
303 basicstyle=\small\ttfamily,
304 commentstyle=\color{BrickRed}\ttfamily,
305 keywordstyle=\color{Purple}\ttfamily,
306 %identifierstyle=\color{Blue}\ttfamily,
307 %functionstyle=\color{Blue}\ttfamily,
308 %typestyle=\color{ForestGreen}\ttfamily,
309 stringstyle=\color{Tan}\ttfamily,
310 morekeywords={,simulation,prop_dim,error_check,stochastic,%
311 globals,field,dimensions,lattice,domains,samples,vector,%
312 components,fourier_space,sequence,integrate,algorithm,%
313 interval,k_operators,constant,operator_names,vectors,%
314 output,filename,group,sampling,moments,benchmark,use_double,%
315 use_wisdom,use_prefs,binary_output,cycles,filter,post_propagation,%
316 default_value,argv,arg,iterations,cross_propagation,%
317 use_mpi,paths,seed,noises,author,description,name,type,%
318 }
319 frame=none,%
320 %framerule=2pt,%
321 backgroundcolor=\color{LightGrey}%
322 }
323
324 % this implements producing nice code blocks
325 % it also saves time, typing and
326 % *should* reduce errors in the text by removing doubling up of code
327 \lstnewenvironment{xmdsCode}[1][]{\lstset{style=myhtml}\lstset{#1}}{}
328
329 % this implements nicely formatted shell code
330 \lstnewenvironment{shellCode}[1][]{\lstset{style=myShell}\lstset{#1}}{}
331
332 % this implements nicely formatted Perl code
333 \lstnewenvironment{perlCode}[1][]{\lstset{style=myPerl}\lstset{#1}}{}
334
335 % this implements nicely formatted Python code
336 \lstnewenvironment{python}[1][]{\lstset{style=myPython}\lstset{#1}}{}
337
338 % this implements nicely formatted C++ code
339 \lstnewenvironment{CCode}{\lstset{style=myC++}}{}
340
341 % this implements nicely formatted matlab code
342 \lstnewenvironment{matlabCode}{\lstset{style=myMatlab}}{}
343
344 % this implements nicely formatted scilab code
345 \lstnewenvironment{scilabCode}{\lstset{style=myScilab}}{}
346
347 %Ensures that latex doesn't have an error if we don't specify the version
348 \providecommand{\RepVersion}{Unknown\xspace}
349 % to set this value use:
350 % (pdf)latex '\newcommand{\RepVersion}{version\xspace}\input{guide.tex}'
351 % as your command-line

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

  ViewVC Help
Powered by ViewVC 1.1.26