Index: trunk/SophyaLib/SkyMap/localmap.cc
===================================================================
--- trunk/SophyaLib/SkyMap/localmap.cc	(revision 1196)
+++ trunk/SophyaLib/SkyMap/localmap.cc	(revision 1217)
@@ -9,75 +9,40 @@
 
 
-//*****************************************************************************
-//++ 
-// Class	LocalMap
-//
-// include      localmap.h 
-//
-//    A local map of a region of the sky, in cartesian coordinates.
-//    It has an origin in (theta0, phi0), mapped to pixel(x0, y0)
-//    (x0, y0 might be outside of this local map)
-//    default value of (x0, y0) is middle of the map, center of 
-//    pixel(nx/2, ny/2)
-//
-//    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()).
-//
-//    A "reference plane" is considered : this plane is tangent to the 
-//    celestial sphere in a point with angles theta=Pi/2 and phi=0. This 
-//    point is the origine of coordinates is of the reference plane. The 
-//    x-axis is the tangent parallel to the equatorial line and oriented 
-//    toward the increasing phi's ; the y-axis is parallel to the meridian 
-//    line and oriented toward the north pole.
-//    
-//    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-- see method 
-//    SetOrigin(...))
-//    
-//
-
-//
-//-- 
-//++
-//
-// Links	Parents
-//
-//    PixelMap
-//    
-//-- 
-//++
-//
-// Links	Childs
-//
-//     
-//-- 
-//++
-// Titre	Constructors
-//--
-//++
+/*!
+  \class SOPHYA::LocalMap
+
+  A local map has an origin in (theta0, phi0), mapped to pixel(x0, y0)
+   (x0, y0 might be outside of this local map)
+ default value of (x0, y0) is middle of the map, center of pixel(nx/2, ny/2)
+    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()).
+
+    A "reference plane" is considered : this plane is tangent to the 
+    celestial sphere in a point with angles theta=Pi/2 and phi=0. This 
+    point is the origine of coordinates is of the reference plane. The 
+    x-axis is the tangent parallel to the equatorial line and oriented 
+    toward the increasing phi's ; the y-axis is parallel to the meridian 
+    line and oriented toward the north pole.
+    
+    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-- see method 
+    SetOrigin(...))
+*/
 template<class T>
 LocalMap<T>::LocalMap() :  pixels_()
-//
-//     
-//--
 {
   InitNul();
-  //  pixels_.Reset();
-}
-
-//++
+}
+
 template<class T>
 LocalMap<T>::LocalMap(int_4 nx, int_4 ny) : nSzX_(nx), nSzY_(ny)
-//
-//    
-//--
 {
   InitNul();
@@ -87,12 +52,7 @@
 }
 
-//++
 template<class T>
 LocalMap<T>::LocalMap(const LocalMap<T>& lm, bool share)
   : pixels_(lm.pixels_, share)
-
-//
-//    copy constructor
-//--
 {
 
@@ -101,12 +61,8 @@
 }
 
-//++
 template<class T>
 LocalMap<T>::LocalMap(const LocalMap<T>& lm)
   : pixels_(lm.pixels_)
 
-//
-//    copy constructor
-//--
 {
 
@@ -115,12 +71,6 @@
 }
 
-//++
-// Titre	Destructor
-//--
-//++
 template<class T>
 LocalMap<T>::~LocalMap()
-//
-//--
 {
   InitNul();
@@ -129,14 +79,10 @@
 
 
-//++
-// Titre	Public Methods
-//--
-
-//++
+/*!  \fn void SOPHYA::LocalMap::ReSize(int_4 nx, int_4 ny) 
+
+  Resize storage area for pixels 
+*/
 template<class T>
 void LocalMap<T>::ReSize(int_4 nx, int_4 ny) 
-//
-//    Resize storage area for pixels 
-//--
 {
   InitNul();
@@ -188,44 +134,38 @@
 
 
-//++
+/*! \fn int_4 SOPHYA::LocalMap::NbPixels() const
+
+   \return number of pixels 
+*/
 template<class T>
 int_4 LocalMap<T>::NbPixels() const
-//
-//    Return number of pixels
-//--
 {
   return(nPix_);
 }
 
-//++
+/*! \fn T& SOPHYA::LocalMap::PixVal(int_4 k)
+
+   \return value of pixel with index k 
+*/
 template<class T>
 T& LocalMap<T>::PixVal(int_4 k)
-//
-//    Return value of pixel with index k
-//--
 {
   if((k < 0) || (k >= nPix_)) 
     {
       cout << " LocalMap::PIxVal : exceptions  a mettre en place" <<endl;
-      //  THROW(out_of_range("LocalMap::PIxVal Pixel index out of range"));
       THROW(rangeCheckErr);
-      //throw "LocalMap::PIxVal Pixel index out of range";
     }
   return(pixels_(k));
 }
 
-//++
-
+/*! \fn T const& SOPHYA::LocalMap::PixVal(int_4 k) const
+  const version of previous method 
+*/
 template<class T>
 T const& LocalMap<T>::PixVal(int_4 k) const
-//
-//   const version of previous method
-//--
 {
   if((k < 0) || (k >= nPix_)) 
     {
       cout << " LocalMap::PIxVal : exceptions  a mettre en place" <<endl;
-      //    THROW(out_of_range("LocalMap::PIxVal Pixel index out of range"));
-      
       throw "LocalMap::PIxVal Pixel index out of range"; 
     } 
@@ -233,4 +173,8 @@
 }
 
+/*! \fn bool SOPHYA::LocalMap::ContainsSph(double theta, double phi) const
+
+ \return true if teta,phi in map  
+*/
 template<class T>
 bool LocalMap<T>::ContainsSph(double theta, double phi) const
@@ -240,10 +184,10 @@
 }
 
-//++
+/*!  \fn int_4 SOPHYA::LocalMap::PixIndexSph(double theta,double phi) const
+
+  \return index of the pixel with spherical coordinates (theta,phi) 
+*/
 template<class T>
 int_4 LocalMap<T>::PixIndexSph(double theta,double phi) const
-//
-//    Return index of the pixel with spherical coordinates (theta,phi)
-//--
 {
   int_4 i,j;
@@ -284,10 +228,10 @@
 }
 
-//++
+/*! \fn void SOPHYA::LocalMap::PixThetaPhi(int_4 k,double& theta,double& phi) const
+
+   \return (theta, phi) coordinates of pixel with index k 
+*/
 template<class T>
 void LocalMap<T>::PixThetaPhi(int_4 k,double& theta,double& phi) const
-//
-//    Return (theta, phi) coordinates of pixel with index k
-//--
 {
   if(!(originFlag_) || !(extensFlag_)) 
@@ -311,4 +255,8 @@
 }
 
+/*! \fn T SOPHYA::LocalMap::SetPixels(T v)
+
+Set all pixels to value v 
+*/
 template <class T>
 T LocalMap<T>::SetPixels(T v)
@@ -318,12 +266,13 @@
 }
  
-//++
+/*! \fn double SOPHYA::LocalMap::PixSolAngle(int_4 k) const
+
+   Pixel Solid angle  (steradians)
+
+    All the pixels have not necessarly the same size in (theta, phi)
+    because of the projection scheme which is not yet fixed. 
+*/  
 template<class T>
 double LocalMap<T>::PixSolAngle(int_4 k) const
-//
-//    Pixel Solid angle  (steradians)
-//    All the pixels have not necessarly the same size in (theta, phi)
-//    because of the projection scheme which is not yet fixed.   
-//--
 {
   int_4 i,j;
@@ -355,11 +304,12 @@
 }
 
-//++
+/*! \fn void SOPHYA::LocalMap::SetOrigin(double theta0,double phi0,double angle)
+
+   set the referential of the map (angles in degrees)
+
+    (default x0=siz_x/2,  y0=siz_y/2) 
+*/
 template<class T>
 void LocalMap<T>::SetOrigin(double theta0,double phi0,double angle)
-//
-//    set the referential of the map (angles in degrees)
-//    (default x0=siz_x/2,  y0=siz_y/2) 
-//--
 {
   theta0_= theta0;
@@ -374,10 +324,10 @@
 }
  
-//++
+/*!  \fn void SOPHYA::LocalMap::SetOrigin(double theta0,double phi0,int_4 x0,int_4 y0,double angle)
+
+  set the referential of the map (angles in degrees) 
+*/
 template<class T>
 void LocalMap<T>::SetOrigin(double theta0,double phi0,int_4 x0,int_4 y0,double angle)
-//
-//    set the referential of the map (angles in degrees)
-//--
 {
   theta0_= theta0;
@@ -392,10 +342,10 @@
 } 
 
-//++
+/*! \fn void SOPHYA::LocalMap::SetSize(double angleX,double angleY)
+
+   angle range of tthe map (angles in degrees) 
+*/
 template<class T>
 void LocalMap<T>::SetSize(double angleX,double angleY)
-//
-//    angle range of tthe map (angles in degrees)
-//--
 {
   angleX_= angleX;
@@ -410,10 +360,10 @@
 }
 
-//++
+/*! \fn void SOPHYA::LocalMap::Project(SphericalMap<T>& sphere) const
+
+Projection to a spherical map 
+*/
 template<class T>
 void LocalMap<T>::Project(SphericalMap<T>& sphere) const
-//
-//    Projection to a spherical map   
-//--
 {
   for(int m = 0; m < nPix_; m++) 
@@ -440,10 +390,11 @@
 }
 
-//++
+
+/*!   \fn void SOPHYA::LocalMap::Getij(int_4 k,int_4& i,int_4& j) const
+
+ \return 2 indices corresponding to the pixel number k 
+*/
 template<class T>
 void LocalMap<T>::Getij(int_4 k,int_4& i,int_4& j) const
-//
-//    Return 2 indices corresponding to the pixel number k
-//--
 {
   i= (k+1)%nSzX_-1;
@@ -452,11 +403,11 @@
 }
 
-//++
+/*! \fn void  SOPHYA::LocalMap::ReferenceToUser(double& theta,double& phi) const
+
+   Transform a pair of coordinates (theta, phi) given in 
+    reference coordinates into map coordinates
+*/
 template<class T>
 void  LocalMap<T>::ReferenceToUser(double& theta,double& phi) const
-//
-//    Transform a pair of coordinates (theta, phi) given in 
-//    reference coordinates into map coordinates
-//--     
 {
   if(theta > Pi || theta < 0. || phi < 0. || phi >= 2*Pi) 
@@ -491,11 +442,11 @@
 }
 
