Index: /trunk/anuga_core/source/anuga/__init__.py
===================================================================
--- /trunk/anuga_core/source/anuga/__init__.py	(revision 9404)
+++ /trunk/anuga_core/source/anuga/__init__.py	(revision 9405)
@@ -162,5 +162,6 @@
 from anuga.file_conversion.esri2sww import esri2sww   
 from anuga.file_conversion.sww2dem import sww2dem, sww2dem_batch 
-from anuga.file_conversion.asc2dem import asc2dem     
+from anuga.file_conversion.asc2dem import asc2dem
+from anuga.file_conversion.xya2pts import xya2pts     
 from anuga.file_conversion.ferret2sww import ferret2sww     
 from anuga.file_conversion.dem2dem import dem2dem
Index: /trunk/anuga_core/source/anuga/file_conversion/xya2pts.py
===================================================================
--- /trunk/anuga_core/source/anuga/file_conversion/xya2pts.py	(revision 9404)
+++ /trunk/anuga_core/source/anuga/file_conversion/xya2pts.py	(revision 9405)
@@ -1,20 +1,24 @@
 
 
-def xya2pts(filename, verbose=False):
+def xya2pts(name_in, name_out=None, verbose=False):
     """Convert a file with xy and elevation data to NetCDF pts file.
     """
     
     from anuga.geospatial_data import Geospatial_data
+
+    root = name_in[:-4]
+
+    if name_out is None: name_out = root + '.pts'
     
-    if verbose: print 'Creating', filename
+    if verbose: print 'Creating', name_out
     
     # Read the ascii (.xya) version of this file,
     # make it comma separated and invert the bathymetry
     # (Below mean sea level should be negative)
-    infile = open(filename[:-4] + '.xya')
-    out_filename = filename[:-4] + '.pts'
+    infile = open(name_in)
 
     points = []
     attribute = []
+
     for line in infile.readlines()[1:]: #Skip first line (the header)
         fields = line.strip().split(',')
@@ -31,5 +35,5 @@
     G = Geospatial_data(data_points=points,
                         attributes=attribute)
-    G.export_points_file(out_filename)
+    G.export_points_file(name_out)
     
     
Index: /trunk/anuga_core/validation_tests/experimental_data/okushiri/create_okushiri.py
===================================================================
--- /trunk/anuga_core/validation_tests/experimental_data/okushiri/create_okushiri.py	(revision 9404)
+++ /trunk/anuga_core/validation_tests/experimental_data/okushiri/create_okushiri.py	(revision 9405)
@@ -185,5 +185,6 @@
 
         if verbose: print 'Reading pts from xya'
-        anuga.xya2pts(project.bathymetry_filename_stem+'.pts', verbose = verbose)
+        anuga.xya2pts(project.bathymetry_filename_stem+'.xya',\
+                      verbose = verbose)
         
         fit_to_mesh_file(project.mesh_filename, project.bathymetry_filename,
Index: /trunk/anuga_user_manual/source/anuga_user_manual.tex
===================================================================
--- /trunk/anuga_user_manual/source/anuga_user_manual.tex	(revision 9404)
+++ /trunk/anuga_user_manual/source/anuga_user_manual.tex	(revision 9405)
@@ -344,5 +344,5 @@
 
 \label{ref:runup_py_code}
-\verbatiminput{../../demos/runup.py}
+\verbatiminputunderscore{../../anuga_core/demos/runup.py}
 
 
@@ -656,5 +656,5 @@
 when this example is run:
 
-\verbatiminput{examples/runupoutput.txt}
+\verbatiminputunderscore{examples/runupoutput.txt}
 
 
@@ -731,5 +731,5 @@
 Here is the code for the first version of the channel flow \file{channel1.py}:
 
-\verbatiminput{demos/channel1.py}
+\verbatiminputunderscore{demos/channel1.py}
 
 In discussing the details of this example, we follow the outline
@@ -774,5 +774,5 @@
 %\end{verbatim}
 
-
+%=========================================
 \section{Model Output}
 
@@ -787,10 +787,13 @@
 \end{figure}
 
-\subsection{Changing boundary conditions on the fly}
+
+
+%=========================================
+\section{Changing boundary conditions on the fly}
 \label{sec:change boundary}
 
 Here is the code for the second version of the channel flow \file{channel2.py}:
 
-\verbatiminput{demos/channel2.py}
+\verbatiminputunderscore{demos/channel2.py}
 
 This example differs from the first version in that a constant outflow boundary condition has
@@ -845,5 +848,5 @@
 Here is the code for the third version of the channel flow \file{channel3.py}:
 
-\verbatiminput{demos/channel3.py}
+\verbatiminputunderscore{demos/channel3.py}
 
 This example differs from the first two versions in that the topography
@@ -886,5 +889,6 @@
 
 
-\section{An Example with Real Data}
+%==========================================================
+\chapter{An Example with Real Data}
 
 \label{sec:realdataexample} The following discussion builds on the
@@ -905,5 +909,5 @@
 }
 
