Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
Jean-Eric Campagne
LagSHT
Commits
8c406946
Commit
8c406946
authored
Nov 24, 2015
by
Jean-Eric Campagne
Browse files
(JEC) 24/11/15 adapt for Linux
parent
aee955b4
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
7 deletions
+17
-7
Makefile
Makefile
+11
-4
src/lagsht_testsuite.cc
src/lagsht_testsuite.cc
+1
-1
src/laguerre2bessel.cc
src/laguerre2bessel.cc
+5
-2
No files found.
Makefile
View file @
8c406946
...
...
@@ -13,6 +13,9 @@ ifeq ($(MACH), Linux)
BLASLIB
=
-L
$(BLASDIR)
/lib
BLASLIBN
=
$(BLASLIB)
-lopenblas
endif
# ==== Boost ======
BOOSTDIR
=
/exp/opera/kits/boost_1_59_0
BOOSTINC
=
-I
$(BOOSTDIR)
else
include
Darwin_g++_omp_make.inc
# ===== nNative BLAS (Darwin)
...
...
@@ -29,7 +32,7 @@ endif
# ===== Libsharp =====
#SHARPDIR = <yourdir>/libsharp-code/auto/
SHARPDIR
=
/
Users/campagne/Travail
/kits/libsharp-code/auto
SHARPDIR
=
/
exp/opera
/kits/libsharp-code/auto
SHARPLIB
=
$(SHARPDIR)
/lib
SHARPINC
=
-I
$(SHARPDIR)
/include
SHARPLIBN
=
-L
$(SHARPLIB)
-lsharp
-lc_utils
-lfftpack
...
...
@@ -72,12 +75,16 @@ confcheck :
@
echo
"Config check mach=<
$(MACH)
> sharp=<
$(SHARPDIR)
> blas=<
$(BLASDIR)
>"
ifeq
($(BLAS), 1)
@
if
[
!
-d
"
$(BLASDIR)
"
]
;
then
\
echo
"BLAS directory not defined properly
!
"
;
\
echo
"BLAS directory not defined properly
:
$BLASDIR
"
;
\
exit
1
;
\
fi
;
endif
@
if
[
!
-d
"
$(SHARPDIR)
"
]
;
then
\
echo
"SHARP directory not defined properly!"
;
\
echo
"SHARP directory not defined properly:
$SHARPDIR
"
;
\
exit
1
;
\
fi
;
@
if
[
!
-d
"
$(BOOSTDIR)
"
]
;
then
\
echo
"BOOST directory not defined properly:
$BOOSTDIR
"
;
\
exit
1
;
\
fi
;
...
...
@@ -125,7 +132,7 @@ CXXHDR = $(SRC)lagsht_exceptions.h \
$(SRC)
laguerre2bessel.h
\
$(SRC)
quadinteg.h
CPPFLAGS
+=
$(BLASYES)
$(SHARPINC)
$(BLASINC)
CPPFLAGS
+=
$(BLASYES)
$(SHARPINC)
$(BLASINC)
$(BOOSTINC)
LDFLAGS
+=
$(SHARPLIBN)
$(BLASLIBN)
-lm
...
...
src/lagsht_testsuite.cc
View file @
8c406946
...
...
@@ -574,7 +574,7 @@ void TestPixelization() {
int
state
=
1234567
+
8912
;
//random seed
stringstream
ss
;
ss
<<
"pixels-"
<<
geometry
<<
"-L"
<<
Lmax
<<
".txt"
;
std
::
ofstream
ofs
(
ss
.
str
(),
std
::
ofstream
::
out
);
std
::
ofstream
ofs
(
ss
.
str
()
.
c_str
()
,
std
::
ofstream
::
out
);
r_8
dTheta
=
M_PI
/
ntheta
/
2
;
r_8
dPhi
=
2
*
M_PI
/
nphi
/
2
;
...
...
src/laguerre2bessel.cc
View file @
8c406946
...
...
@@ -8,6 +8,7 @@
#include "walltimer.h" //timing
#include <fstream> //dump
#include <sstream>
#include <numeric>
#define DEBUG 0
...
...
@@ -47,7 +48,8 @@ Laguerre2Bessel::Laguerre2Bessel(BaseGeometry* sphere,
//read the Rmax-independant values of the jlnp and rescale
stringstream
ss
;
ss
<<
"jlnp-L"
<<
Lmax_
<<
"-N"
<<
Nmax_
<<
"-P"
<<
Pmax_
<<
"-PP"
<<
PPmax_
<<
".txt"
;
std
::
ifstream
ifs
(
jlnpDir
+
"/"
+
ss
.
str
(),
std
::
ifstream
::
in
);
string
fname
(
jlnpDir
+
"/"
+
ss
.
str
());
std
::
ifstream
ifs
(
fname
.
c_str
(),
std
::
ifstream
::
in
);
if
(
!
ifs
.
is_open
())
throw
LagSHTError
(
"ERROR: jlnp file open failed.:"
+
ss
.
str
());
...
...
@@ -138,7 +140,8 @@ void Laguerre2Bessel::ComputeJInteg(string clenshawDir, string jlnpDir){
stringstream
ss
;
ss
<<
"jlnp-L"
<<
Lmax_
<<
"-N"
<<
Nmax_
<<
"-P"
<<
Pmax_
<<
"-PP"
<<
PPmax_
<<
".txt"
;
std
::
ofstream
ofs
;
ofs
.
open
(
jlnpDir
+
"/"
+
ss
.
str
(),
std
::
ofstream
::
out
);
string
fname
(
jlnpDir
+
"/"
+
ss
.
str
());
ofs
.
open
(
fname
.
c_str
(),
std
::
ofstream
::
out
);
// cout << "(JEC) Jlpn recompute..." << endl;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment