21char param_elliptic_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Param_elliptic/param_elliptic.C,v 1.21 2014/10/13 08:53:37 j_novak Exp $" ;
110#include "ope_elementary.h"
111#include "param_elliptic.h"
128 cout <<
"Unknown mapping in Param_elliptic" << endl ;
134double Param_elliptic::get_alpha(
int l)
const {
144 cout <<
"Unknown mapping in Param_elliptic" << endl ;
150double Param_elliptic::get_beta(
int l)
const {
160 cout <<
"Unknown mapping in Param_elliptic" << endl ;
166int Param_elliptic::get_type(
int l)
const {
176 cout <<
"Unknown mapping in Param_elliptic" << endl ;
184 done_F (so.get_mp().get_mg()->get_nzone(),
185 so.get_mp().get_mg()->get_np(0) + 1,
186 so.get_mp().get_mg()->get_nt(0)),
187 done_G (so.get_mp().get_mg()->get_nzone()),
188 val_F_plus (so.get_mp().get_mg()->get_nzone(),
189 so.get_mp().get_mg()->get_np(0) + 1,
190 so.get_mp().get_mg()->get_nt(0)),
191 val_F_minus (so.get_mp().get_mg()->get_nzone(),
192 so.get_mp().get_mg()->get_np(0) + 1,
193 so.get_mp().get_mg()->get_nt(0)),
194 val_dF_plus (so.get_mp().get_mg()->get_nzone(),
195 so.get_mp().get_mg()->get_np(0) + 1,
196 so.get_mp().get_mg()->get_nt(0)),
197 val_dF_minus (so.get_mp().get_mg()->get_nzone(),
198 so.get_mp().get_mg()->get_np(0) + 1,
199 so.get_mp().get_mg()->get_nt(0)),
200 val_G_plus (so.get_mp().get_mg()->get_nzone()),
201 val_G_minus (so.get_mp().get_mg()->get_nzone()),
202 val_dG_plus (so.get_mp().get_mg()->get_nzone()),
203 val_dG_minus (so.get_mp().get_mg()->get_nzone())
221 if ((map_affine == 0x0) && (map_log == 0x0)) {
222 cout <<
"Param_elliptic not yet defined on this type of mapping" << endl ;
227 if (map_affine != 0x0) {
232 if (map_log != 0x0) {
239 for (
int l=0 ; l<nz ; l++)
240 nbr += (
get_mp().get_mg()->get_np(l)+1)*
245 for (
int l=0 ; l<nbr ; l++)
249 int base_r, m_quant, l_quant ;
252 for (
int l=0 ; l<nz ; l++) {
260 (l, k, j, m_quant, l_quant, base_r) ;
266 get_beta(l), l_quant, dzpuis) ;
272 get_beta(l), l_quant, dzpuis) ;
279 cout <<
"Unknown mapping in Param_elliptic::Param_elliptic"
316 for (
int i=0 ; i<nbr ; i++)
333 for (
int k=0 ; k<np+1 ; k++)
334 for (
int j=0 ; j<nt ; j++) {
351 int m_quant, base_r_1d, l_quant ;
357 for (
int l=0 ; l<nz ; l++) {
367 (l, k, j, m_quant, l_quant, base_r_1d) ;
369 get_beta(l) , masse) ;
379 cout <<
"Operator not define with LOG mapping..." << endl ;
383 for (
int l=0 ; l<nz ; l++) {
393 (l, k, j, m_quant, l_quant, base_r_1d) ;
395 get_alpha(l), get_beta(l), masse) ;
405 cout <<
"Unkown mapping in set_helmhotz_minus" << endl ;
419 int m_quant, base_r_1d, l_quant ;
425 for (
int l=0 ; l<nz ; l++) {
438 (l, k, j, m_quant, l_quant, base_r_1d) ;
440 get_beta(l) , masse) ;
451 cout <<
"Operator not define with LOG mapping..." << endl ;
455 for (
int l=0 ; l<nz ; l++) {
468 (l, k, j, m_quant, l_quant, base_r_1d) ;
470 get_alpha(l), get_beta(l), masse) ;
481 cout <<
"Unkown mapping in set_helmhotz_minus" << endl ;
490 cout <<
"set_poisson_vect_r only defined for an affine mapping..." << endl ;
500 for (
int l=0 ; l<nz ; l++) {
506 if ((
operateurs[conte] != 0x0) && (l==zone)) {
510 assert (op_pois !=0x0) ;
516 if ((!only_l_zero)||(lq_old == 0)) {
518 get_beta(l), lq_old, dzp) ;
538 for (
int l=0 ; l<nz ; l++) {
543 if ((
operateurs[conte] != 0x0) && (l==zone)) {
546 assert (op_pois !=0x0) ;
563 cout <<
"set_poisson_tens_rr only defined for an affine mapping..."
574 for (
int l=0 ; l<nz ; l++) {
580 if ((
operateurs[conte] != 0x0) && (l==zone)) {
584 assert (op_pois !=0x0) ;
591 (nr, old_base,get_alpha(l), get_beta(l), lq_old, dzp) ;
613 for (
int l=0 ; l<nz ; l++) {
619 if ((
operateurs[conte] != 0x0) && (l==zone)) {
626 get_beta(l), a, b, c) ;
636 cout <<
"Operator not define with LOG mapping..." << endl ;
640 for (
int l=0 ; l<nz ; l++) {
646 if ((
operateurs[conte] != 0x0) && (l==zone)) {
653 get_beta(l), a, b, c) ;
663 cout <<
"Unkown mapping in set_sec_order_r2" << endl ;
672 cout <<
"set_sec_order only defined for a log mapping" << endl ;
682 for (
int l=0 ; l<nz ; l++) {
688 if ((
operateurs[conte] != 0x0) && (l==zone)) {
696 get_beta(l), a, b, c) ;
713 int m_quant, base_r_1d, l_quant ;
720 for (
int l=0 ; l<nz ; l++) {
721 int dz = (l==nz-1) ? dzpuis : 0 ;
730 (l, k, j, m_quant, l_quant, base_r_1d) ;
732 get_beta(l), l_quant, dz) ;
742 cout <<
"Operator not define with LOG mapping..." << endl ;
746 for (
int l=0 ; l<nz ; l++) {
747 int dz = (l==nz-1) ? dzpuis : 0 ;
756 (l, k, j, m_quant, l_quant, base_r_1d) ;
758 get_alpha(l), get_beta(l), l_quant, dz) ;
768 cout <<
"Unkown mapping in set_ope_vorton" << endl ;
776 assert (so.
get_etat() != ETATNONDEF) ;
785 assert (so.
get_etat() != ETATNONDEF) ;
Bases of the spectral expansions.
void give_quant_numbers(int, int, int, int &, int &, int &) const
Computes the various quantum numbers and 1d radial base.
void annule_hard()
Sets the Itbl to zero in a hard way.
const double * get_beta() const
Returns the pointer on the array beta.
const double * get_alpha() const
Returns the pointer on the array alpha.
Logarithmic radial mapping.
double get_beta(int l) const
Returns in the domain l.
double get_alpha(int l) const
Returns in the domain l.
int get_type(int l) const
Returns the type of description in the domain l.
Base class for pure radial mappings.
const Mg3d * get_mg() const
Gives the Mg3d on which the mapping is defined.
int get_np(int l) const
Returns the number of points in the azimuthal direction ( ) in domain no. l.
int get_nt(int l) const
Returns the number of points in the co-latitude direction ( ) in domain no. l.
int get_nzone() const
Returns the number of domains.
int get_nr(int l) const
Returns the number of points in the radial direction ( ) in domain no. l.
int get_type_r(int l) const
Returns the type of sampling in the radial direction in domain no.
Basic class for elementary elliptic operators.
int get_base_r() const
Returns base_r}.
virtual void inc_l_quant()=0
Increases the quatum number l by one unit.
Class for the Helmholtz operator ( ).
Class for the Helmholtz operator (m > 0).
Class for the operator of the rr component of the divergence-free tensor Poisson equation.
Class for the operator of the r component of the vector Poisson equation.
Class for the operator of the Poisson equation (i.e.
int get_dzpuis()
Returns the associated dzpuis, if in the compactified domain.
int get_lquant()
Returns the quantum number l.
virtual void dec_l_quant()
Decreases the quatum number l by one unit.
virtual void inc_l_quant()
Increases the quatum number l by one unit.
Class for operator of the type .
Class for operator of the type .
Class for the operator appearing for the vortons.
Scalar var_G
Multiplicative variable change that must be sphericaly symetric !
Itbl done_F
Stores what has been computed for F.
Tbl val_dG_minus
Values of the derivative of G at the inner boundaries of the various domains.
void set_sec_order_r2(int zone, double a, double b, double c)
Set the operator to in one domain (only in the shells).
void inc_l_quant(int zone)
Increases the quantum number l in the domain zone .
void set_helmholtz_minus(int zone, double mas, Scalar &so)
Set the operator to in one domain (not in the nucleus).
Tbl val_dF_minus
Values of the derivative of F at the inner boundaries of the various domains.
void set_poisson_vect_eta(int zone)
Sets the operator to be a regular elliptic operator to solve for the component of the vector Poisson...
const Map_log * mp_log
The mapping if log type.
Param_elliptic(const Scalar &)
Standard constructor from a Scalar.
const Map_radial & get_mp() const
Returns the mapping.
Tbl val_F_minus
Values of F at the inner boundaries of the various domains.
Tbl val_F_plus
Values of F at the outer boundaries of the various domains.
~Param_elliptic()
Destructor.
void set_sec_order(int zone, double a, double b, double c)
Set the operator to in one domain (only in the shells).
Tbl val_G_minus
Values of G at the inner boundaries of the various domains.
Tbl val_dG_plus
Values of the derivative of G at the outer boundaries of the various domains.
Ope_elementary ** operateurs
Array on the elementary operators.
void set_poisson_vect_r(int zone, bool only_l_zero=false)
Sets the operator to in all domains, for ; and to in all domains otherwise.
const Map_af * mp_af
The mapping, if affine.
void set_poisson_tens_rr(int zone)
Sets the operator to in all domains, for only.
void set_variable_F(const Scalar &)
Changes the variable function F.
void set_helmholtz_plus(int zone, double mas, Scalar &so)
Set the operator to in one domain (only in the shells).
void set_variable_G(const Scalar &)
Changes the variable function G.
int type_map
Type of mapping either MAP_AFF or MAP_LOG.
Tbl val_dF_plus
Values of the derivative of F at the outer boundaries of the various domains.
Tbl val_G_plus
Values of G at the outer boundaries of the various domains.
void set_ope_vorton(int zone, Scalar &so)
Set the operator to in one domain (not implemented in the nucleus).
Itbl done_G
Stores what has been computed for G.
Scalar var_F
Additive variable change function.
Tensor field of valence 0 (or component of a tensorial field).
int get_dzpuis() const
Returns dzpuis.
virtual void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
bool dz_nonzero() const
Returns true if the last domain is compactified and *this is not zero in this domain.
virtual void std_spectral_base()
Sets the spectral bases of the Valeur va to the standard ones for a scalar field.
Valeur & set_spectral_va()
Returns va (read/write version)
const Valeur & get_spectral_va() const
Returns va (read only version)
void annule_hard()
Sets the Scalar to zero in a hard way.
int get_etat() const
Returns the logical state ETATNONDEF (undefined), ETATZERO (null) or ETATQCQ (ordinary).
void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
const Base_val & get_base() const
Return the bases for spectral expansions (member base )
void set_base(const Base_val &)
Sets the bases for spectral expansions (member base )
void ylm()
Computes the coefficients of *this.
void coef() const
Computes the coeffcients of *this.
Base_val base
Bases on which the spectral expansion is performed.
#define R_CHEBI
base de Cheb. impaire (rare) seulement
const Map & get_mp() const
Returns the mapping.