-\subsection{Overview}
+\section{Overview}
 As in the case of \file{runup.py}, the actions carried
 out by the program can be organised according to this outline:
@@ -925,14 +929,14 @@
 \end{enumerate}
 
-\subsection{The Code}
+\section{The Code}
 
 Here is the code for \file{runcairns.py}:
 
-\verbatiminput{../../demos/cairns/runcairns.py}
+\verbatiminputunderscore{../../anuga_core/demos/cairns/runcairns.py}
 
 In discussing the details of this example, we follow the outline
 given above, discussing each major step of the code in turn.
 
-\subsection{Establishing the Mesh}\index{mesh, establishing}
+\section{Establishing the Mesh}\index{mesh, establishing}
 
 One obvious way that the present example differs from
@@ -990,5 +994,5 @@
 \file{project.py}:
 
-\verbatiminput{../../demos/cairns/project.py}
+\verbatiminputunderscore{../../anuga_core/demos/cairns/project.py}
 
 Figure \ref{fig:cairns3d} illustrates the landscape of the region
@@ -1074,5 +1078,5 @@
 Make sure points on polygons are spaced to be no closer than the smallest resolution requested.
 
-\subsection{Initialising the Domain}
+\section{Initialising the Domain}
 
 Since we used \code{create_domain_from_regions} to create the mesh file, we do not need to 
@@ -1089,5 +1093,5 @@
 \end{verbatim}
 
-\subsection{Initial Conditions}
+\section{Initial Conditions}
 
 Quantities for \file{runcairns.py} are set
@@ -1097,5 +1101,5 @@
 auxiliary points file.
 
-\subsubsection{Stage}
+\subsection{Stage}
 
 The stage is initially set to 0.0 (i.e.\ Mean Sea Level) by the following statements:
@@ -1123,5 +1127,5 @@
 %large amplitude tsunami which would inundate the Cairns region.}
 
-\subsubsection{Friction}
+\subsection{Friction}
 
 We assign the friction exactly as we did for \file{runup.py}:
@@ -1131,5 +1135,5 @@
 \end{verbatim}
 
-\subsubsection{Elevation}
+\subsection{Elevation}
 
 The elevation is specified by reading data from a file with a name derived from
@@ -1153,5 +1157,5 @@
 the screen.
 
-\subsection{Boundary Conditions}\index{boundary conditions}
+\section{Boundary Conditions}\index{boundary conditions}
 
 Setting boundaries follows a similar pattern to the one used for
@@ -1190,5 +1194,5 @@
 how the script can take different actions depending on a variable.
 
-\subsection{Evolution}
+\section{Evolution}
 
 With the basics established, the running of the 'evolve' step is
@@ -1253,5 +1257,5 @@
 \file{ExportResults.py} demonstrates how this function can be used:
 
-\verbatiminput{demos/cairns/ExportResults.py}
+\verbatiminputunderscore{demos/cairns/ExportResults.py}
 
 The script generates a maximum water depth ASCII grid at a defined
@@ -1308,5 +1312,5 @@
 the gauges shown in Figure \ref{fig:cairnsgauges} is \file{gauges.csv}:
 
-\verbatiminput{demos/cairns/gauges.csv}
+\verbatiminputunderscore{demos/cairns/gauges.csv}
 
 Header information has been included to identify the location in terms of eastings and
