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
b8c1a6a9
Commit
b8c1a6a9
authored
Apr 29, 2015
by
Jean-Eric Campagne
Browse files
(JEC) 29/4/15 use a ptr to LaguerreTransform in LaguerreSphericalTransform
parent
b11375eb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
12 deletions
+24
-12
lagSphericTransform.cc
lagSphericTransform.cc
+2
-2
lagSphericTransform.h
lagSphericTransform.h
+22
-10
No files found.
lagSphericTransform.cc
View file @
b8c1a6a9
...
...
@@ -33,7 +33,7 @@ void LaguerreSphericalTransform::Synthesis(const vector< complex<r_8> >& flmn,
#endif
tstack_push
(
"Laguerre MultiSynthesis"
);
lagTrans_
.
MultiSynthesis
(
flmn
,
flmk
,
Nalm_
);
lagTrans_
->
MultiSynthesis
(
flmn
,
flmk
,
Nalm_
);
tstack_pop
(
"Laguerre MultiSynthesis"
);
...
...
@@ -108,7 +108,7 @@ void LaguerreSphericalTransform::Analysis(const vector<r_8>& fijk,
tstack_push
(
"Laguerre MultiAnalysis"
);
//Laguerre Transform
lagTrans_
.
MultiAnalysis
(
almk
,
flmn
,
Nalm_
);
lagTrans_
->
MultiAnalysis
(
almk
,
flmn
,
Nalm_
);
#if DEBUG >= 1
cout
<<
"End Laguerre..."
<<
endl
;
...
...
lagSphericTransform.h
View file @
b8c1a6a9
...
...
@@ -26,10 +26,10 @@ namespace LagSHT {
class
LaguerreSphericalTransform
{
public:
//! Constructor
LaguerreSphericalTransform
(
string
spheregeom
,
int
Lmax
,
int
Mmax
,
int
Nmax
,
r_8
R
,
int
Nrings
=
-
1
,
int
Nphi
=
-
1
,
int
alpha
=
2
)
:
R_
(
R
)
,
lagTrans_
(
Nmax
,
R
,
alpha
)
{
R_
(
R
)
{
//Factory
if
(
spheregeom
==
"ECP"
||
spheregeom
==
"Fejer1"
)
{
...
...
@@ -43,36 +43,48 @@ class LaguerreSphericalTransform {
sphere_
=
0
;
throw
LagSHTError
(
"LaguerreSphericalTransform::Ctor wrong geometry type"
);
}
lagTrans_
=
new
LaguerreTransform
(
Nmax
,
R
,
alpha
);
//do the map pixelization
if
(
sphere_
)
{
//JEC sphere_->SetMap(Nrings, Nphi);
//store localy usefull parameters for the algorithms Analysis/Synthesis
Npix_
=
sphere_
->
Npix
();
Nalm_
=
sphere_
->
Nalm
();
N_
=
lagTrans_
.
GetOrder
();
alpha_
=
lagTrans_
.
GetAlpha
(
);
}
else
{
throw
LagSHTError
(
"LaguerreSphericalTransform::Ctor sphere_ ptr NULL"
);
}
if
(
lagTrans_
)
{
N_
=
lagTrans_
->
GetOrder
();
alpha_
=
lagTrans_
->
GetAlpha
();
}
else
{
throw
LagSHTError
(
"LaguerreSphericalTransform::Ctor lagtrans_ ptr NULL"
);
}
}
//Ctor
//! Destructor
virtual
~
LaguerreSphericalTransform
()
{
if
(
sphere_
)
delete
sphere_
;
sphere
_
=
0
;
if
(
sphere_
)
delete
sphere_
;
sphere_
=
0
;
if
(
lagTrans_
)
delete
lagTrans_
;
lagTrans
_
=
0
;
}
//! Geometry helper
BaseGeometry
*
GetSphericalGeometry
()
const
{
return
sphere_
;}
//! Laguerre Transform helper
LaguerreTransform
*
GetLagTransform
()
const
{
return
lagTrans_
;}
//! Getters
int
GetOrder
()
{
return
N_
;
}
int
GetAlpha
()
{
return
alpha_
;}
//! Laguerre Transform helper
//! Synthesis
/*! \brief Coeffs -> Pixels with Input/Output using T floating representation
\input flmn: 3D complex spherical-laguerre coefficients
...
...
@@ -110,7 +122,7 @@ protected:
BaseGeometry
*
sphere_
;
//<! the 2D pixelization of the shells
LaguerreTransform
lagTrans_
;
//!< the Laguerre Transform
LaguerreTransform
*
lagTrans_
;
//!< the Laguerre Transform
int
Npix_
;
//!< Total number of 2D pixels
int
Nalm_
;
//!< Total number of Alm coefficients
...
...
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