Commit e635b467 authored by Jean-Eric Campagne's avatar Jean-Eric Campagne
Browse files

(JEC) 24/11/15 complet the Readme for instance to introduce the setup procedure

parent 10e20127
......@@ -11,6 +11,13 @@ git clone https://gitlab.in2p3.fr/campagne/LagSHT.git
# List of files
* **root** directory
* COPYING
* Readme.md : this file
* Documentation.md : a brief summary of the mathematics implemented
* Makefile
* Darwin_g++_omp_make.inc : file included into Makefile in case of running on Mac Os X system
* Linux_g++_make.inc : idem but for Linux system
* **src** directory
* laguerreBuilder.h (.cc) : class of generalized Laguerre function
* laguerreTransform.h (.cc) : class to manage the Laguerre function Transform (Synthesis & Analysis): Single or Multiple
......@@ -54,7 +61,7 @@ If the variable `CBLAS` is defined then the code of laguerreTransform.cc use the
This is simply header files which are needed to access to the `"boost/math/special_functions/bessel.hpp"` and related headers of the library.
# Compilation
# Compilation/Installation/Setup
1. edit Makefile and adapat to local platform :
* adapt to the type of Machine MacOSX (Darwin) vs Linux
......@@ -92,6 +99,7 @@ This is simply header files which are needed to access to the `"boost/math/speci
Similarly, the library is in <root>/lib but one can switch to
another location by modifying the LIB variable in the
Makefile.
6. execute setup.[c]sh depending on your shell to setup **LAGSHTROOTDIR** environment variable.
# Plateform tested
Mac OS X 10.9.5 + gcc 4.8.4
......
......@@ -425,6 +425,9 @@ void TestLaguerre2Bessel() {
cout << "tstack 2 End" <<endl;
tstack_pop("processing");
//verif F-Laguerre part
tstack_push("F-L Analysis verif");
vector< complex<r_8> > flmn(Ntot);
......@@ -455,14 +458,15 @@ void TestLaguerre2Bessel() {
tstack_pop("F-L Analysis verif");
tstack_pop("processing");
{//Check 1
cout << "Dump FL or FB reconstructed Alm(r_k)" <<endl;
#if DEBUG >=2
std::ofstream ofs;
ofs.open ("Almi.txt", std::ofstream::out);
#endif
for(int n=0;n<Nmax;n++){
r_8 err_abs(0.);
......@@ -471,11 +475,13 @@ void TestLaguerre2Bessel() {
for(int l=0;l<Lmax;l++){
for (int m=0;m<=l;m++) {
int id= n*Nalm + l+m*Lmax-m*(m+1)/2; // LagSHT numbering
#if DEBUG >=2
ofs <<l<<" "
<<m<<" "
<<n<< " " << setprecision(12) << FLalmk[id].real() << " " << FLalmk[id].imag()
<< " " << FBalmk[id].real() << " " << FBalmk[id].imag() << endl;
#endif
complex<r_8> cdiff = (FLalmk[id] - FBalmk[id])*conj(FLalmk[id] - FBalmk[id]);
r_8 diff = sqrt(cdiff.real());
if(diff>err_abs){
......@@ -493,14 +499,16 @@ void TestLaguerre2Bessel() {
cout << " >>>>>>>>>>>>>>>>>>>>> <<<<<<<<<<<<<<<<<<<<<<<<<<" << endl;
}
#if DEBUG >=2
ofs.close();
#endif
}//check 1
{//check 2
#if DEBUG >=2
std::ofstream ofs;
ofs.open ("fijk.txt", std::ofstream::out);
#endif
cout << "Dump FL or FB reconstructed fijk on each shell k" <<endl;
for (int ish=0;ish<Nshell; ish++){
......@@ -509,7 +517,10 @@ void TestLaguerre2Bessel() {
for (int ip=0; ip<Npix; ip++) {
int id = ish*Npix+ip;
// cout << "Shell("<<ish<<") Pix["<<ip<<"] FL fijk = " << fFLijk[id] << " FB fijk = " << fFBijk[id] << endl;
#if DEBUG >=2
ofs << ish << " " << ip << " " << setprecision(12) << fFLijk[id] << " " << fFBijk[id] << endl;
#endif
r_8 diff = fabs(fFLijk[id]-fFBijk[id]);
if(diff>err_abs){
err_abs = diff;
......@@ -526,7 +537,9 @@ void TestLaguerre2Bessel() {
}//loop on shell
#if DEBUG >=2
ofs.close();
#endif
}//check 2
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment