bin_bhns.h

00001 /*
00002  *  Definition of Lorene class Bin_bhns
00003  *
00004  */
00005 
00006 /*
00007  *   Copyright (c) 2005-2007 Keisuke Taniguchi
00008  *
00009  *   This file is part of LORENE.
00010  *
00011  *   LORENE is free software; you can redistribute it and/or modify
00012  *   it under the terms of the GNU General Public License version 2
00013  *   as published by the Free Software Foundation.
00014  *
00015  *   LORENE is distributed in the hope that it will be useful,
00016  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
00017  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00018  *   GNU General Public License for more details.
00019  *
00020  *   You should have received a copy of the GNU General Public License
00021  *   along with LORENE; if not, write to the Free Software
00022  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00023  *
00024  */
00025 
00026 #ifndef __BIN_BHNS_H_ 
00027 #define __BIN_BHNS_H_ 
00028 
00029 /*
00030  * $Id: bin_bhns.h,v 1.2 2008/05/15 18:50:06 k_taniguchi Exp $
00031  * $Log: bin_bhns.h,v $
00032  * Revision 1.2  2008/05/15 18:50:06  k_taniguchi
00033  * Addition of new global quantities.
00034  *
00035  * Revision 1.1  2007/06/22 01:03:50  k_taniguchi
00036  * *** empty log message ***
00037  *
00038  *
00039  * $Header: /cvsroot/Lorene/C++/Include/bin_bhns.h,v 1.2 2008/05/15 18:50:06 k_taniguchi Exp $
00040  *
00041  */
00042 
00043 // External classes which appear in the declaration of class Bin_bhns:
00044 class Hole_bhns ;
00045 class Star_bhns ;
00046 
00047 // Lorene headers
00048 #include "hole_bhns.h"
00049 #include "star_bhns.h"
00050 
00051 
00058 class Bin_bhns {
00059 
00060     // Data : 
00061     // -----
00062     protected:
00064         const Base_vect_cart ref_triad ;
00065 
00067         Hole_bhns hole ;
00068 
00070     Star_bhns star ;
00071 
00075     double omega ;
00076 
00078     double separ ;
00079 
00081     double x_rot ;
00082 
00084     double y_rot ;
00085 
00086     // Derived data : 
00087     // ------------
00088     protected:
00092     mutable double* p_mass_adm_bhns_surf ;
00093 
00097     mutable double* p_mass_adm_bhns_vol ;
00098 
00102     mutable double* p_mass_kom_bhns_surf ;
00103 
00107     mutable double* p_mass_kom_bhns_vol ;
00108 
00110     mutable Tbl* p_line_mom_bhns ;
00111 
00113     mutable Tbl* p_angu_mom_bhns ;
00114 
00118     mutable double* p_virial_bhns_surf ;
00119 
00123     mutable double* p_virial_bhns_vol ;
00124 
00126     mutable double* p_xa_barycenter ;
00127 
00129     mutable double* p_ya_barycenter ;
00130 
00132     mutable double* p_omega_two_points ;
00133 
00135     //  mutable double* p_ham_constr_bhns ;
00136 
00138     //  mutable Tbl* p_mom_constr_bhns ;
00139 
00140 
00141     // Constructors - Destructor
00142     // -------------------------
00143     public:
00164     Bin_bhns(Map& mp_bh, Map& mp_ns, int nzet, const Eos& eos,
00165          bool irrot_ns, bool kerrschild,
00166          bool bc_lapse_nd, bool bc_lapse_fs, bool irrot_bh,
00167          double mass_bh) ;
00168 
00169     Bin_bhns(const Bin_bhns& ) ;        
00170 
00172     Bin_bhns(Map& mp_bh, Map& mp_ns, const Eos& eos, FILE* fich) ;
00173 
00174     virtual ~Bin_bhns() ;           
00175  
00176 
00177     // Memory management
00178     // -----------------
00179     protected:
00181     void del_deriv() const ; 
00182     
00184     void set_der_0x0() const ; 
00185 
00186 
00187     // Mutators / assignment
00188     // ---------------------
00189     public:
00191     void operator=(const Bin_bhns&) ;
00192 
00194     Hole_bhns& set_bh()
00195         { del_deriv() ;
00196           return hole ; } ;
00197 
00199     Star_bhns& set_ns()
00200         { del_deriv() ;
00201           return star ; } ;
00202 
00204     double& set_omega() { return omega ; } ;
00205 
00207     double& set_separ() { return separ ; } ;
00208 
00210     double& set_x_rot() {return x_rot; } ;
00211 
00213     double& set_y_rot() {return y_rot; } ;
00214 
00215     
00216     // Accessors
00217     // ---------
00218     public:
00220     const Hole_bhns& get_bh() const { return hole ; } ;
00221 
00223     const Star_bhns& get_ns() const { return star ; } ;
00224 
00226     double get_omega() const { return omega ; } ;
00227 
00231     double get_separ() const { return separ ; } ;
00232 
00236     double get_x_rot() const {return x_rot; } ;
00237 
00241     double get_y_rot() const {return y_rot; } ;
00242 
00243 
00244     // Outputs
00245     // -------
00246     public:
00247     virtual void sauve(FILE *) const ;      
00248     
00250     friend ostream& operator<<(ostream& , const Bin_bhns& ) ;   
00251 
00253     void display_poly(ostream& ) const ;
00254 
00255     private:
00257     ostream& operator>>(ostream& ) const ;
00258 
00259     // Computational routines
00260     // ----------------------
00261     public:
00262 
00264     double mass_adm_bhns_surf() const ;
00265 
00266     double mass_adm_bhns_vol() const ;
00267 
00269     double mass_kom_bhns_surf() const ;
00270 
00271     double mass_kom_bhns_vol() const ;
00272 
00280     const Tbl& line_mom_bhns() const ;
00281 
00289     const Tbl& angu_mom_bhns() const ;
00290 
00294     double virial_bhns_surf() const ;
00295 
00299     double virial_bhns_vol() const ;
00300 
00302     double xa_barycenter() const ;
00303 
00305     double ya_barycenter() const ;
00306 
00308     double omega_two_points() const ;
00309 
00312     //  double ham_constr() const ;
00313 
00316     //  const Tbl& mom_constr() const ;
00317 
00336     void orbit_omega(double fact_omeg_min, double fact_omeg_max) ;
00337 
00344     void rotation_axis_x(double rot_exp_x) ;
00345 
00354     void rotation_axis_y(double thres_rot, double rot_exp_y, double fact) ;
00355 
00364     void shift_analytic(double reduce_shift_bh, double reduce_shift_ns) ;
00365 
00366 
00367 };
00368 ostream& operator<<(ostream& , const Bin_bhns& ) ;
00369 
00370 #endif

Generated on Tue Feb 7 01:35:14 2012 for LORENE by  doxygen 1.4.6