30 #include <gsl/gsl_sf_bessel.h> 33 #include "ope_elementary.h" 39 Tbl _solh_helmholtz_minus_pseudo_1d_pas_prevu (
int,
int,
40 double,
double,
double) {
42 cout <<
" Solution homogene pas prevue ..... : "<< endl ;
53 Tbl _solh_helmholtz_minus_pseudo_1d_r_chebu (
int n,
int l,
55 double alpha,
double) {
60 double* coloc =
new double[n] ;
62 int * deg =
new int[3] ;
67 for (
int i=0 ; i<n-1 ; i++) {
68 double air = 1./(alpha*(-1-
cos(M_PI*i/(n-1)))) ;
69 if ((l !=0) && (l!=1))
70 coloc[i] = gsl_sf_bessel_kl_scaled (l-1, masse*air) /
exp(masse*air) * air;
72 coloc[i] =
exp(-masse*air) ;
76 cfrcheb(deg, deg, coloc, deg, coloc) ;
77 for (
int i=0 ; i<n ;i++)
78 res.set(i) = coloc[i] ;
90 static Tbl (*solh_helmholtz_minus_pseudo_1d[
MAX_BASE]) (int, int, double, double, double) ;
97 solh_helmholtz_minus_pseudo_1d[i] = _solh_helmholtz_minus_pseudo_1d_pas_prevu ;
100 solh_helmholtz_minus_pseudo_1d[
R_CHEBU >>
TRA_R] = _solh_helmholtz_minus_pseudo_1d_r_chebu ;
109 val_lim *=
sqrt (
double(2)) ;
120 for (
int i=0 ; i<
nr ; i++)
121 auxi.
set(i) = res(0,i) ;
124 val_one *=
sqrt (
double(2)) ;
131 for (
int i=0 ; i<
nr ; i++)
132 auxi.
set(i) = res(1,i) ;
135 val_two *=
sqrt(
double(2)) ;
double alpha
Parameter of the associated mapping.
Cmp exp(const Cmp &)
Exponential.
double s_one_minus
Value of the first homogeneous solution at the inner boundary.
Cmp sqrt(const Cmp &)
Square root.
double ds_two_minus
Value of the derivative of the second homogeneous solution at the inner boundary. ...
double beta
Parameter of the associated mapping.
double & set(int i)
Read/write of a particular element (index i) (1D case)
double ds_two_plus
Value of the derivative of the second homogeneous solution at the outer boundary. ...
Cmp cos(const Cmp &)
Cosine.
int base_r
Radial basis of decomposition.
void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
#define TRA_R
Translation en R, used for a bitwise shift (in hex)
double ds_one_plus
Value of the derivative of the first homogeneous solution at the outer boundary.
int get_ndim() const
Gives the number of dimensions (ie dim.ndim)
double s_two_minus
Value of the second homogeneous solution at the inner boundary.
double masse
The mass term.
double s_one_plus
Value of the first homogeneous solution at the outer boundary.
int l_quant
quantum number
virtual Tbl get_solh() const
Computes the homogeneous solutions(s).
int nr
Number of radial points.
double ds_one_minus
Value of the derivative of the first homogeneous solution at the inner boundary.
#define R_CHEBU
base de Chebychev ordinaire (fin), dev. en 1/r
double s_two_plus
Value of the second homogeneous solution at the outer boundary.
#define MAX_BASE
Nombre max. de bases differentes.