star_rot.h

00001 /*
00002  *  Definition of Lorene class Star_rot
00003  *               
00004  */
00005 
00006 /*
00007  *   Copyright (c) 2010 Eric Gourgoulhon 
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 as published by
00013  *   the Free Software Foundation; either version 2 of the License, or
00014  *   (at your option) any later version.
00015  *
00016  *   LORENE is distributed in the hope that it will be useful,
00017  *   but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00019  *   GNU General Public License for more details.
00020  *
00021  *   You should have received a copy of the GNU General Public License
00022  *   along with LORENE; if not, write to the Free Software
00023  *   Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00024  *
00025  */
00026 
00027 
00028 #ifndef __STAR_ROT_H_ 
00029 #define __STAR_ROT_H_ 
00030 
00031 /*
00032  * $Id: star_rot.h,v 1.4 2010/02/08 10:56:30 j_novak Exp $
00033  * $Log: star_rot.h,v $
00034  * Revision 1.4  2010/02/08 10:56:30  j_novak
00035  * Added a few things missing for the reading from resulting file.
00036  *
00037  * Revision 1.3  2010/02/02 13:35:00  e_gourgoulhon
00038  * Remove the "under construction" mark.
00039  *
00040  * Revision 1.2  2010/01/25 18:14:05  e_gourgoulhon
00041  * Added member unsurc2
00042  * Added method is_relativistic()
00043  * Suppressed method f_eccentric
00044  *
00045  * Revision 1.1  2010/01/24 16:07:45  e_gourgoulhon
00046  * New class Star_rot.
00047  *
00048  *
00049  * $Header: /cvsroot/Lorene/C++/Include/star_rot.h,v 1.4 2010/02/08 10:56:30 j_novak Exp $
00050  *
00051  */
00052 
00053 // Headers Lorene
00054 #include "star.h"
00055 
00056 class Eos ;
00057 
00058             //--------------------------//
00059             //    class Star_rot        //
00060             //--------------------------//
00061 
00079 class Star_rot : public Star {
00080 
00081     // Data : 
00082     // -----
00083     protected:
00087     bool relativistic ;
00088 
00092     double unsurc2 ;         
00093 
00094     double omega ;      
00095 
00097     Scalar a_car ; 
00098 
00100     Scalar bbb ; 
00101 
00103     Scalar b_car ; 
00104 
00106     Scalar nphi ; 
00107 
00111     Scalar tnphi ; 
00112 
00114     Scalar uuu ;        
00115     
00119     Scalar nuf ;    
00120 
00124     Scalar nuq ;    
00125 
00127     Scalar dzeta ;  
00128 
00130     Scalar tggg ; 
00131 
00143     Vector w_shift ; 
00144     
00153     Scalar khi_shift ; 
00154 
00160     Sym_tensor tkij ; 
00161 
00179      Scalar ak_car ; 
00180 
00185     Scalar ssjm1_nuf ; 
00186 
00191     Scalar ssjm1_nuq ; 
00192 
00196     Scalar ssjm1_dzeta ; 
00197 
00201     Scalar ssjm1_tggg ; 
00202 
00209      Scalar ssjm1_khi ; 
00210      
00218      Vector ssjm1_wshift ; 
00219      
00220 
00221     // Derived data : 
00222     // ------------
00223     protected:
00224     
00225     mutable double* p_angu_mom ;    
00226     mutable double* p_tsw ;     
00227     mutable double* p_grv2 ;    
00228     mutable double* p_grv3 ;    
00229     mutable double* p_r_circ ;  
00230     mutable double* p_aplat ;   
00231     mutable double* p_z_eqf ;   
00232     mutable double* p_z_eqb ;   
00233     mutable double* p_z_pole ;  
00234     mutable double* p_mom_quad ;    
00235     mutable double* p_r_isco ;  
00236     mutable double* p_f_isco ;  
00237 
00238     mutable double* p_espec_isco ;  
00240     mutable double* p_lspec_isco ;  
00241         mutable double* p_f_eq ;        
00242     
00243      
00244 
00245     // Constructors - Destructor
00246     // -------------------------
00247     public:
00256     Star_rot(Map& mp_i, int nzet_i, bool relat, const Eos& eos_i) ;         
00257     
00258     
00259     Star_rot(const Star_rot& ) ;        
00260 
00268     Star_rot(Map& mp_i, const Eos& eos_i, FILE* fich) ;         
00269 
00270     virtual ~Star_rot() ;           
00271 
00272 
00273     // Memory management
00274     // -----------------
00275     protected:
00277     virtual void del_deriv() const ; 
00278     
00280     virtual void set_der_0x0() const ; 
00281 
00285     virtual void del_hydro_euler() ; 
00286     
00287 
00288     // Mutators / assignment
00289     // ---------------------
00290     public:
00292     void operator=(const Star_rot& ) ;  
00293     
00294     // Accessors
00295     // ---------
00296     public:
00300     bool is_relativistic() const {return relativistic; } ;  
00301 
00305     virtual double get_omega_c() const ;        
00306 
00308     const Scalar& get_bbb() const {return bbb;} ; 
00309 
00311     const Scalar& get_a_car() const {return a_car;} ; 
00312 
00314     const Scalar& get_b_car() const {return b_car;} ; 
00315 
00317     const Scalar& get_nphi() const {return nphi;} ; 
00318 
00322     const Scalar& get_tnphi() const {return tnphi;} ; 
00323 
00325     const Scalar& get_uuu() const {return uuu;} ;       
00326     
00330     const Scalar& get_nuf() const {return nuf;} ;   
00331 
00335     const Scalar& get_nuq() const {return nuq;} ;   
00336 
00338     const Scalar& get_dzeta() const {return dzeta;} ;   
00339 
00341     const Scalar& get_tggg() const {return tggg;} ; 
00342 
00355     const Vector& get_w_shift() const {return w_shift;} ; 
00356     
00369     const Scalar& get_khi_shift() const {return khi_shift;} ; 
00370 
00376     const Sym_tensor& get_tkij() const {return tkij;} ; 
00377 
00395      const Scalar& get_ak_car() const {return ak_car;} ; 
00396 
00397     // Outputs
00398     // -------
00399     public:
00400     virtual void sauve(FILE* ) const ;      
00401     
00403     virtual void display_poly(ostream& ) const ; 
00404 
00405     protected:
00407     virtual ostream& operator>>(ostream& ) const ;    
00408 
00410     virtual void partial_display(ostream& ) const ;    
00411 
00412     // Global quantities
00413     // -----------------
00414     public:
00415     
00423     virtual const Itbl& l_surf() const ; 
00424     
00425     virtual double mass_b() const ;     
00426     virtual double mass_g() const ;     
00427     virtual double angu_mom() const ;   
00428     virtual double tsw() const ;        
00429 
00433     virtual double grv2() const ;   
00434 
00446     virtual double grv3(ostream* ost = 0x0) const ; 
00447 
00448     virtual double r_circ() const ; 
00449     virtual double aplat() const ;  
00450     virtual double z_eqf() const ;  
00451     virtual double z_eqb() const ;  
00452     virtual double z_pole() const ; 
00453     
00463     virtual double mom_quad() const ;   
00464 
00471     virtual double r_isco(ostream* ost = 0x0) const ;   
00472     
00474     virtual double f_isco() const ; 
00475 
00477     virtual double espec_isco() const ; 
00478     
00480     virtual double lspec_isco() const ; 
00481 
00483     virtual double f_eq() const ;
00484     
00485 
00486     // Computational routines
00487     // ----------------------
00488     public: 
00499     virtual void hydro_euler() ; 
00500     
00511     void update_metric() ; 
00512         
00521     void fait_shift() ; 
00522     
00526     void fait_nphi() ; 
00527         
00531     void extrinsic_curvature() ;
00532     
00562     static double lambda_grv2(const Scalar& sou_m, const Scalar& sou_q) ;
00563         
00643     virtual void equilibrium(double ent_c, double omega0, double fact_omega, 
00644              int nzadapt, const Tbl& ent_limit,
00645              const Itbl& icontrol, const Tbl& control,
00646              double mbar_wanted, double aexp_mass, 
00647              Tbl& diff, Param* = 0x0) ;
00648     
00649 
00650 };
00651 
00652 #endif

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