-//++
+/*!  \fn void  SOPHYA::LocalMap::UserToReference(double& theta,double& phi) const
+
+  Transform a pair of coordinates (theta, phi) given in 
+   map coordinates into reference coordinates
+*/
 template<class T>
 void  LocalMap<T>::UserToReference(double& theta,double& phi) const
-//
-//    Transform a pair of coordinates (theta, phi) given in 
-//    map coordinates into reference coordinates
-//--     
 {
   if(theta > Pi || theta < 0. || phi < 0. || phi >= 2*Pi) 
@@ -534,12 +485,11 @@
 }
 
-//++
+/*! \fn void SOPHYA::LocalMap::PixProjToAngle(double x,double y,double& theta,double& phi) const
+
+  Given coordinates in pixel units in the REFERENCE PLANE, return
+    (theta, phi) in "absolute" referential theta=pi/2 ,phi=0.   
+*/
 template<class T>
 void LocalMap<T>::PixProjToAngle(double x,double y,double& theta,double& phi) const
-//
-//  
-//    Given coordinates in pixel units in the REFERENCE PLANE, return
-//    (theta, phi) in "absolute" referential theta=pi/2 ,phi=0.   
-//--
 {
   theta= Pi*0.5-atan(2.*y*tgAngleY_/(double)nSzY_);
@@ -548,11 +498,11 @@
 }
 
-//++
+/*! \fn void SOPHYA::LocalMap::AngleProjToPix(double theta,double phi,double& x,double& y) const
+
+   Given coordinates  (theta, phi) in "absolute" referential 
+    theta=pi/2 ,phi=0  return pixel indices  (i,j) in the REFERENCE PLANE.
+*/
 template<class T>
 void LocalMap<T>::AngleProjToPix(double theta,double phi,double& x,double& y) const
