LORENE
cmp_r_manip.C
1/*
2 * Member functions of the class Cmp for various r manipulations
3 */
4
5/*
6 * Copyright (c) 1999-2001 Eric Gourgoulhon
7 * Copyright (c) 1999-2001 Philippe Grandclement
8 * Copyright (c) 2001 Jerome Novak
9 *
10 * This file is part of LORENE.
11 *
12 * LORENE is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
16 *
17 * LORENE is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
21 *
22 * You should have received a copy of the GNU General Public License
23 * along with LORENE; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 *
26 */
27
28
29char cmp_r_manip_C[] = "$Header: /cvsroot/Lorene/C++/Source/Cmp/cmp_r_manip.C,v 1.4 2014/10/13 08:52:48 j_novak Exp $" ;
30
31/*
32 * $Id: cmp_r_manip.C,v 1.4 2014/10/13 08:52:48 j_novak Exp $
33 * $Log: cmp_r_manip.C,v $
34 * Revision 1.4 2014/10/13 08:52:48 j_novak
35 * Lorene classes and functions now belong to the namespace Lorene.
36 *
37 * Revision 1.3 2012/08/12 17:35:36 p_cerda
38 * Magnetstar: adding new member to class Cmp
39 *
40 * Revision 1.2 2004/10/11 15:09:01 j_novak
41 * The radial manipulation functions take Scalar as arguments, instead of Cmp.
42 * Added a conversion operator from Scalar to Cmp.
43 * The Cmp radial manipulation function make conversion to Scalar, call to the
44 * Map_radial version with a Scalar argument and back.
45 *
46 * Revision 1.1.1.1 2001/11/20 15:19:27 e_gourgoulhon
47 * LORENE
48 *
49 * Revision 1.5 2001/10/29 15:37:06 novak
50 * Ajout de Cmp::div_r()
51 *
52 * Revision 1.4 2000/08/31 13:04:46 eric
53 * Ajout des fonctions mult_rsint et div_rsint.
54 *
55 * Revision 1.3 2000/05/22 14:39:52 phil
56 * ajout de inc_dzpuis et dec_dzpuis
57 *
58 * Revision 1.2 1999/12/10 16:33:48 eric
59 * Appel de del_deriv().
60 *
61 * Revision 1.1 1999/11/30 14:22:54 eric
62 * Initial revision
63 *
64 *
65 * $Header: /cvsroot/Lorene/C++/Source/Cmp/cmp_r_manip.C,v 1.4 2014/10/13 08:52:48 j_novak Exp $
66 *
67 */
68
69#include "cmp.h"
70#include "scalar.h"
71
72
73 //---------------------------//
74 // div_r //
75 //---------------------------//
76
77namespace Lorene {
78void Cmp::div_r() {
79
80 Scalar resu(*this) ;
81 mp->div_r(resu) ; // Call to the Scalar version
82 operator=(Cmp(resu)) ;
83
84 del_deriv() ; // Delete the derived members
85
86}
87 //---------------------------//
88 // mult_r //
89 //---------------------------//
90
92
93 mp->mult_r(*this) ; // Call of the appropriate routine of the mapping
94
95 del_deriv() ; // Delete the derived members
96
97}
98
99 //---------------------------//
100 // mult_r_zec //
101 //---------------------------//
102
104
105 Scalar resu(*this) ;
106 mp->mult_r_zec(resu) ; // Call of the appropriate routine of the mapping
107 operator=(resu) ;
108 del_deriv() ; // Delete the derived members
109
110}
111
112 //---------------------------//
113 // mult_rsint //
114 //---------------------------//
115
117
118 Scalar resu(*this) ;
119 mp->mult_rsint(resu) ; // Call of the appropriate routine of the mapping
120 operator=(resu) ;
121 del_deriv() ; // Delete the derived members
122
123}
124 //---------------------------//
125 // mult_rcost //
126 //---------------------------//
127
129
130 Scalar resu(*this) ;
131 mp->mult_cost(resu) ; // Call of the appropriate routine of the mapping
132 operator=(resu) ;
133 del_deriv() ; // Delete the derived members
134
135}
136
137 //---------------------------//
138 // div_rsint //
139 //---------------------------//
140
141void Cmp::div_rsint() {
142
143 Scalar resu(*this) ;
144 mp->div_rsint(resu) ; // Call of the appropriate routine of the mapping
145 operator=(resu) ;
146 del_deriv() ; // Delete the derived members
147
148}
149
150 //---------------------------//
151 // dec_dzpuis //
152 //---------------------------//
153
155
156 Scalar resu(*this) ;
157 mp->dec_dzpuis(resu) ; // Call of the appropriate routine of the mapping
158 operator=(resu) ;
159
160}
161
162 //---------------------------//
163 // inc_dzpuis //
164 //---------------------------//
165
167
168 Scalar resu(*this) ;
169 mp->inc_dzpuis(resu) ; // Call of the appropriate routine of the mapping
170 operator=(resu) ;
171
172}
173
174
175
176 //---------------------------//
177 // dec2_dzpuis //
178 //---------------------------//
179
181
182 Scalar resu(*this) ;
183 mp->dec2_dzpuis(resu) ; // Call of the appropriate routine of the mapping
184 operator=(resu) ;
185
186}
187
188 //---------------------------//
189 // inc2_dzpuis //
190 //---------------------------//
191
193
194 Scalar resu(*this) ;
195 mp->inc2_dzpuis(resu) ; // Call of the appropriate routine of the mapping
196 operator=(resu) ;
197
198}
199
200
201}
Component of a tensorial field *** DEPRECATED : use class Scalar instead ***.
Definition cmp.h:446
const Map * mp
Reference mapping.
Definition cmp.h:451
void mult_r_zec()
Multiplication by r in the external compactified domain (ZEC)
void mult_rsint()
Multiplication by .
void div_r()
Division by r everywhere.
Definition cmp_r_manip.C:78
void dec_dzpuis()
Decreases by 1 the value of dzpuis and changes accordingly the values of the Cmp in the external comp...
void operator=(const Cmp &a)
Assignment to another Cmp defined on the same mapping.
Definition cmp.C:398
void mult_r()
Multiplication by r everywhere.
Definition cmp_r_manip.C:91
void inc2_dzpuis()
Increases by 2 the value of dzpuis and changes accordingly the values of the Cmp in the external comp...
void del_deriv()
Logical destructor of the derivatives.
Definition cmp.C:265
void dec2_dzpuis()
Decreases by 2 the value of dzpuis and changes accordingly the values of the Cmp in the external comp...
void mult_cost()
Multiplication by \f\cos\theta\f$.
void inc_dzpuis()
Increases by the value of dzpuis and changes accordingly the values of the Cmp in the external compac...
virtual void dec2_dzpuis(Scalar &) const =0
Decreases by 2 the value of dzpuis of a Scalar and changes accordingly its values in the compacti...
virtual void mult_r(Scalar &uu) const =0
Multiplication by r of a Scalar , the dzpuis of uu is not changed.
virtual void inc_dzpuis(Scalar &) const =0
Increases by 1 the value of dzpuis of a Scalar and changes accordingly its values in the compacti...
virtual void mult_cost(Scalar &) const =0
Multiplication by of a Scalar.
virtual void mult_rsint(Scalar &) const =0
Multiplication by of a Scalar.
virtual void dec_dzpuis(Scalar &) const =0
Decreases by 1 the value of dzpuis of a Scalar and changes accordingly its values in the compacti...
virtual void div_rsint(Scalar &) const =0
Division by of a Scalar.
virtual void div_r(Scalar &) const =0
Division by r of a Scalar.
virtual void mult_r_zec(Scalar &) const =0
Multiplication by r (in the compactified external domain only) of a Scalar.
virtual void inc2_dzpuis(Scalar &) const =0
Increases by 2 the value of dzpuis of a Scalar and changes accordingly its values in the compacti...
Tensor field of valence 0 (or component of a tensorial field).
Definition scalar.h:387
Lorene prototypes.
Definition app_hor.h:64