r413: no message
[ctsim.git] / doc / tex2rtf / ctsim.tex
1 \documentstyle[a4,makeidx,verbatim,texhelp,fancyhea,mysober,mytitle]{report}%
2 %\input{psbox.tex}
3 \usepackage{times}
4 \usepackage{hyperref}
5
6 \newcommand{\ctsim}{{\tt CTSim}}
7 \newcommand{\ctsimtext}{{\tt CTSimText}}
8
9 \newcommand{\commandref}[2]{\helpref{{\tt $\backslash$#1}}{#2}}%
10 \newcommand{\commandrefn}[2]{\helprefn{{\tt $\backslash$#1}}{#2}\index{#1}}%
11 \newcommand{\commandpageref}[2]{\latexignore{\helprefn{{\tt $\backslash$#1}}{#2}}\latexonly{{\tt $\backslash$#1} {\it page \pageref{#2}}}\index{#1}}%
12 \newcommand{\indexit}[1]{#1\index{#1}}%
13 \newcommand{\inioption}[1]{{\bf {\tt #1}}\index{#1}}%
14 \parskip=10pt%
15 \parindent=0pt%
16 %\backgroundcolour{255;255;255}\textcolour{0;0;0}% Has an effect in HTML only
17 \winhelpignore{\title{Manual for CTSim 3.0}%
18 \author{Kevin Rosenberg, M.D.}%
19 \date{January 2001}%
20 }%
21 \winhelponly{\title{Manual for CTSim 3.0}%
22 \author{by Kevin Rosenberg, M.D.\\$$\image{1cm;0cm}{logo-huge.bmp}$$}%
23 }%
24 \makeindex%
25 \begin{document}%
26 \maketitle%
27 \pagestyle{fancyplain}%
28 \bibliographystyle{plain}%
29 \pagenumbering{roman}%
30 \setheader{{\it CONTENTS}}{}{}{}{}{{\it CONTENTS}}%
31 \setfooter{\thepage}{}{}{}{}{\thepage}%
32 \tableofcontents%
33
34 \chapter*{Copyright notice}%
35 \setheader{{\it COPYRIGHT}}{}{}{}{}{{\it COPYRIGHT}}%
36 \setfooter{\thepage}{}{}{}{}{\thepage}%
37
38 Copyright (c) 1983-2001 Kevin Rosenberg, M.D.
39
40 Permission to use, copy, modify, and distribute this software and its
41 documentation for any purpose is hereby granted without fee, provided that the
42 above copyright notice, author statement and this permission notice appear in
43 all copies of this software and related documentation.
44
45 THE SOFTWARE IS PROVIDED ``AS-IS'' AND WITHOUT WARRANTY OF ANY KIND, EXPRESS,
46 IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
47 MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
48
49 IN NO EVENT SHALL KEVIN ROSENBERG BE LIABLE FOR ANY
50 SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR
51 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
52 WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY
53 OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
54 PERFORMANCE OF THIS SOFTWARE.
55
56 \chapter{Introduction}%
57 \pagenumbering{arabic}%
58 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
59 \setfooter{\thepage}{}{}{}{}{\thepage}%
60
61 Computed Tomography is a technique for estimating the interior of an object 
62 from measurement of radiation collected around the object. This radiation 
63 can be either projected through or emitted from the object.
64 \ctsim simulates the process of projecting X-rays through a phantom object.
65 \ctsim can then reconstruct the interior of the object from the projections
66 collected around the phantom object.
67
68 \chapter{Installation}\index{Installation}%
69 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
70 \setfooter{\thepage}{}{}{}{}{\thepage}%
71
72 \section{Download}%\index{Installation,Download}%
73
74 The latest version of CTSim, plus source code, can be accessed from:
75
76 \begin{verbatim}
77 http://www.ctsim.org
78 ftp://ftp.ctsim.org
79 \end{verbatim}
80
81 It is available in Windows 95/NT/2000 and Linux GUI versions and non-GUI versions.
82
83 \section{Installing Linux RPM}\index{Installation,Linux}%
84
85 \section{Installing Windows Binary}\index{Installation,Windows}%
86
87 \section{Build From Sources}%\index{Installation,Build}%
88
89 See the INSTALL file included in the source distribution for instructions.
90
91 \section{Requirements}\index{Installation,Build,Requirements}%
92   \begin{itemize}\itemsep=0pt
93   \item zlib Library (optional)
94         \par Used for PNG file export.
95
96   \item libpng Library (optional)
97         \par Used for PNG file export.
98         \par www.libpng.org
99
100   \item FFTW library (optional)
101         \par Used for frequency-based filtering and fourier transformations of images.
102         \par www.fftw.org
103
104   \item readline library (optional)
105         /par Used for {/ctsimtext} interactive shell.
106
107   \item dmalloc library (optional)
108         \par Used for debugging memory allocation
109         \par www.dmalloc.com
110
111   \item wxWindows library (optional) 
112   \par Used for platform-independent graphical interface. The graphical-shell
113   program \ctsim requires this library.  
114   \par www.wxwindows.org
115
116 \end{itemize}
117
118 \chapter{ctsim - the Graphical User Interface}%\index{ctsim}% 
119 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
120 \setfooter{\thepage}{}{}{}{}{\thepage}%
121
122 \ctsim\ is the graphical shell for the CTSim project. It is
123 written using the wxLibrary for cross-platform compatibility with GTK,
124 Motif, and Microsoft Windows. It includes all of the functionality of
125 the command-line tool {\tt ctsimtext} as well as image processing and visualization features.
126
127 \section{Usage}
128 ctsim [OPTIONS] [files to open...]
129
130 \ctsim can open projection files, image files, phantom definition files, and plotfiles.
131
132 \chapter{ctsimtext - The Command Line Interface}\index{ctsimtext}%
133 \ctsimtext is a master shell for all of the command-line utilities. 
134 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
135 \setfooter{\thepage}{}{}{}{}{\thepage}%
136
137 \section{Usage}%
138
139 \ctsimtext can be executed without any parameters. In that case, \ctsimtext
140 offers a command-line to enter the function-names and their parameters. The output of the command is displayed. Further commands may be given to \ctsimtext. The shell is exited by the {\tt quit} command.
141
142 \ctsimtext can also be called to execute a single command. This is especially useful for batch files containing multiple \ctsimtext commands. This is invoked by calling {\tt ctsimtext function-name parameters...}.
143
144 The following function names are available:
145
146 \subsection{if1}\index{Programs,ctsimtext,if1}%
147 Perfoms math functions on a single image.
148
149 \subsubsection{Usage}%
150 \begin{itemize}\itemsep=0pt
151   \item --invert
152   \item --log
153   \item --exp
154   \item --sqr
155   \item --sqrt
156 \end{itemize}
157
158 \subsection{if2}\index{Programs,ctsimtext,if2}%
159 Perfoms math functions on a two images.
160
161 \subsubsection{Usage}%
162 \begin{itemize}\itemsep=0pt
163   \item --add
164   \item --sub
165   \item --mul
166   \item --comp
167   \item --column-plot
168   \item --row-plot
169 \end{itemize}
170
171 \subsection{ifinfo}\index{Programs,ctsimtext,ifinfo}%
172
173 Displays information about an imagefile.
174 \subsubsection{Usage}%
175 \begin{itemize}\itemsep=0pt
176   \item --labels
177   \item --no-labels
178   \item --stats
179   \item --no-stats
180   \item --help
181 \end{itemize}
182
183 \subsection{ifexport}\index{Programs,ctsimtext,ifexport}%
184 Export an imagefile to a standard graphics file.
185
186 \subsubsection{Usage}%
187 \begin{itemize}\itemsep=0pt
188   \item --format
189   \begin{itemize}\itemsep=0pt
190     \item --pgm
191     \item --pgmasc
192     \item --png
193     \item --png16
194   \end{itemize}
195   \item --center
196   \begin{itemize}\itemsep=0pt
197     \item median
198     \item mode
199     \item mean
200   \end{itemize}
201   \item --auto
202   \begin{itemize}\itemsep=0pt
203      \item --full
204      \item --std0.1
205      \item --std0.5
206      \item --std1
207      \item --std2
208      \item --std3
209   \end{itemize}
210   \item --scale
211   \item --min
212   \item --max
213 \end{itemize}
214
215 \subsection{phm2pj}\index{Programs,ctsimtext,phm2pj}%
216 Simulates collection of X-rays data (projections) around a phantom object.
217
218 \subsubsection{Usage}%
219 phm2pj projection-file-name number-of-detectors number-of-views [options...]
220 \begin{itemize}\itemsep=0pt
221   \item --phantom
222   Select a standard phantom 
223   \begin{itemize}\itemsep=0pt
224     \item herman
225     \item herman-b
226     \item shepp-logan
227     \item shepp-logan-b
228   \end{itemize}
229
230   \item --phmfile
231   Load a phantom definition definition
232
233   \item --geometry
234   \begin{itemize}\itemsep=0pt
235     \item parallel
236     \item equiangular
237     \item equilinear
238   \end{itemize}
239
240   \item --nray
241     Number of samples per each detector
242
243   \item --rotangle
244     Sets the rotation amount as a multiple of pi. For parallel geometries use
245 a rotation angle of 1 and for equilinear and equiangular geometries use a rotation angle of 2.
246
247   \item --field-of-view
248     Sets the field of view as a ratio of the diameter of the phantom. For parallel geometries, using a value of 1.0 is fine. For other geometies, this should be at least 1.3 to avoid artifacts.
249
250   \item --focal-length
251     Sets the distance of the radiation source and detectors from the center of the object as a ratio of the radius of the object. For parallel geometries, a value of 1.0 is fine. For other geometries, this should be at least 2.0 to avoid artifacts.
252 \end{itemize}
253
254 The Herman phantom is taken with permission from Gabor Hermans 1980 book\cite{HERMAN80}. The Shepp-Logan phantom was published in 1974\cite{SHEPP74}.
255
256 \subsection{phm2if}\index{Programs,ctsimtext,phm2if}%
257 Converts a geometric phantom object into an imagefile. The size of the
258 imagefile in pixels must be specified as well as the number of samples
259 to average per pixel.
260
261 \subsubsection{Usage}%
262 \begin{itemize}\itemsep=0pt
263   \item --nsamples
264 \end{itemize}
265
266 \subsection{pj2if}\index{Programs,ctsimtext,pj2if}%
267 Convert a projection file into an imagefile.
268
269 \subsubsection{Usage}%
270 \begin{itemize}\itemsep=0pt
271 \end{itemize}
272
273 \subsection{pjinfo}\index{Programs,ctsimtext,pjinfo}%
274 Displays information about a projection file.
275
276 \subsubsection{Usage}%
277 \begin{itemize}\itemsep=0pt
278   \item --binaryheader
279   \item --binaryview
280   \item --startview
281   \item --endview
282   \item --dump
283 \end{itemize}
284
285 \subsection{pjrec}\index{Programs,ctsimtext,pjrec}%
286 Reconstructs the interior of an object from a projection file.
287
288 \subsubsection{Usage}%
289
290 \subsubsection{Parameters}%
291 \begin{itemize}\itemsep=0pt
292   \item Filter 
293   Selects which filter to apply to each projection. To
294   properly reconstruct an image, this filter should be multiplied 
295   by the absolute value of distance from zero frequency.
296   \begin{itemize}\itemsep=0pt
297     \item abs_bandlimit
298     \item abs_cosine
299     \item abs_hamming
300     \item abs_sinc
301   \end{itemize}
302
303   \item Filter Parameter 
304   \par Sets the alpha level for Hamming
305   window. At setting of 0.54, this equals the Hanning window.
306
307   \item Filter Method
308     \begin{itemize}\itemsep=0pt
309       \item convolution
310       \item fourier
311       \item fourier_table
312       \item fftw
313       \item rfftw
314     \end{itemize}
315
316   \item Filter Generation
317     \begin{itemize}\itemsep=0pt
318       \item direct
319       \item inverse_fourier
320     \end{itemize}
321
322   \item Interpolation
323     \begin{itemize}\itemsep=0pt
324       \item nearest
325       \item linear
326     \end{itemize}
327      
328   \item Backprojection
329     \begin{itemize}\itemsep=0pt
330       \item trig
331       \item table
332       \item diff
333       \item diff2
334       \item idiff2
335       \item idiff3
336     \end{itemize}
337
338   \item Zeropad
339   \item Preinterpolation Factor
340 \end{itemize}
341
342 \chapter{The Web Browser CGI Interface}\index{Web Interface}%
343 \setheader{{\it CHAPTER \thechapter}}{}{}{}{}{{\it CHAPTER \thechapter}}%
344 \setfooter{\thepage}{}{}{}{}{\thepage}%
345
346 \section{Overview}\index{Web Interface,Overview}%
347 The CGI program {\tt ctsim.cgi} takes projections of a standard
348 phantom object, performs reconstruction, and then compares the
349 rasterized phantom object with the reconstruction. The comparison is
350 performed both visually by an image subtraction as well as by standard
351 statistics as described by Herman\cite{HERMAN80}.
352
353 \section{Requirements}\index{Web Interface,Requirements}%
354 \begin{itemize}\itemsep=0pt
355    \item For Web Interface
356    \begin{itemize}\itemsep=0pt
357       \item Apache or other CGI compatible web server
358
359       \item Perl (version 4.0 or higher)
360
361       \item A client web browser than can display PNG files. Most
362       current web browswer do support PNG.
363     \end{itemize}
364
365   \end{itemize}
366
367 \newpage
368
369 \bibliographystyle{plain}
370 \bibliography{ctsim}
371 \addcontentsline{toc}{chapter}{Bibliography}
372 \setheader{{\it REFERENCES}}{}{}{}{}{{\it REFERENCES}}%
373 \setfooter{\thepage}{}{}{}{}{\thepage}%
374
375 \addcontentsline{toc}{chapter}{Index}
376 \setheader{{\it INDEX}}{}{}{}{}{{\it INDEX}}%
377 \setfooter{\thepage}{}{}{}{}{\thepage}%
378 \printindex%
379
380 \end{document}