-//
-//    Given coordinates  (theta, phi) in "absolute" referential 
-//    theta=pi/2 ,phi=0  return pixel indices  (i,j) in the REFERENCE PLANE.
-//--
 {
   if(phi >= Pi) phi-= DeuxPi;
Index: trunk/SophyaLib/SkyMap/localmap.h
===================================================================
--- trunk/SophyaLib/SkyMap/localmap.h	(revision 1196)
+++ trunk/SophyaLib/SkyMap/localmap.h	(revision 1217)
@@ -10,48 +10,4 @@
 #include "ppersist.h"
 
-//! A local map of a region of the sky, in cartesian coordinates.
-/*! A local map has an origin in (theta0, phi0), mapped to pixel(x0, y0)
-   (x0, y0 might be outside of this local map)
- default value of (x0, y0) is middle of the map, center of pixel(nx/2, ny/2)
-    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()).
-
-    A "reference plane" is considered : this plane is tangent to the 
-    celestial sphere in a point with angles theta=Pi/2 and phi=0. This 
-    point is the origine of coordinates is of the reference plane. The 
-    x-axis is the tangent parallel to the equatorial line and oriented 
-    toward the increasing phi's ; the y-axis is parallel to the meridian 
-    line and oriented toward the north pole.
-    
-    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-- see method 
-    SetOrigin(...))
-*/
-//
-//    la carte est consideree comme un tableau a deux indices i et j, i etant 
-//    indice de colonne et j indice de ligne. La carte est supposee resider 
-//    dans un plan tangent, dont le point de tangence est repere (x0,y0) dans 
-//    la carte et (theta0, phi0) sur la sphere celeste. L extension de la 
-//    carte est definie par les valeurs de deux angles couverts respectivement
-//    par la totalite des pixels en x de la carte et la totalite des pixels 
-//    en y. (SetSize()).
-//    On considere un "plan de reference" : plan tangent a la sphere celeste 
-//    aux angles theta=Pi/2 et phi=0. Dans ce plan L origine des coordonnees 
-//    est le point de tangence. L axe Ox est la tangente parallele a 
-//    lequateur, dirige vers les phi croissants, l axe Oy est parallele 
-//    au meridien, dirige vers le pole nord.
-//    De maniere interne a la classe une carte est definie dans ce plan de 
-//    reference et transportee  jusqu au point (theta0, phi0) de sorte que les //    axes restent paralleles aux meridiens et paralleles. L utilisateur peut 
-//    definir sa carte selon un repere en rotation par rapport au repere de 
-//    reference (par l angle entre le parallele et l axe Ox souhaite -- 
-//    methode SetOrigin(...))
 
 
@@ -61,4 +17,7 @@
 
 namespace SOPHYA {
+
+
+/* Class LocalMap */
 
 
@@ -76,4 +35,5 @@
 
 inline virtual bool IsTemp(void) const { return pixels_.IsTemp();}
+
 /*! Setting blockdata to temporary (see ndatablock documentation) */
 inline virtual void SetTemp(bool temp=false) const {pixels_.SetTemp(temp);};
@@ -89,59 +49,32 @@
 // ---------- Definition of PixelMap abstract methods -------
 
-/* return/set the number of pixels */
-/*!    Return number of pixels */
 virtual int_4 NbPixels() const;   // D.Y. int change en int_4 rationalisation Mac
   
-/* return the value of pixel number k */
-/*!    Return value of pixel with index k */
 virtual T& PixVal(int_4 k);
-/*!   const version of previous method */
 virtual T const& PixVal(int_4 k) const;
 
-/* Return true if teta,phi in map  */
 virtual bool ContainsSph(double theta, double phi) const;
-/* return the index of pixel at (theta,phi) */
-/*!    Return index of the pixel with spherical coordinates (theta,phi) */
 virtual int_4 PixIndexSph(double theta,double phi) const;
    
-/* return the spherical coordinates of center of pixel number k */
-/*!    Return (theta, phi) coordinates of pixel with index k */
 virtual void PixThetaPhi(int_4 k,double& theta,double& phi) const;
 
-/*! Set all pixels to value v */
 virtual T SetPixels(T v);
 
-/* return the Pixel Solid angle  (steradians) */
-/*!    Pixel Solid angle  (steradians)
-
-    All the pixels have not necessarly the same size in (theta, phi)
-    because of the projection scheme which is not yet fixed. 
-*/  
 virtual double PixSolAngle(int_4 k) const; 
 
 // ---------- Specific methods ------------------------------
 
-/*!    Resize storage area for pixels */
 void ReSize(int_4 nx, int_4 ny);
 
 inline virtual char* TypeOfMap() const {return "LOCAL";};
  
-/* Origin (with angle between x axis and phi axis, in degrees)  x0,y0  the default: middle of map*/
-/*!    set the referential of the map (angles in degrees)
-
-    (default x0=siz_x/2,  y0=siz_y/2) 
-*/
 virtual void SetOrigin(double theta=90.,double phi=0.,double angle=0.);
-/*!    set the referential of the map (angles in degrees) */
 virtual void SetOrigin(double theta,double phi,int_4 x0,int_4 y0,double angle=0.);
 
-/* Pixel size (degres) */ 
-/*!    angle range of tthe map (angles in degrees) */
 virtual void SetSize(double angleX,double angleY);
 
-/* Check to see if the local mapping is done */
+/*! Check to see if the local mapping is done */
 inline bool LocalMap_isDone() const {return(originFlag_ && extensFlag_);};
 
-/*! Projection to a spherical map */
 virtual void Project(SphericalMap<T>& sphere) const;
   
@@ -149,5 +82,5 @@
       -> static method, or separate class */
   
-/* provides a integer characterizing the pixelization refinement  (here : number of pixels) */
+/*! provides a integer characterizing the pixelization refinement  (here : number of pixels) */
 inline virtual int_4 SizeIndex() const {return(nPix_);}
 inline int_4 Size_x() const {return nSzX_;}
@@ -180,21 +113,8 @@
 
 void InitNul();
-/*!    Return 2 indices corresponding to the pixel number k */
 void Getij(int_4 k,int_4& i,int_4& j) const;
-/*!    Transform a pair of coordinates (theta, phi) given in 
-    reference coordinates into map coordinates
-*/
 void ReferenceToUser(double& theta,double& phi) const; 
-/*!    Transform a pair of coordinates (theta, phi) given in 
-   map coordinates into reference coordinates
-*/
 void UserToReference(double& theta,double& phi) const;
-/*!   Given coordinates in pixel units in the REFERENCE PLANE, return
-    (theta, phi) in "absolute" referential theta=pi/2 ,phi=0.   
-*/
 void PixProjToAngle(double x,double y,double& theta,double& phi) const; 
-/*!    Given coordinates  (theta, phi) in "absolute" referential 
-    theta=pi/2 ,phi=0  return pixel indices  (i,j) in the REFERENCE PLANE.
-*/
 void AngleProjToPix(double theta,double phi,double& x,double& y) const; 
 
Index: trunk/SophyaLib/SkyMap/spherehealpix.cc
===================================================================
--- trunk/SophyaLib/SkyMap/spherehealpix.cc	(revision 1196)
+++ trunk/SophyaLib/SkyMap/spherehealpix.cc	(revision 1217)
@@ -17,55 +17,44 @@
 using namespace SOPHYA;
 
-//*******************************************************************
-//++ 
-// Class	SphereHEALPix
-//
-// include      SphereHealpix.h strutil.h
-//
-//    Pixelisation Gorski  
-//
-//
-//|    -----------------------------------------------------------------------
-//|     version 0.8.2  Aug97 TAC  Eric Hivon, Kris Gorski
-//|    -----------------------------------------------------------------------
-//
-//    the sphere is split in 12 diamond-faces containing nside**2 pixels each
-//
-//    the numbering of the pixels (in the nested scheme) is similar to
-//    quad-cube
-//    In each face the first pixel is in the lowest corner of the diamond
-//
-//    the faces are                    (x,y) coordinate on each face
-//|        .   .   .   .   <--- North Pole
-//|       / \ / \ / \ / \                          ^        ^     
-//|      . 0 . 1 . 2 . 3 . <--- z = 2/3             \      /      
-//|       \ / \ / \ / \ /                        y   \    /  x   
-//|      4 . 5 . 6 . 7 . 4 <--- equator               \  /                     
-//|       / \ / \ / \ / \                              \/        
-//|      . 8 . 9 .10 .11 . <--- z = -2/3              (0,0) : lowest corner  
-//|       \ / \ / \ / \ /                                  
-//|        .   .   .   .   <--- South Pole
-//|
-//    phi:0               2Pi                                 
-//
-//    in the ring scheme pixels are numbered along the parallels
-//    the first parallel is the one closest to the north pole and so on
-//    on each parallel, pixels are numbered starting from the one closest
-//    to phi = 0
-//
-//    nside MUST be a power of 2 (<= 8192)
-//--
-//++
-//
-// Links	Parents
-//
-//    SphericalMap 
-//-- 
+/*!
+  \class SOPHYA::SphereHEALPix
+
+*******************************************************************
+   Pixelisation Gorski  
+
+\verbatim
+
+    -----------------------------------------------------------------------
+     version 0.8.2  Aug97 TAC  Eric Hivon, Kris Gorski
+    -----------------------------------------------------------------------
+
+    the sphere is split in 12 diamond-faces containing nside**2 pixels each
+    the numbering of the pixels (in the nested scheme) is similar to
+    quad-cube
+    In each face the first pixel is in the lowest corner of the diamond
+    the faces are                    (x,y) coordinate on each face
+
+        .   .   .   .   <--- North Pole
+       / \ / \ / \ / \                          ^        ^     
+      . 0 . 1 . 2 . 3 . <--- z = 2/3             \      / 
+       \ / \ / \ / \ /                        y   \    /  x  
+      4 . 5 . 6 . 7 . 4 <--- equator               \  /      
+       / \ / \ / \ / \                              \/      
+      . 8 . 9 .10 .11 . <--- z = -2/3              (0,0) : lowest corner 
+       \ / \ / \ / \ /      
+        .   .   .   .   <--- South Pole
+\endverbatim
+    phi:0               2Pi                                 
+
+   in the ring scheme pixels are numbered along the parallels
+   the first parallel is the one closest to the north pole and so on  
+   on each parallel, pixels are numbered starting from the one closest
+    to phi = 0
+
+    nside MUST be a power of 2 (<= 8192)
+
+*/
 
 /* --Methode-- */
-//++
-// Titre	Constructors
-//--
-//++
 
 template<class T>
@@ -73,20 +62,21 @@
                                                 sliceLenght_()
 
-//--
+
 {
   InitNul();
-  //  SetTemp(false);
-}
-
-//++
+}
+
+/*! \fn   SOPHYA::SphereHEALPix::SphereHEALPix(int_4 m)
+ 
+  \param <m> : "nside" of the Healpix algorithm
+
+  The total number of pixels will be Npix =  12*nside**2
+
+  nside MUST be a power of 2 (<= 8192)
+*/
+
 template<class T>
 SphereHEALPix<T>::SphereHEALPix(int_4 m)
 
-//    m is the "nside" of the Gorski algorithm
-//
-//    The total number of pixels will be Npix =  12*nside**2
-//
-//    nside MUST be a power of 2 (<= 8192)
-//--
 {
 
@@ -202,14 +192,15 @@
 //--
 
-//++
+/*!  \fn   void SOPHYA::SphereHEALPix::Resize(int_4 m)
+  \param <m>   "nside" of the Gorski algorithm
+
+  The total number of pixels will be Npix =  12*nside**2
+
+  nside MUST be a power of 2 (<= 8192)
+*/
 template<class T>
 void SphereHEALPix<T>::Resize(int_4 m)
 
-//    m is the "nside" of the Gorski algorithm
-//
-//    The total number of pixels will be Npix =  12*nside**2
-//
-//    nside MUST be a power of 2 (<= 8192)
-//--
+
 {
   if (m<=0 || m> 8192) {
@@ -270,20 +261,22 @@
 
 /* --Methode-- */
-//++
+/* Nombre de pixels du decoupage */
+/*! \fn int_4 SOPHYA::SphereHEALPix::NbPixels() const
+
+   Return number of  pixels of the  splitting 
+*/
 template<class T>
 int_4 SphereHEALPix<T>::NbPixels() const
-
-//    Retourne le nombre de pixels du découpage
-//--
 {  
   return(nPix_);
 }
 
-//++
+
+/*! \fn uint_4 SOPHYA::SphereHEALPix::NbThetaSlices() const
+
+   \return number of slices in theta direction on the  sphere 
+*/
 template<class T>
 uint_4 SphereHEALPix<T>::NbThetaSlices() const 
-
-//    Return number of slices in theta direction on the  sphere
-//--
 {
   uint_4 nbslices = uint_4(4*nSide_-1);
@@ -296,22 +289,21 @@
 }
 
-//++
+/*!  \fn void SOPHYA::SphereHEALPix::GetThetaSlice(int_4 index,r_8& theta,TVector<r_8>& phi,TVector<T>& value) const 
+
+ For a theta-slice with index 'index', return :
+ 
+   the corresponding "theta" 
+
+   a vector containing the phi's of the pixels of the slice
+
+   a vector containing the corresponding values of pixels 
+*/
 template<class T>
 void SphereHEALPix<T>::GetThetaSlice(int_4 index,r_8& theta,TVector<r_8>& phi,TVector<T>& value) const 
 
-//    For a theta-slice with index 'index', return : 
-//
-//    the corresponding "theta" 
-//
-//    a vector containing the phi's of the pixels of the slice
-//
-//    a vector containing the corresponding values of pixels 
-//
-//--
 {
 
   if (index<0 || index >= NbThetaSlices()) 
     {
-      // THROW(out_of_range("SphereHEALPix::PIxVal Pixel index out of range")); 
       cout << " SphereHEALPix::GetThetaSlice : Pixel index out of range" <<endl;
       throw RangeCheckError(" SphereHEALPix::GetThetaSlice : Pixel index out of range");
@@ -335,26 +327,26 @@
   theta= TH;
 }
-//++
-//++
+/*! \fn void SOPHYA::SphereHEALPix::GetThetaSlice(int_4 sliceIndex,r_8& theta, r_8& phi0, TVector<int_4>& pixelIndices,TVector<T>& value) const
+
+   For a theta-slice with index 'index', return : 
+
+   the corresponding "theta" 
+
+   the corresponding "phi" for first pixel of the slice 
+
+    a vector containing indices of the pixels of the slice
+
+   (equally distributed in phi)
+
+    a vector containing the corresponding values of pixels 
+*/
 
 template<class T>
 void SphereHEALPix<T>::GetThetaSlice(int_4 sliceIndex,r_8& theta, r_8& phi0, TVector<int_4>& pixelIndices,TVector<T>& value) const 
 
-//    For a theta-slice with index 'sliceIndex', return : 
-//
-//    the corresponding "theta" 
-//    the corresponding "phi" for first pixel of the slice 
-//
-//    a vector containing the indices of the pixels of the slice
-//    (equally distributed in phi)
-//
-//    a vector containing the corresponding values of pixels 
-//
-//--
 {
 
   if (sliceIndex<0 || sliceIndex >= NbThetaSlices()) 
     {
-      // THROW(out_of_range("SphereHEALPix::PIxVal Pixel index out of range")); 
       cout << " SphereHEALPix::GetThetaSlice : Pixel index out of range" <<endl;
       throw RangeCheckError(" SphereHEALPix::GetThetaSlice : Pixel index out of range");
@@ -372,9 +364,7 @@
   PixThetaPhi(iring, theta, phi0);
 }
-//++
+
 template<class T>
 void SphereHEALPix<T>::SetThetaSlices()  
-
-//--
 {
   sliceBeginIndex_.ReSize(4*nSide_-1);
@@ -399,11 +389,12 @@
 }
 
-/* --Methode-- */
-//++
+
+/*! \fn T& SOPHYA::SphereHEALPix::PixVal(int_4 k)
+
+   \return value of  pixel with "RING" index k 
+*/
 template<class T>
 T& SphereHEALPix<T>::PixVal(int_4 k)
 
-//    Return value of  pixel with "RING" index k 
-//--
 {
   if((k < 0) || (k >= nPix_)) 
@@ -414,11 +405,11 @@
 }
 
-/* --Methode-- */
-//++
+/*! \fn T const& SOPHYA::SphereHEALPix::PixVal(int_4 k) const
+
+   \return value of  pixel with "RING" index k 
+*/
 template<class T>
 T const& SphereHEALPix<T>::PixVal(int_4 k) const
 
-//    Return value of  pixel with "RING" index k 
-//--
 {
   if((k < 0) || (k >= nPix_)) 
@@ -429,9 +420,11 @@
 }
 
-//++
+/*! \fn T& SOPHYA::SphereHEALPix::PixValNest(int_4 k)
+
+   \return value of  pixel with "NESTED" index k 
+*/
 template<class T>
 T& SphereHEALPix<T>::PixValNest(int_4 k)
 
-//    Return value of  pixel with "NESTED" index k 
 //--
 {
@@ -442,11 +435,13 @@
   return pixels_(nest2ring(nSide_,k));
 }
-//++
+
+/*!  \fn T const& SOPHYA::SphereHEALPix::PixValNest(int_4 k) const
+
+  \return value of  pixel with "NESTED" index k 
+*/
 
 template<class T>
 T const& SphereHEALPix<T>::PixValNest(int_4 k) const
 
-//    Return value of  pixel with "NESTED" index k 
-//--
 {
   if((k < 0) || (k >= nPix_)) 
@@ -458,48 +453,51 @@
 }
 
+/*! \fn bool SOPHYA::SphereHEALPix::ContainsSph(double theta, double phi) const
+
+\return true if teta,phi in map 
+*/
+template<class T>
+bool SphereHEALPix<T>::ContainsSph(double theta, double phi) const
+{
+return(true);
+}
+
+/*! \fn int_4 SOPHYA::SphereHEALPix::PixIndexSph(double theta,double phi) const
+
+ \return "RING" index of the pixel corresponding to direction (theta, phi).
+ */
+template<class T>
+int_4 SphereHEALPix<T>::PixIndexSph(double theta,double phi) const
+
+{
+  return ang2pix_ring(nSide_,theta,phi);
+}
+
+/*! \fn int_4 SOPHYA::SphereHEALPix::PixIndexSphNest(double theta,double phi) const
+
+ \return "NESTED" index of the pixel corresponding to direction (theta, phi).
+ */
+template<class T>
+int_4 SphereHEALPix<T>::PixIndexSphNest(double theta,double  phi) const
+
+{
+  return ang2pix_nest(nSide_,theta,phi);
+}
+
+
 /* --Methode-- */
-//++
-template<class T>
-bool SphereHEALPix<T>::ContainsSph(double /*theta*/, double /*phi*/) const
-//--
-{
-return(true);
-}
-
-/* --Methode-- */
-//++
-template<class T>
-int_4 SphereHEALPix<T>::PixIndexSph(double theta,double phi) const
-
-//    Return "RING" index of the pixel corresponding to 
-//    direction (theta, phi).
-//--
-{
-  return ang2pix_ring(nSide_,theta,phi);
-}
-
-//++
-template<class T>
-int_4 SphereHEALPix<T>::PixIndexSphNest(double theta,double  phi) const
-
-//    Return "NESTED" index of the pixel corresponding to 
-//    direction (theta, phi).
-//--
-{
-  return ang2pix_nest(nSide_,theta,phi);
-}
-
-
-/* --Methode-- */
-//++
+/*! \fn void SOPHYA::SphereHEALPix::PixThetaPhi(int_4 k,double& theta,double& phi) const
+ \return (theta,phi) coordinates of middle of  pixel with "RING" index k
+ */
 template<class T>
 void SphereHEALPix<T>::PixThetaPhi(int_4 k,double& theta,double& phi) const
-
-//   Return (theta,phi) coordinates of middle of  pixel with "RING" index k
-//--
 {
   pix2ang_ring(nSide_,k,theta,phi);
 }
 
+/*! \fn T SOPHYA::SphereHEALPix::SetPixels(T v)
+
+Set all pixels to value v 
+*/
 template <class T>
 T SphereHEALPix<T>::SetPixels(T v)
@@ -509,44 +507,36 @@
 }
 
-//++
-template<class T>
-double SphereHEALPix<T>::PixSolAngle(int_4 /*dummy*/) const
-//    Pixel Solid angle  (steradians)
-//    All the pixels have the same solid angle. The dummy argument is
-//    for compatibility with eventual pixelizations which would not 
-//    fulfil this requirement.
-//--
-{
-  return omeg_;
-}
-
-//++
+
+
+/*! \fn void SOPHYA::SphereHEALPix::PixThetaPhiNest(int_4 k,double& theta,double& phi) const
+
+  \return (theta,phi) coordinates of middle of  pixel with "NESTED" index k
+ */
 template<class T>
 void SphereHEALPix<T>::PixThetaPhiNest(int_4 k,double& theta,double& phi) const
 
-//   Return (theta,phi) coordinates of middle of  pixel with "NESTED" index k
-//--
 {   
   pix2ang_nest(nSide_,k,theta,phi);
 }
 
-//++
+
+/*! \fn int_4 SOPHYA::SphereHEALPix::NestToRing(int_4 k) const
+
+   translation from NESTED index  into RING index 
+*/
 template<class T>
 int_4 SphereHEALPix<T>::NestToRing(int_4 k) const
 
-//    translation from NESTED index  into RING index 
-//
-//--
 {
   return  nest2ring(nSide_,k);
 }
 
-//++
+
+/*!  \fn  int_4 SOPHYA::SphereHEALPix::RingToNest(int_4 k) const
+
+ translation from  RING index  into NESTED index 
+*/
 template<class T>
 int_4 SphereHEALPix<T>::RingToNest(int_4 k) const
-//
-//    translation from  RING index  into NESTED index 
-//
-//--
 {
   return  ring2nest(nSide_,k);
@@ -571,13 +561,4 @@
   os << endl;
 
-  os << endl;
-  //const PIXELS_XY& PXY= PIXELS_XY::instance();
-
-  //os << endl;  os << " contenu des tableaux conversions "<<endl;
-  //for(int i=0; i < 5; i++)
-  //  {
-  //   os<<PXY.pix2x_(i)<<", "<<PXY.pix2y_(i)<<", "<<PXY.x2pix_(i)<<", "<<PXY.y2pix_(i)<<endl;
-  // }
-  os << endl;
 
 }
Index: trunk/SophyaLib/SkyMap/spherehealpix.h
===================================================================
--- trunk/SophyaLib/SkyMap/spherehealpix.h	(revision 1196)
+++ trunk/SophyaLib/SkyMap/spherehealpix.h	(revision 1217)
@@ -16,41 +16,5 @@
 // ***************** CLASSE SphereHEALPix *****************************
 
-//!  class SphereHEALPix
-/*!
-   Pixelisation Gorski  
-
-
-    -----------------------------------------------------------------------
-     version 0.8.2  Aug97 TAC  Eric Hivon, Kris Gorski
-    -----------------------------------------------------------------------
-
-    the sphere is split in 12 diamond-faces containing nside**2 pixels each
-
-    the numbering of the pixels (in the nested scheme) is similar to
-    quad-cube
-    In each face the first pixel is in the lowest corner of the diamond
-
-    the faces are                    (x,y) coordinate on each face
-\verbatim
-        .   .   .   .   <--- North Pole
-       / \ / \ / \ / \                          ^        ^     
-      . 0 . 1 . 2 . 3 . <--- z = 2/3             \      / 
-       \ / \ / \ / \ /                        y   \    /  x  
-      4 . 5 . 6 . 7 . 4 <--- equator               \  /      
-       / \ / \ / \ / \                              \/      
-      . 8 . 9 .10 .11 . <--- z = -2/3              (0,0) : lowest corner 
-       \ / \ / \ / \ /      
-        .   .   .   .   <--- South Pole
-\endverbatim
-    phi:0               2Pi                                 
-
-   in the ring scheme pixels are numbered along the parallels
-   the first parallel is the one closest to the north pole and so on  
-   on each parallel, pixels are numbered starting from the one closest
-    to phi = 0
-
-    nside MUST be a power of 2 (<= 8192)
-
-*/
+  /*! Class SphereHEALPix */
 
 
@@ -81,18 +45,9 @@
 
 SphereHEALPix();
-/*!    
-  m is the "nside" of the Gorski algorithm
-
-  The total number of pixels will be Npix =  12*nside**2
-
-  nside MUST be a power of 2 (<= 8192)
-*/
 SphereHEALPix(int_4 m);
 SphereHEALPix(const SphereHEALPix<T>& s, bool share);
 SphereHEALPix(const SphereHEALPix<T>& s);
-//!	Destructor
 virtual ~SphereHEALPix();
 
-  // Temporaire?
 inline virtual bool   IsTemp(void) const {
 
@@ -101,5 +56,5 @@
     return pixels_.IsTemp();
 }
-/*! Setting blockdata to temporary (see ndatablock documentation) */
+
 inline virtual void SetTemp(bool temp=false) const 
   {
@@ -110,55 +65,21 @@
 // ------------------ Definition of PixelMap abstract methods
 
-/* Nombre de pixels du decoupage */
-/*!    Return number of  pixels of the  splitting */
 virtual int_4 NbPixels() const;
 
-/* Valeur du contenu du pixel d'indice "RING" k  */
-/*!    Return value of  pixel with "RING" index k */
 virtual T& PixVal(int_4 k);
 virtual T const& PixVal(int_4 k) const;
 
-/* Nombre de tranches en theta */ 
-/*!    Return number of slices in theta direction on the  sphere */
 uint_4 NbThetaSlices() const;
-/*!   For a theta-slice with index 'index', return : 
-
-   the corresponding "theta" 
-
-    a vector containing the phi's of the pixels of the slice
-
-    a vector containing the corresponding values of pixels 
-*/
 virtual void GetThetaSlice(int_4 index,r_8& theta,TVector<r_8>& phi,TVector<T>& value) const;
-/*!   For a theta-slice with index 'index', return : 
-
-   the corresponding "theta" 
-
-   the corresponding "phi" for first pixel of the slice 
-
-    a vector containing indices of the pixels of the slice
-
-   (equally distributed in phi)
-
-    a vector containing the corresponding values of pixels 
-*/
 virtual void GetThetaSlice(int_4 sliceIndex,r_8& theta, r_8& phi0, TVector<int_4>& pixelIndices,TVector<T>& value) const ;
 
-/* Return true if teta,phi in map  */
 virtual bool ContainsSph(double theta, double phi) const;
-/* Indice "RING" du pixel vers lequel pointe une direction definie par 
-ses  coordonnees spheriques */                                    
-/*!  Return "RING" index of the pixel corresponding to direction (theta, phi).
- */
 virtual int_4 PixIndexSph(double theta,double phi) const;
 
-/* Coordonnees spheriques du milieu du pixel d'indice "RING" k   */
 virtual void PixThetaPhi(int_4 k,double& theta,double& phi) const;
 
-/*! Set all pixels to value v */
 virtual T SetPixels(T v);
 
-/* Pixel Solid angle  (steradians) */
-/*!    Pixel Solid angle  (steradians)
+/*! Pixel Solid angle  (steradians)
 
     All the pixels have the same solid angle. The dummy argument is
@@ -166,5 +87,5 @@
    fulfil this requirement.
 */
-virtual double PixSolAngle(int_4 dummy=0) const;
+inline virtual double PixSolAngle(int_4 dummy=0) const {return omeg_;}
 
 /*  Acces to the DataBlock  */
@@ -174,50 +95,32 @@
 // --------------- Specific methods 
 
-/*!    
-  m is the "nside" of the Gorski algorithm
-
-  The total number of pixels will be Npix =  12*nside**2
-
-  nside MUST be a power of 2 (<= 8192)
-*/
 virtual void Resize(int_4 m);
 
-// pour l'instant le tableau est ordonne selon RING, uniquement
+/*! 
+
+\return type of storage of the map : RING or NESTED
+
+at the moment, always RING
+*/
 inline virtual char* TypeOfMap() const {return "RING";};
 
 
-/* Valeur du contenu du pixel d'indice "NEST" k */
-/*!    Return value of  pixel with "NESTED" index k */
 virtual T& PixValNest(int_4 k);
-/*!    Return value of  pixel with "NESTED" index k */
 virtual T const& PixValNest(int_4 k) const;
 
-/* Indice "NEST" du pixel vers lequel pointe une direction definie par 
-ses  coordonnees spheriques */                                    
-/*! Return "NESTED" index of the pixel corresponding to direction (theta, phi).
- */
 virtual int_4 PixIndexSphNest(double theta,double phi) const;
 
-/* Coordonnees spheriques du milieu du pixel d'indice "NEST" k       */
-/*!   Return (theta,phi) coordinates of middle of  pixel with "NESTED" index k
- */
 virtual void PixThetaPhiNest(int_4 k,double& theta,double& phi) const;
 
-/* algorithme de pixelisation */
 void Pixelize(int_4); 
 
-/* convertit index nested en ring  */
-/*!    translation from NESTED index  into RING index */
 int_4 NestToRing(int_4) const;
 
-/* convertit index ring en nested" */
-/*!    translation from  RING index  into NESTED index */
 int_4 RingToNest(int_4) const;
 
 
-/* retourne la valeur du parametre Gorski */
+/*! \return value of healpix nside */
 inline virtual int_4 SizeIndex() const {return(nSide_);}
 
-/* impression */ 
 void print(ostream& os) const;
 
@@ -256,5 +159,5 @@
 
 NDataBlock<T> pixels_;
-NDataBlock<int_4> sliceBeginIndex_;		// Rationalisation Mac. 	D.Y.
+NDataBlock<int_4> sliceBeginIndex_;	    // Rationalisation Mac. D.Y.
 NDataBlock<int_4> sliceLenght_;
 
