Index: trunk/SophyaLib/Manual/sophya.tex
===================================================================
--- trunk/SophyaLib/Manual/sophya.tex	(revision 1434)
+++ trunk/SophyaLib/Manual/sophya.tex	(revision 1435)
@@ -36,5 +36,6 @@
 \vspace{1cm}
 \begin{center}
-{\bf \Large Document being updated !}
+{\bf \Large Sophya Version: 1.1 (V\_Fev2001) \\ 
+Document revision 1.0 }
 \end{center}
 \titrebp{1}
@@ -57,11 +58,14 @@
 the Planck-HFI data processing software, most of the
 packages presented here have a more general scope than the 
-CMB analysis and Planck mission problem. This documents
+CMB analysis and Planck mission problem. 
+\par
+\vspace*{2mm}
+This documents
 presents only a brief overview of the class library, 
 mainly from the user's point of view. A more complete description
 can be found in the reference manual, available from our
-web site: \\ 
-{\bf http://www.sophya.org}. 
-
+web site: {\bf http://www.sophya.org}. 
+\par
+\vspace*{2mm}
 The source directory tree 
 \footnote{ CVS: cvsserver.lal.in2p3.fr:/exp/eros/CVSPlanck} 
@@ -166,5 +170,5 @@
 flags and the list of Sophya libraries. It should be included in the 
 user's makefile. The default compilation rules assumes that the object (.o) 
-and executable files would be put in the following diretories: \\
+and executable files would be put in the following directories: \\
 {\tt \$HOME/`uname`-\$EROSCXX/Objs} \\ 
 {\tt \$HOME/`uname`-\$EROSCXX/Exec}.
@@ -174,5 +178,5 @@
 The GNU make program should be used.
 \par
-The file {\tt \$DPCBASEREP/Include/makefile\_auto} defines the rules to compile
+The file {\tt Examples/auto\_makefile} defines the rules to compile
 a given source program, and link it against the Sophya libraries to produce
 an executable. The example below shows the steps to compile a program named
@@ -185,5 +189,5 @@
 This command should compile the {\tt trivial.cc} file, 
 and link it against the sophya libraries. 
-The file {\tt \$DPCBASEREP/Include/ex\_makefile} provides another 
+The file {\tt Examples/ex\_makefile} provides another 
 example makefile.
 
@@ -196,4 +200,6 @@
 and NTools modules, and the main program with exception handling.
 Other Sophya modules can be included using the {\tt -import} flag.
+Use of additional include files can be specified using the 
+{\tt -inc} flag.
 \begin{verbatim}
 csh> runcxx -h
@@ -220,9 +226,10 @@
 \end{verbatim}
  
+\newpage
 
 \section{Copy constructor and assignment operator}
-In C++, objects can be copied by assignment or by initialization.
-Copying by initialization corresponds to creating an object and
-initializing its value through the copy constructor.
+In C++, objects can be copied by assignment or by initialisation.
+Copying by initialisation corresponds to creating an object and
+initialising its value through the copy constructor.
 The copy constructor has its first argument as a reference, or
 const reference to the object's class type. It can have  
@@ -271,4 +278,5 @@
 duplicate the data.
 
+\newpage
 \section{Module SysTools}
 
@@ -277,5 +285,5 @@
 class {\tcls{NDataBlock}} for handling reference counting on numerical
 arrays, as well as classes providing the services for implementing simple
-serialization. 
+serialisation. 
 \vspace*{5mm}
 
@@ -294,5 +302,5 @@
 and object hierarchy. \\
 {\bf PPF} {\bf P}ortable {\bf P}ersistence file {\bf F}ormat.
-\item[] Handling of read/write for mutiply referenced objects.
+\item[] Handling of read/write for multiply referenced objects.
 \item[] All write operations are carried using sequential access only. This
 holds also for read operations, unless positional tags are used. 
@@ -300,11 +308,55 @@
 through network links.
 \item[] The serialisation (reading/writing) for objects for a given class
-is implemented through a delegate object. The delegate class inherits
+is implemented through a handler object. The handler class inherits
 from {\tt PPersist} class.
+\item[] A run time registration mechanism is used in conjunction with 
+RTTI (Run Time Type Identification) for identifying handler classes
+when reading {\bf PInPersist} streams, or for associating handlers
+with data objects {\bf AnyDataObject} for write operations.
 \end{itemize}
 A complete description of SOPHYA persistence mechanism and guidelines
 for writing delegate classes for handling object persistence is beyond
-the scope of this document. The example in the next paragraph shows
-simple use of SOPHYA persistence.
+the scope of this document. The most useful methods for using Sophya
+persistence are listed below:
+\begin{itemize}
+\item[] {\tt POutPersist::PutObject(AnyDataObj \& o)} \\ 
+Writes the data object {\bf o} to the output stream.
+\item[] {\tt POutPersist::PutObject(AnyDataObj \& o, string tagname)} \\
+Writes the data object {\bf o} to the output stream, associated with an
+identification tag {\bf tagname}.
+\item[] {\tt PInPersist::GetObject(AnyDataObj \& o)} \\ 
+Reads the next object in stream into {\bf o}. An exception is 
+generated for incompatible object types.
+\item[] {\tt PInPersist::GetObject(AnyDataObj \& o, string  tagname)} \\
+Reads the object associated with the tag {\bf tagname} into {\bf o}. 
+An exception is generated for incompatible object types.
+\end{itemize}
+The operators {\tt operator << (POutPersist ...) } and 
+{\tt operator >> (PInPersist ...) } are often overloaded 
+to perform {\tt PutObject()} and {\tt GetObject()} operations,
+as illustrated in the example below:
+\begin{verbatim}
+// Creating and filling a histogram
+Histo hw(0.,10.,100);
+...
+// Writing histogram to a PPF stream
+POutPersist os("hw.ppf");
+os << hw;
+// Reading a histogram from a PPF stream
+PInPersist is("hr.ppf");
+is >> hr;
+\end{verbatim}
+
+The {\bf scanppf} program can be used to list the content of a PPF file.
+\index{scanppf}
+\begin{verbatim}
+csh> scanppf -h
+SOPHYA Version  1.1 Revision 0 (V_Fev2001) -- Feb 28 2001 11:19:17 cxx
+ Usage: scanppf filename [s/n/a0/a1/a2/a3]
+   s[=default} : Sequential reading of objects
+   n : Object reading at NameTags
+   a0...a3 : Tag List with PInPersist.AnalyseTags(0...3)
+\end{verbatim}
+
 
 \subsection{\tcls{NDataBlock}}
@@ -361,5 +413,5 @@
 MuTyV s("hello");  // string type value
 MuTyV x;
-x = "3.14159626";    // string type value, ascii representation for Pi
+x = "3.14159626";    // string type value, ASCII representation for Pi
 double d = x;        // x converted to double = 3.141596
 x = 314;             // x contains the integer value = 314
@@ -384,5 +436,5 @@
 #include "datacards.h"
 // ...
-// Initializing DataCards object dc from file ex.d
+// Initialising DataCards object dc from file ex.d
 DataCards dc( "ex.d" );
 // Getting the first and second parameters for keyword size
@@ -433,4 +485,5 @@
 \end{verbatim}
 
+\newpage
 \section{Module TArray}
 \index{\tcls{TArray}}
@@ -440,5 +493,5 @@
 arrays {\tt (int, float, double, complex, \ldots)}. The include
 file {\tt array.h} declares all the classes and definitions 
-in module TArray. {\bf Array} is a typdef for arrays 
+in module TArray. {\bf Array} is a typedef for arrays 
 with double precision floating value elements. \\
 {\tt typedef TArray$<$r\_8$>$ Array ; }
@@ -453,7 +506,7 @@
 \index{Sequence} \index{RandomSequence} \index{RegularSequence} 
 \index{EnumeratedSequence}
-The example below shows basic usage of arrays, creation, initialization
+The example below shows basic usage of arrays, creation, initialisation
 and arithmetic operations. Different kind of {\bf Sequence} objects
-can be used for initializing arrays. 
+can be used for initialising arrays. 
 
 \begin{figure}[hbt]
@@ -466,5 +519,5 @@
 \index{\tcls{TArray}} 
 \begin{verbatim}
-// Creating and initializing a 1-D array of integers
+// Creating and initialising a 1-D array of integers
 TArray<int> ia(5);
 EnumeratedSequence es;
@@ -573,5 +626,4 @@
 \end{verbatim}
 
-\newpage
 \subsection{Memory organisation}
 {\tt \tcls{TArray} } can handle numerical arrays with various memory 
@@ -621,5 +673,4 @@
 cout << "Matrix X_F (FortranMemoryMapping) = " << X_F << endl;
 \end{verbatim}
-\newpage
 This code would produce the following output (X\_F = Transpose(X\_C)) :
 \begin{verbatim}
@@ -664,6 +715,6 @@
 computing means and sigmas, finding maxima, fitting, rebinning,
 integrating \dots \\
-The example below shows creating and filling a one dimensionnal histogram
-of 100 bins from $-5.$ to $+5.$ to create a gaussian normal distribution
+The example below shows creating and filling a one dimensional histogram
+of 100 bins from $-5.$ to $+5.$ to create a Gaussian normal distribution
 with errors~:
 \begin{verbatim}
@@ -708,5 +759,5 @@
 may be applied onto profile histograms.
 
-\subsection{NTuples}
+\subsection{Data tables (tuples)}
 \index{NTuple}
 NTuple are memory resident tables of 32 bits floating values (float).
@@ -767,5 +818,5 @@
 \subsection{Writing, viewing \dots }
 
-All these objects have been design to be written to or read from a persistant file.
+All these objects have been design to be written to or read from a persistent file.
 The following example shows how to write the previously created objects
 into such a file~:
@@ -785,71 +836,5 @@
 all these objects.
 
-\subsection{Fourier transform (FFT)}
-\index{FFT} \index{FFTServer}
-
 \newpage
-\section{Module SkyMap}
-\begin{figure}[hbt]
-\dclsbb{AnyDataObj}{PixelMap}
-\dclsccc{PixelMap}{Sphericalmap}{SphereHEALPix}
-\dclsc{SphereThetaPhi}
-\dclsb{LocalMap}
-\caption{partial class diagram for pixelization classes  in Sophya}
-\end{figure}
-The {\bf SkyMap} module provides classes for creating, filling, reading pixelized spherical  and 2D-maps. The types of values stored in pixels can be int, float, double , complex etc. according to the specialization of the template type. 
-\subsection {Spherical maps}
-There are two kinds of spherical maps according pixelization algorithms. SphereHEALPix represents spheres pixelized following the HEALPIix algorithm (E. Yvon, K. Gorski), SphereThetaPhi represents spheres pixelized following an algorithm developed at LAL-ORSAY. The example below shows creating and filling of a SphereHEALPix with nside = 8 (it will be 12*8*8= 768 pixels) :
-\index{\tcls{SphereHEALPix}} 
-
-\begin{verbatim}
-#include ``spherehealpix.h''
-// ...
-SphereHEALPix<double> sph(8);
-for (int k=0; k< sph.NbPixels(); k++) sph(k) = (double)(10*k);
-\end{verbatim}
-
-SphereThetaPhi is used in a similar way with an argument representing number of slices in theta (Euler angle) for an hemisphere.
-\index{\tcls{SphereThetaPhi}}
-
-\subsection {Local maps}
-\index{\tcls{LocalMap}}
-A local map is a 2 dimensional array, with i as column index and j as row index. The map is supposed to lie on a plan tangent to the celestial sphere in a point whose coordinates are (x0,y0) on the local map and (theta0, phi0) on the sphere. The range of the map is defined by two values of angles covered respectively by all the pixels in x direction and all the pixels in y direction (SetSize()). Default value of (x0, y0) is middle of the map, center of pixel(nx/2, ny/2).
-
-Internally, a map is first defined within this reference plane and tranported until the point (theta0, phi0) in such a way that both axes are kept parallel to meridian and parallel lines of the sphere. The user can define its own map with axes rotated with respect to reference axes (this rotation is characterized by angle between the local parallel line and the wanted x-axis-- method SetOrigin(...))
-
-The example below shows creating and filling of a LocalMap with 4 columns and 5 rows. The origin is set to default. The map covers a sphere portion defined by two angles of 30. degrees (methods \textit{SetOrigin()} and \textit{SetSize()} must be called in order to completely define the map).
-\begin{verbatim}
-#include "localmap.h"  
-//..............       
-  LocalMap<r_4> locmap(4,5);
-  for (int k=0; k<locmap.NbPixels();k++) locmap(k)=10.*k;
-  locmap.SetOrigin();
-  locmap.SetSize(30.,30.);
-\end{verbatim}
-
-\subsection{Writing, viewing \dots }
-
-All these objects have been design to be written to or read from a persistant file.
-The following example shows how to write the previously created objects
-into such a file~:
-\begin{verbatim}
-//-- Writing
-
-#include "fiospherehealpix.h" 
-//................
-
-char *fileout = "myfile.ppf";
-POutPersist outppf(fileout);
-FIO_SphereHEALPix<r_8> outsph(sph);
-outsph.Write(outppf);
-FIO_LocalMap<r_8> outloc(locmap);
-outloc.Write(outppf);
-
-\end{verbatim}
-
-Sophya graphical tools (spiapp) can automatically display and operate
-all these objects.
-
-
 \section{Module NTools}
 
@@ -858,5 +843,5 @@
 
 \subsection{Fitting}
-\index{Fitting} \index{Minimization}
+\index{Fitting} \index{Minimisation}
 Fitting is done with two classes {\tt GeneralFit} and {\tt GeneralFitData}
 and is based on the Levenberg-Marquardt method.
@@ -871,5 +856,5 @@
 and can be easily fitted. \\
 Here is a very simple example for fitting the previously created NTuple
-with a gaussian~:
+with a Gaussian~:
 \begin{verbatim}
 #include "fct1dfit.h"
@@ -896,5 +881,5 @@
 mFit.SetData(&mGData);        // connect data to the fitter
 
-// Set and initialize the parameters (that's non-linear fitting!)
+// Set and initialise the parameters (that's non-linear fitting!)
 //           (num par, name, guess start, step, [limits min and max])
 mFit.SetParam(0,"high",90.,1..);
@@ -962,8 +947,141 @@
 Similar operations can be done on polynomials with 2 variables.
 
+\subsection{Integration, Differential equations}
+\index{Integration}
+The NTools module provide also simple classes for numerical integration 
+of functions and differential equations.
+\begin{figure}[hbt]
+\dclsbb{Integrator}{GLInteg}
+\dclsb{TrpzInteg}
+\end{figure}
+
+\index{GLInteg} \index{TrpzInteg}
+{\bf GLInteg} implements the integration through Gauss-Legendre method
+and {\bf TrpzInteg} implements trapeze integration. For {\bf TrpzInteg},
+number of steps specify the number of trapeze, and integration step, 
+their width.
+The sample code below illustrates the use of TrpzInteg class:
+\begin{verbatim}
+#include "integ.h"
+// ......................................................
+// Function to be integrated
+double myf(double x)
+{
+// Simple a x + b x^2  (a=2 b=3)
+return (x*(2.+3.*x));
+}
+// ......................................................
+
+// Compute Integral(myf, 2., 5.) between xmin=2., xmax=5.
+TrpzInteg trpz(myf, 2., 5.);
+// We specify an integration step
+trpz.DX(0.01);
+// The integral can be computed as trpz.Value() 
+double myf_integral = trpz.Value();
+// We could have used the cast operator :
+cout << "Integral[myf, 2., 5.]= " << (double)trpz << endl;
+// Limits can be specified through ValueBetween() method 
+cout << "Integral[myf, 0., 4.]= " << trpz.ValueBetween(0.,4.) << endl;
+\end{verbatim}
+
+\subsection{Fourier transform (FFT)}
+\index{FFT} \index{FFTPackServer}
+An abstract interface for performing FFT operations is defined by the 
+{\bf FFTServerInterface} class. The {\bf FFTPackSever} class implements
+one dimensional FFT, on real and complex data. FFTPackServer uses an
+adapted and extended version of FFTPack (available from netlib), 
+translated in C, and can operate on single and double precision
+({\tt float, double}) data.
+
+The sample code below illustrates the use of FFTServers:
+\begin{verbatim}
+#include "fftpserver.h"
+   // ...
+TVector<r_8> in(32);
+TVector< complex<r_8> > out;
+in = RandomSequence();
+FFTPackServer ffts;
+ffts.setNormalize(true);  // To have normalized transforms
+cout << " FFTServer info string= " << ffts.getInfo() << endl;
+cout << "in= " << in << endl;
+cout << " Calling ffts.FFTForward(in, out) : " << endl;
+ffts.FFTForward(in, out);
+cout << "out= " << out << endl;
+\end{verbatim}
+
+\newpage
+\section{Module SkyMap}
+\begin{figure}[hbt]
+\dclsbb{AnyDataObj}{PixelMap}
+\dclsccc{PixelMap}{Sphericalmap}{SphereHEALPix}
+\dclsc{SphereThetaPhi}
+\dclsb{LocalMap}
+\caption{partial class diagram for pixelization classes  in Sophya}
+\end{figure}
+The {\bf SkyMap} module provides classes for creating, filling, reading pixelized spherical  and 2D-maps. The types of values stored in pixels can be int, float, double , complex etc. according to the specialization of the template type. 
+\subsection {Spherical maps}
+There are two kinds of spherical maps according pixelization algorithms. SphereHEALPix represents spheres pixelized following the HEALPIix algorithm (E. Hivon, K. Gorski)
+\footnote{see the HEALPix Homepage: http://www.eso.org/kgorski/healpix/ }
+, SphereThetaPhi represents spheres pixelized following an algorithm developed at LAL-ORSAY. The example below shows creating and filling of a SphereHEALPix with nside = 8 (it will be 12*8*8= 768 pixels) :
+\index{\tcls{SphereHEALPix}} 
+\index{\tcls{SphereThetaPhi}} 
+
+\begin{verbatim}
+#include "spherehealpix.h"
+// ...
+SphereHEALPix<double> sph(8);
+for (int k=0; k< sph.NbPixels(); k++) sph(k) = (double)(10*k);
+\end{verbatim}
+
+SphereThetaPhi is used in a similar way with an argument representing number of slices in theta (Euler angle) for an hemisphere.
+\index{\tcls{SphereThetaPhi}}
+
+\subsection {Local maps}
+\index{\tcls{LocalMap}}
+A local map is a 2 dimensional array, with i as column index and j as row index. The map is supposed to lie on a plan tangent to the celestial sphere in a point whose coordinates are (x0,y0) on the local map and (theta0, phi0) on the sphere. The range of the map is defined by two values of angles covered respectively by all the pixels in x direction and all the pixels in y direction (SetSize()). Default value of (x0, y0) is middle of the map, center of pixel(nx/2, ny/2).
+
+Internally, a map is first defined within this reference plane and tranported until the point (theta0, phi0) in such a way that both axes are kept parallel to meridian and parallel lines of the sphere. The user can define its own map with axes rotated with respect to reference axes (this rotation is characterized by angle between the local parallel line and the wanted x-axis-- method SetOrigin(...))
+
+The example below shows creating and filling of a LocalMap with 4 columns and 5 rows. The origin is set to default. The map covers a sphere portion defined by two angles of 30. degrees (methods \textit{SetOrigin()} and \textit{SetSize()} must be called in order to completely define the map).
+\begin{verbatim}
+#include "localmap.h"  
+//..............       
+  LocalMap<r_4> locmap(4,5);
+  for (int k=0; k<locmap.NbPixels();k++) locmap(k)=10.*k;
+  locmap.SetOrigin();
+  locmap.SetSize(30.,30.);
+\end{verbatim}
+
+\subsection{Writing, viewing \dots }
+
+All these objects have been design to be written to or read from a persistant file.
+The following example shows how to write the previously created objects
+into such a file~:
+\begin{verbatim}
+//-- Writing
+
+#include "fiospherehealpix.h" 
+//................
+
+char *fileout = "myfile.ppf";
+POutPersist outppf(fileout);
+FIO_SphereHEALPix<r_8> outsph(sph);
+outsph.Write(outppf);
+FIO_LocalMap<r_8> outloc(locmap);
+outloc.Write(outppf);
+// It is also possible to use the << operator
+POutPersist os("sph.ppf");
+os << outsph;
+os << outloc;
+\end{verbatim}
+
+Sophya graphical tools (spiapp) can automatically display and operate
+all these objects.
+
+\newpage
 \section{Module Samba}
 \index{Spherical Harmonics}
 \index{SphericalTransformServer}
-The module provides several classes for spherical harmonic analysis. The main class is \textit{SphericalTranformServer}. It contains methods for analysis and synthesis of spherical maps. The following example fills a vector of Cl's, generate a spherical map from these Cl's. This map is analyzed back to Cl's...
+The module provides several classes for spherical harmonic analysis. The main class is \textit{SphericalTranformServer}. It contains methods for analysis and synthesis of spherical maps. The following example fills a vector of Cl's, generate a spherical map from these Cl's. This map is analysed back to Cl's...
 \begin{verbatim}
 #include "skymap.h"
@@ -988,6 +1106,40 @@
 \end{verbatim}
 
+\newpage
 \section{Module SkyT}
-
+\index{RadSpectra} \index{SpectralResponse}
+The SkyT module is composed of two types of classes:
+\begin{itemize}
+\item{} one which corresponds to an emission spectrum of
+radiation, which is called RadSpectra
+\item{} one which corresponds to the spectral response
+of a given detector (i.e. corresponding to a detector
+filter in a given frequency domain), which is called
+SpectralResponse.
+\end{itemize}
+\begin{figure}[hbt]
+\dclsbb{RadSpectra}{RadSpectraVec}
+\dclsb{BlackBody}
+\dclsccc{AnyDataObj}{SpectralResponse}{SpecRespVec}
+\dclsc{GaussianFilter}
+\caption{partial class for SkyT module}
+\end{figure}
+
+\begin{verbatim}
+#include "skyt.h"
+// ....
+// Compute the flux from a blackbody at 2.73 K through a square filter
+BlackBody myBB(2.73);
+// We define a square filter from 100 - 200 GHz
+SquareFilter mySF(100,200);
+// Compute the filtered integrated flux :
+double flux = myBB.filteredIntegratedFlux(mySF);
+\end{verbatim}
+
+A more detailed description of SkyT module can be found in: 
+{\it The SkyMixer (SkyT and PMixer modules) - Sophya Note No 2. }
+available also from Sophya Web site.
+
+\newpage
 \section{Module FitsIOServer}
 \begin{figure}[hbt]
@@ -995,5 +1147,5 @@
 \dclsb{FitsOutFile}
 \end{figure}
-\index{FITS}
+\index{FITS} \index{FitsInFile} \index{FitsOutFile}
 This module provides classes for handling file input-output in FITS format using the cfitsio library. It works like the SOPHYA persistence (see Module SysTools), using delegate objects, but its design is simpler. The following example  writes a matrix (see module TArray) and a spherical map (see module SkyMap)  on a FITS file and reads back from FITS file and creates new objects :
 \begin{verbatim}
@@ -1030,5 +1182,61 @@
 \end{verbatim}
 
-
+The operators {\tt operator << (FitsOutFile ...)} and 
+{\tt operator >> (FitsInFile ...)} are defined in order 
+to facilitate the FITS file operations:
+\begin{verbatim}
+// Writing an array object to a FITS file
+#include "fitstarray.h" 
+FitsOutFile fio("arr.fits");
+Matrix m(20,30);
+m = 12345.;
+fio << m;
+// .....
+// Reading a binary table to a XNTuple
+#include "fitsxntuple.h" 
+XNTuple xn;
+FitsInFile fii("table.fits");
+fii >> xn;
+\end{verbatim}
+
+
+\newpage
+\section{LinAlg and IFFTW modules}
+An interface to use LAPACK library (available from {\tt http://www.netlib.org})
+is implemented by the {\bf LapackServer} class, in module LinAlg.
+\index{LapackServer}.
+The sample code below shows how to use SVD (Singular Value Decomposition)
+through LapackServer:
+\begin{verbatim}
+#include "intflapack.h"
+// ...
+// Use FortranMemoryMapping as default
+BaseArray::SetDefaultMemoryMapping(BaseArray::FortranMemoryMapping);
+// Create an fill the arrays A and its copy AA
+int n = 20;
+Matrix A(n , n), AA;
+A = RandomSequence(RandomSequence::Gaussian, 0., 4.);  
+AA = A;  // AA is a copy of A
+// Compute the SVD decomposition
+Vector S;  // Vector of singular values
+Matrix U, VT;
+LapackServer<r_8> lpks;
+lpks.SVD(AA, S, U, VT);
+// We create a diagonal matrix using S
+Matrix SM(n, n); 
+for(int k=0; k<n; k++) SM(k,k) = S(k);
+// Check the result : A = U*SM*VT
+Matrix diff = U*(SM*VT) - A;
+double min, max;
+diff.MinMax(min, max);
+cout << " Min/Max difference Matrix (?=0) , Min= " << min 
+     << " Max= " << max << endl;
+\end{verbatim}
+
+\index{FFTWServer}
+The {\bf FFTWServer} class (in module FFTW) implements FFTServerInterface class 
+methods, for one dimensional and multi-dimensional Fourier 
+transforms on double precision data using the FFTW package
+(available from {\tt http://www.fftw.org}).
 
 \newpage
@@ -1109,5 +1317,5 @@
 \end{verbatim}
 
-At this step, all libraries sould have been made. Programs using
+At this step, all libraries should have been made. Programs using
 Sophya libraries can now be built:
 \begin{verbatim}
@@ -1130,6 +1338,6 @@
 makefiles for each module.
 \begin{itemize}
-\item {\bf Makefile} Top level Makefile for builiding the libraries.
-\item {\bf Makefile.h} contains the defintion of compilation flags for the 
+\item {\bf Makefile} Top level Makefile for building the libraries.
+\item {\bf Makefile.h} contains the definition of compilation flags for the 
 different compilers and systems. This file is used for building the 
 library and generating {\bf MakefileUser.h} (to be included in makefiles).
@@ -1162,5 +1370,5 @@
 \index{Exception classes} \index{PThrowable} \index{PError} \index{PException}
 SOPHYA library defines a set of exceptions which are used 
-for signaling error conditions. The figure below shows a partial 
+for signalling error conditions. The figure below shows a partial 
 class diagram for exception classes in SOPHYA.
 \begin{figure}[hbt]