@@ -1318,5 +1322,5 @@
 of the standard \code{anuga} release, however it can be downloaded and installed from \code{http://matplotlib.sourceforge.net/}
 
-\verbatiminput{demos/cairns/GetTimeseries.py}
+\verbatiminputunderscore{demos/cairns/GetTimeseries.py}
 
 Here, the time series for the quantities stage, depth and speed will be generated for
@@ -1347,30 +1351,38 @@
 
 %=================================
-\section{A Parallel Simulation}
-
-The previous examples were run just using one processor. \anuga also has the option of running in parallel using \mpi.
+\chapter{Parallel Simulation}
+
+The examples from the previous chapters were run just using one processor. As you will have noticed, the simulations can take a long time to run, especially if you are using a fine mesh. Indeed as you halve the spacing of the mesh, the number of triangles goes up by a factor of 4 and the timestep halves, so generally halving the spacing of the mesh increases the run time by approximately a factor of 8. 
+
+One way to alleviate this is to run your simulation in parallel and use more processors to spread the computational cost. 
+
+
+\anuga has the option of running in parallel using \mpi. A description of the method used to parallelize \anuga is given in section~\ref{theory:parallel}.
 
 Such jobs are run using the command
 
 \begin{verbatim}
-mpirun -np n python runParallelCairns.py
+mpirun -np n python runscript.py
 \end{verbatim}
 where \code{n} is the total number of processors being used for the parallel run. 
 
-Essentially we can expect speedups comparable to the number of cores available. This is measured via scalablity. We can expect scalability of 70\% when using up to the number of processors so that the local partitioned domains contain around 2000 triangles. 
-
-\subsection{The Code}
-
-Here is the code for \file{runParallelCairns.py}:
+Essentially we can expect speedups comparable to the number of cores available. This is measured via scalability. Our current experiments have demonstrated a scalability of 70\% or above when the number of processors are chosen so that the local partitioned meshes contain around 2000 triangles. 
+
+For instance, suppose we have a problem with a mesh of 500,000 triangles, and use 250 processors. Then the mesh will be partitioned into sub meshes of approximately 2000 triangles. 
+We would expect 70\% scalability, and so expect a speedup of $250 \times 0.7 = 175$. 
+
+\section{The Code}
+
+Here is the code for \file{runParallelCairns.py} which is found in the \file{demos/cairns} directory:
 
 \verbatiminputunderscore{../../anuga_core/demos/cairns/runParallelCairns.py}
 
 
-\subsection{Structure of the Code}
+\section{Structure of the Code}
 
 The code is very similar to the sequential code. The same procedures are used to setup the domain, setup the inital conditions, boundary conditions and evolve. 
 
 
-We first import a few procedures  need forthe parallel code.
+We first import a few procedures  need for the parallel code.
 \begin{verbatim}
 from anuga import distribute, myid, numprocs, finalize, barrier
@@ -1436,18 +1448,18 @@
 
 
-
-\section{Checkpointing}
-
-When running large and long running simulations, it is useful to provide a mechanism to allow the simulation to restarted if it is interupted mid simulation. Maybe there is a power cut, or when using batch queues there may be a time restriction on the length of any one running job. Then the use of checkpointing becomes useful. 
-
-The idea is that at regular intervals the system makes a copy of the current state of the computation. Then if there is an interruption the computation can be started from the last checkpoint time and not orginal start time. 
-
-\subsection{The Code}
+%=================================
+\chapter{Checkpointing}
+
+When running large and long running simulations, it is useful to provide a mechanism to allow the simulation to restarted if it is interrupted mid simulation. Maybe there is a power cut, or when using batch queues there may be a time restriction on the length of any one running job. Then the use of checkpointing becomes useful. 
+
+The idea is that at regular intervals the system makes a copy of the current state of the computation. Then if there is an interruption the computation can be started from the last checkpoint time and not original start time. 
+
+\section{The Code}
 
 Here is the code for \file{runCheckpoint.py}:
 
-\verbatiminput{../../anuga_core/demos/checkpointing/runCheckpoint.py}
-
-\subsection{Structure of the Code}
+\verbatiminputunderscore{../../anuga_core/demos/checkpointing/runCheckpoint.py}
+
+\section{Structure of the Code}
 
 As usual the code needs to import the required modules, and setup parameters and in this case procedures for setting up the stage and elevation. 
@@ -1489,5 +1501,5 @@
 will run the tests in verbose mode (produces output) and in parallel using 6 processors (if parallel version of anuga has been setup). 
 
-A subset of these validation tests can be run using \code{run_auto_validatoin_tests.py} from the \module{anuga_core} directory. 
+A subset of these validation tests can be run using \code{run_auto_validation_tests.py} from the \module{anuga_core} directory. 
 
 
@@ -3767,5 +3779,5 @@
 
 %FIXME (Ole): Should put in example with nonzero xllcorner, yllcorner
-\verbatiminput{examples/bedslopeexcerpt.cdl}
+\verbatiminputunderscore{examples/bedslopeexcerpt.cdl}
 
 The SWW format is used not only for output but also serves as input
@@ -3820,8 +3832,8 @@
 \subsection{Formats for Storing Arbitrary Points and Attributes}
 
-A CSV/TXT file is used to store data representing
+A CSV/TXT/XYA file is used to store data representing
 arbitrary numerical attributes associated with a set of points.
 
-The format for an CSV/TXT file is:\\
+The format for an CSV/TXT/XYA file is:\\
  \\
 first line:   \code{[column names]}\\
@@ -4242,4 +4254,5 @@
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 \section{Parallel Implementation}
+\label{theory:parallel}
 
 
@@ -5913,8 +5926,8 @@
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
-\chapter{Frequently Asked Questions}
-
-The Frequently Asked Questions have been move to the online FAQ at: \\
-\url{https://anuga.anu.edu.au/wiki/FrequentlyAskedQuestions}
+%\chapter{Frequently Asked Questions}
+%
+%The Frequently Asked Questions have been move to the online FAQ at: \\
+%\url{https://anuga.anu.edu.au/wiki/FrequentlyAskedQuestions}
 
 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
