28char map_af_deriv_C[] =
"$Header: /cvsroot/Lorene/C++/Source/Map/map_af_deriv.C,v 1.13 2014/10/13 08:53:02 j_novak Exp $" ;
138 assert (ci.
get_etat() != ETATNONDEF) ;
139 assert (ci.
get_mp()->get_mg() == mg) ;
146 assert( ci.
get_etat() == ETATQCQ ) ;
151 int nz = mg->get_nzone() ;
157 resu = (ci.
va).dsdx() ;
159 if (mg->get_type_r(nzm1) == UNSURR) {
167 assert(mg->get_type_r(nzm1) == UNSURR) ;
176 tmp_ced.
set(nzm1) -= 2. * ci.
va(nzm1) ;
179 resu = tmp + tmp_ced ;
186 assert(mg->get_type_r(nzm1) == UNSURR) ;
190 tmp2.
base = (ci.
va).dsdx().base ;
195 tmp2.
set(nzm1) -= 4*ci.
va(nzm1) ;
199 resu = tmp + tmp2 /
xsr ;
205 cerr <<
"Map_af::dsdxi: unexpected value of input dzpuis !\n"
206 <<
" ci.get_dzpuis() = " << ci.
get_dzpuis() << endl ;
214 (resu.
va).set_base( (ci.
va).dsdx().get_base() ) ;
222 assert (uu.
get_etat() != ETATNONDEF) ;
223 assert (uu.
get_mp().get_mg() == mg) ;
231 assert( uu.
get_etat() == ETATQCQ ) ;
237 int nz = mg->get_nzone() ;
241 resu = uuva.
dsdx() * unity ;
243 if (mg->get_type_r(nzm1) == UNSURR) {
252 if (mg->get_type_r(nzm1) == UNSURR) {
259 tmp_ced.
set(nzm1) -= dzp * uuva(nzm1) ;
281 assert (ci.
get_etat() != ETATNONDEF) ;
282 assert (ci.
get_mp()->get_mg() == mg) ;
289 assert( ci.
get_etat() == ETATQCQ ) ;
294 int nz = mg->get_nzone() ;
300 resu = (ci.
va).dsdx() *
dxdr ;
302 if (mg->get_type_r(nzm1) == UNSURR) {
310 assert(mg->get_type_r(nzm1) == UNSURR) ;
319 tmp_ced.
set(nzm1) -= 2. * ci.
va(nzm1) ;
322 resu = tmp + tmp_ced ;
329 assert(mg->get_type_r(nzm1) == UNSURR) ;
333 tmp2.
base = (ci.
va).dsdx().base ;
338 tmp2.
set(nzm1) -= 4*ci.
va(nzm1) ;
342 resu = tmp + tmp2 /
xsr ;
348 cerr <<
"Map_af::dsdr: unexpected value of input dzpuis !\n"
349 <<
" ci.get_dzpuis() = " << ci.
get_dzpuis() << endl ;
357 (resu.
va).set_base( (ci.
va).dsdx().get_base() ) ;
365 assert (uu.
get_etat() != ETATNONDEF) ;
366 assert (uu.
get_mp().get_mg() == mg) ;
373 assert( uu.
get_etat() == ETATQCQ ) ;
379 int nz = mg->get_nzone() ;
385 if (mg->get_type_r(nzm1) == UNSURR) {
394 if (mg->get_type_r(nzm1) == UNSURR) {
401 tmp_ced.
set(nzm1) -= dzp * uuva(nzm1) ;
419 assert (uu.
get_etat() != ETATNONDEF) ;
420 assert (uu.
get_mp().get_mg() == mg) ;
427 assert( uu.
get_etat() == ETATQCQ ) ;
433 int nz = mg->get_nzone() ;
439 if (mg->get_type_r(nzm1) == UNSURR) {
445 assert(mg->get_type_r(nzm1) == UNSURR) ;
456 tmp_ced.
set(nzm1) -= dzp * uuva(nzm1) ;
477 assert (ci.
get_etat() != ETATNONDEF) ;
478 assert (ci.
get_mp()->get_mg() == mg) ;
485 assert( ci.
get_etat() == ETATQCQ ) ;
493 int nz = mg->get_nzone() ;
508 if (mg->get_type_r(nz-1) == UNSURR) {
516 assert(mg->get_type_r(nzm1) == UNSURR) ;
529 resu = tmp + tmp_ced ;
536 assert(mg->get_type_r(nzm1) == UNSURR) ;
549 resu = tmp + tmp_ced /
xsr ;
557 cerr <<
"Map_af::srdsdt: unexpected value of input dzpuis !\n"
558 <<
" ci.get_dzpuis() = " << ci.
get_dzpuis() << endl ;
570 assert (uu.
get_etat() != ETATNONDEF) ;
571 assert (uu.
get_mp().get_mg() == mg) ;
578 assert( uu.
get_etat() == ETATQCQ ) ;
585 int nz = mg->get_nzone() ;
598 if (mg->get_type_r(nz-1) == UNSURR) {
605 assert(mg->get_type_r(nzm1) == UNSURR) ;
619 resu = tmp + tmp_ced ;
635 assert (ci.
get_etat() != ETATNONDEF) ;
636 assert (ci.
get_mp()->get_mg() == mg) ;
643 assert( ci.
get_etat() == ETATQCQ ) ;
652 int nz = mg->get_nzone() ;
667 if (mg->get_type_r(nz-1) == UNSURR) {
675 assert(mg->get_type_r(nzm1) == UNSURR) ;
688 resu = tmp + tmp_ced ;
695 assert(mg->get_type_r(nzm1) == UNSURR) ;
708 resu = tmp + tmp_ced /
xsr ;
716 cerr <<
"Map_af::srstdsdp: unexpected value of input dzpuis !\n"
717 <<
" ci.get_dzpuis() = " << ci.
get_dzpuis() << endl ;
731 assert (uu.
get_etat() != ETATNONDEF) ;
732 assert (uu.
get_mp().get_mg() == mg) ;
739 assert( uu.
get_etat() == ETATQCQ ) ;
748 int nz = mg->get_nzone() ;
762 if (mg->get_type_r(nz-1) == UNSURR) {
769 assert(mg->get_type_r(nzm1) == UNSURR) ;
784 resu = tmp + tmp_ced ;
799 assert (ci.
get_etat() != ETATNONDEF) ;
800 assert (ci.
get_mp().get_mg() == mg) ;
807 assert( ci.
get_etat() == ETATQCQ ) ;
825 assert (ci.
get_etat() != ETATNONDEF) ;
826 assert (ci.
get_mp().get_mg() == mg) ;
833 assert( ci.
get_etat() == ETATQCQ ) ;
Bases of the spectral expansions.
Component of a tensorial field *** DEPRECATED : use class Scalar instead ***.
int get_etat() const
Returns the logical state.
Valeur va
The numerical value of the Cmp.
int get_dzpuis() const
Returns dzpuis.
void set_etat_zero()
Sets the logical state to ETATZERO (zero).
void set_dzpuis(int)
Set a value to dzpuis.
const Map * get_mp() const
Returns the mapping.
virtual void srstdsdp(const Cmp &ci, Cmp &resu) const
Computes of a Cmp.
virtual void dsdradial(const Scalar &, Scalar &) const
Computes of a Scalar.
virtual void dsdr(const Cmp &ci, Cmp &resu) const
Computes of a Cmp.
virtual void dsdt(const Scalar &uu, Scalar &resu) const
Computes of a Scalar.
virtual void stdsdp(const Scalar &uu, Scalar &resu) const
Computes of a Scalar.
virtual void srdsdt(const Cmp &ci, Cmp &resu) const
Computes of a Cmp.
virtual void dsdxi(const Cmp &ci, Cmp &resu) const
Computes of a Cmp.
Coord xsr
in the nucleus; \ 1/R in the non-compactified shells; \ in the compactified outer domain.
Coord dxdr
in the nucleus and in the non-compactified shells; \ in the compactified outer domain.
Tensor field of valence 0 (or component of a tensorial field).
int get_dzpuis() const
Returns dzpuis.
virtual void set_etat_zero()
Sets the logical state to ETATZERO (zero).
Valeur & set_spectral_va()
Returns va (read/write version).
const Valeur & get_spectral_va() const
Returns va (read only version).
int get_etat() const
Returns the logical state ETATNONDEF (undefined), ETATZERO (null) or ETATQCQ (ordinary).
void set_dzpuis(int)
Modifies the dzpuis flag.
void set_spectral_base(const Base_val &)
Sets the spectral bases of the Valeur va.
Values and coefficients of a (real-value) function.
const Valeur & dsdp() const
Returns of *this.
const Valeur & sx() const
Returns (r -sampling = RARE ) \ Id (r sampling = FIN ) \ (r -sampling = UNSURR ).
void mult_xm1_zec()
Applies the following operator to *this : \ Id (r sampling = RARE, FIN ) \ (r -sampling = UNSURR ).
const Base_val & get_base() const
Return the bases for spectral expansions (member base ).
const Valeur & stdsdp() const
Returns of *this.
void set_base(const Base_val &)
Sets the bases for spectral expansions (member base ).
const Valeur & dsdt() const
Returns of *this.
void annule(int l)
Sets the Valeur to zero in a given domain.
Tbl & set(int l)
Read/write of the value in a given domain (configuration space).
const Valeur & dsdx() const
Returns of *this.
const Valeur & ssint() const
Returns of *this.
void coef() const
Computes the coeffcients of *this.
Base_val base
Bases on which the spectral expansion is performed.
const Map & get_mp() const
Returns the mapping.
void annule_domain(int l)
Sets the Tensor to zero in a given domain.
Coord r
r coordinate centered on the grid