LORENE
et_bin_nsbh_upmetr_der.C
1/*
2 * Methods Et_bin_nsbh::update_metric_der_comp
3 *
4 * (see file et_bin_nsbh.h for documentation).
5 *
6 */
7
8/*
9 * Copyright (c) 2003 Philippe Grandclement
10 * 2003 Keisuke Taniguchi
11 *
12 * This file is part of LORENE.
13 *
14 * LORENE is free software; you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License version 2
16 * as published by the Free Software Foundation.
17 *
18 * LORENE is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU General Public License for more details.
22 *
23 * You should have received a copy of the GNU General Public License
24 * along with LORENE; if not, write to the Free Software
25 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26 *
27 */
28
29char et_bin_nsbh_upmetr_der_C[] = "$Header: /cvsroot/Lorene/C++/Source/Etoile/et_bin_nsbh_upmetr_der.C,v 1.6 2014/10/13 08:52:56 j_novak Exp $" ;
30
31/*
32 * $Id: et_bin_nsbh_upmetr_der.C,v 1.6 2014/10/13 08:52:56 j_novak Exp $
33 * $Log: et_bin_nsbh_upmetr_der.C,v $
34 * Revision 1.6 2014/10/13 08:52:56 j_novak
35 * Lorene classes and functions now belong to the namespace Lorene.
36 *
37 * Revision 1.5 2007/04/24 20:14:45 f_limousin
38 * Implementation of Dirichlet and Neumann BC for the lapse
39 *
40 * Revision 1.4 2005/10/18 13:12:33 p_grandclement
41 * update of the mixted binary codes
42 *
43 * Revision 1.3 2005/08/29 15:10:17 p_grandclement
44 * Addition of things needed :
45 * 1) For BBH with different masses
46 * 2) Provisory files for the mixted binaries (Bh and NS) : THIS IS NOT
47 * WORKING YET !!!
48 *
49 * Revision 1.2 2004/06/07 11:08:31 k_taniguchi
50 * A minor change.
51 *
52 * Revision 1.1 2003/10/24 12:29:21 k_taniguchi
53 * Method of update metric for the BH companion
54 *
55 *
56 *
57 * $Header: /cvsroot/Lorene/C++/Source/Etoile/et_bin_nsbh_upmetr_der.C,v 1.6 2014/10/13 08:52:56 j_novak Exp $
58 *
59 */
60
61// Lorene headers
62#include "et_bin_nsbh.h"
63#include "bhole.h"
64
65 //---------------------------------------//
66 // Version with BH companion //
67 //---------------------------------------//
68
69
70namespace Lorene {
72
73 // Computation of Grad(N) ---> stored in d_n_comp
74 // -------------------------------------------------
75
76 Tenseur dncomp = ( comp.get_n_auto() ).gradient() ;
77
78 if ( dncomp.get_etat() == ETATZERO ) {
80 }
81 else{
82
83 // 1/ Division by r^2 of comp.d_n_auto in the ZEC
84 dncomp.dec2_dzpuis() ;
85
86 // 2/ Interpolation of the result
87
89 (d_n_comp.set(0)).import( dncomp(0) ) ; // d/dx sym.
90 (d_n_comp.set(1)).import( dncomp(1) ) ; // d/dy antisym.
91 (d_n_comp.set(2)).import( dncomp(2) ) ; // d/dz sym.
92
93 }
96 d_n_comp.set_triad( *(dncomp.get_triad()) ) ;
98
99
100 // Computation of Grad(Psi) ---> stored in d_confpsi_comp
101 // ------------------------------------------------------
102
103 Tenseur dpsicomp = ( comp.get_psi_auto() ).gradient() ;
104
105 if ( dpsicomp.get_etat() == ETATZERO ) {
107 }
108 else {
109 // 1/ Division by r^2 of comp.d_confpsi_auto in the ZEC
110 dpsicomp.dec2_dzpuis() ;
111
112 // 2/ Interpolation of the result
113
115
116 (d_confpsi_comp.set(0)).import(dpsicomp(0) ) ; // d/dx sym.
117 (d_confpsi_comp.set(1)).import(dpsicomp(1) ) ; // d/dy antisym.
118 (d_confpsi_comp.set(2)).import(dpsicomp(2) ) ; // d/dz sym.
119
120 }
121
124 d_confpsi_comp.set_triad( *(dpsicomp.get_triad()) ) ;
126
127 // The derived quantities are obsolete
128 // -----------------------------------
129 del_deriv() ;
130}
131}
Black hole.
Definition bhole.h:268
const Tenseur & get_n_auto() const
Returns the part of N generated by the hole.
Definition bhole.h:395
const Tenseur & get_psi_auto() const
Returns the part of generated by the hole.
Definition bhole.h:412
Tenseur d_confpsi_comp
Gradient of {\tt confpsi_comp} (Cartesian components with respect to {\tt ref_triad})
Tenseur d_n_comp
Gradient of {\tt n_comp} (Cartesian components with respect to {\tt ref_triad})
Definition et_bin_nsbh.h:98
void update_metric_der_comp(const Bhole &comp)
Computes the derivative of metric functions related to the companion black hole.
const Base_vect & ref_triad
Reference triad ("absolute frame"), with respect to which the components of all the member Tenseur 's...
Definition etoile.h:828
virtual void del_deriv() const
Deletes all the derived quantities.
Definition etoile_bin.C:447
Tensor handling *** DEPRECATED : use class Tensor instead ***.
Definition tenseur.h:301
const Base_vect * get_triad() const
Returns the vectorial basis (triad) on which the components are defined.
Definition tenseur.h:704
Cmp & set()
Read/write for a scalar (see also operator=(const Cmp&) ).
Definition tenseur.C:824
void set_etat_qcq()
Sets the logical state to ETATQCQ (ordinary state).
Definition tenseur.C:636
void dec2_dzpuis()
dzpuis -= 2 ;
Definition tenseur.C:1130
void set_std_base()
Set the standard spectal basis of decomposition for each component.
Definition tenseur.C:1170
void set_etat_zero()
Sets the logical state to ETATZERO (zero state).
Definition tenseur.C:645
void inc2_dzpuis()
dzpuis += 2 ;
Definition tenseur.C:1143
void change_triad(const Base_vect &new_triad)
Sets a new vectorial basis (triad) of decomposition and modifies the components accordingly.
Definition tenseur.C:668
void set_triad(const Base_vect &new_triad)
Assigns a new vectorial basis (triad) of decomposition.
Definition tenseur.C:674
int get_etat() const
Returns the logical state.
Definition tenseur.h:707
Lorene prototypes.
Definition app_hor.h:64