star_rot_dirac_diff.h
/*
* Definition of Lorene class Star_rot_dirac_diff
*
*/
/*
* Copyright (c) 2005 Motoyuki Saijo
*
* This file is part of LORENE.
*
* LORENE is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* LORENE is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with LORENE; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
*/
#ifndef __STAR_ROT_DIRAC_DIFF_H_
#define __STAR_ROT_DIRAC_DIFF_H_
/*
*
* $Header: /cvsroot/Lorene/C++/Include/star_rot_dirac_diff.h,v 1.2 2014/10/13 08:52:36 j_novak Exp $
*
*/
// Headers Lorene
#include "star_rot_dirac.h"
namespace Lorene {
class Star_rot_Dirac_diff : public Star_rot_Dirac {
// Data :
// -----
protected:
double (*frot)(double, const Tbl&) ;
double (*primfrot)(double, const Tbl&) ;
Tbl par_frot ;
Scalar omega_field ;
double omega_min ;
double omega_max ;
Scalar prim_field ;
// Constructors - Destructor
// -------------------------
public:
Star_rot_Dirac_diff(Map& mp_i, int nzet_i, const Eos& eos_i,
double (*frot_i)(double, const Tbl&),
double (*primfrot_i)(double, const Tbl&),
const Tbl& par_frot_i) ;
Star_rot_Dirac_diff(const Star_rot_Dirac_diff& ) ;
Star_rot_Dirac_diff(Map& mp_i, const Eos& eos_i, FILE* fich,
double (*frot_i)(double, const Tbl&),
double (*primfrot_i)(double, const Tbl&) ) ;
virtual ~Star_rot_Dirac_diff() ;
// Memory management
// -----------------
// Everything is inherited from Star_rot_dirac
// Mutators / assignment
// ---------------------
public:
void operator=(const Star_rot_Dirac_diff& ) ;
// Accessors
// ---------
public:
const Scalar& get_omega_field() const {return omega_field;} ;
virtual double get_omega_c() const ;
// Outputs
// -------
public:
virtual void sauve(FILE *) const ;
/* /// Display in polytropic units */
/* virtual void display_poly(ostream& ) const ; */
friend ostream& operator<<(ostream& , const Star& ) ;
protected:
virtual ostream& operator>>(ostream& ) const ;
// Computational routines
// ----------------------
public:
virtual double tsw() const ;
virtual void hydro_euler() ;
void fait_omega_field(double omeg_min, double omeg_max,
double precis, int nitermax) ;
void fait_prim_field() ;
double funct_omega(double omeg) const ;
double prim_funct_omega(double omeg) const ;
virtual void equilibrium(double ent_c, double omega0, double fact_omega,
int nzadapt, const Tbl& ent_limit,
const Itbl& icontrol, const Tbl& control,
double mbar_wanted, double aexp_mass,
Tbl& diff) ;
};
}
#endif
Lorene::Eos
Equation of state base class.
Definition eos.h:190
Lorene::Itbl
Basic integer array class.
Definition itbl.h:122
Lorene::Scalar
Tensor field of valence 0 (or component of a tensorial field).
Definition scalar.h:387
Lorene::Star_rot_Dirac_diff::fait_omega_field
void fait_omega_field(double omeg_min, double omeg_max, double precis, int nitermax)
Computes (member omega_field ).
Definition strot_dirac_diff_faitomeg.C:52
Lorene::Star_rot_Dirac_diff::~Star_rot_Dirac_diff
virtual ~Star_rot_Dirac_diff()
Destructor.
Definition star_rot_dirac_diff.C:116
Lorene::Star_rot_Dirac_diff::equilibrium
virtual void equilibrium(double ent_c, double omega0, double fact_omega, int nzadapt, const Tbl &ent_limit, const Itbl &icontrol, const Tbl &control, double mbar_wanted, double aexp_mass, Tbl &diff)
Computes an equilibrium configuration.
Definition strot_dirac_diff_equil.C:47
Lorene::Star_rot_Dirac_diff::omega_field
Scalar omega_field
Field .
Definition star_rot_dirac_diff.h:84
Lorene::Star_rot_Dirac_diff::operator>>
virtual ostream & operator>>(ostream &) const
Operator >> (virtual function called by the operator <<).
Definition star_rot_dirac_diff.C:170
Lorene::Star_rot_Dirac_diff::get_omega_field
const Scalar & get_omega_field() const
Returns the angular velocity field .
Definition star_rot_dirac_diff.h:149
Lorene::Star_rot_Dirac_diff::funct_omega
double funct_omega(double omeg) const
Evaluates , where F is the function defining the rotation profile.
Definition star_rot_dirac_diff.C:250
Lorene::Star_rot_Dirac_diff::sauve
virtual void sauve(FILE *) const
Save in a file.
Definition star_rot_dirac_diff.C:151
Lorene::Star_rot_Dirac_diff::prim_funct_omega
double prim_funct_omega(double omeg) const
Evaluates the primitive of , where F is the function defining the rotation profile.
Definition star_rot_dirac_diff.C:256
Lorene::Star_rot_Dirac_diff::operator<<
friend ostream & operator<<(ostream &, const Star &)
Display.
Definition star.C:412
Lorene::Star_rot_Dirac_diff::hydro_euler
virtual void hydro_euler()
Computes the hydrodynamical quantities relative to the Eulerian observer from those in the fluid fram...
Definition strot_dirac_diff_hydro.C:44
Lorene::Star_rot_Dirac_diff::Star_rot_Dirac_diff
Star_rot_Dirac_diff(Map &mp_i, int nzet_i, const Eos &eos_i, double(*frot_i)(double, const Tbl &), double(*primfrot_i)(double, const Tbl &), const Tbl &par_frot_i)
Standard constructor.
Definition star_rot_dirac_diff.C:53
Lorene::Star_rot_Dirac_diff::fait_prim_field
void fait_prim_field()
Computes the member prim_field from omega_field .
Definition strot_dirac_diff_faitomeg.C:176
Lorene::Star_rot_Dirac_diff::frot
double(* frot)(double, const Tbl &)
Function defining the rotation profile.
Definition star_rot_dirac_diff.h:64
Lorene::Star_rot_Dirac_diff::omega_min
double omega_min
Minimum value of .
Definition star_rot_dirac_diff.h:86
Lorene::Star_rot_Dirac_diff::get_omega_c
virtual double get_omega_c() const
Returns the central value of the rotation angular velocity ([f_unit] ).
Definition star_rot_dirac_diff.C:262
Lorene::Star_rot_Dirac_diff::primfrot
double(* primfrot)(double, const Tbl &)
Primitive of the function , which vanishes at the stellar center.
Definition star_rot_dirac_diff.h:72
Lorene::Star_rot_Dirac_diff::prim_field
Scalar prim_field
Field .
Definition star_rot_dirac_diff.h:90
Lorene::Star_rot_Dirac_diff::tsw
virtual double tsw() const
Ratio T/W.
Definition strot_dirac_diff_global.C:48
Lorene::Star_rot_Dirac_diff::par_frot
Tbl par_frot
Parameters of the function .
Definition star_rot_dirac_diff.h:81
Lorene::Star_rot_Dirac_diff::operator=
void operator=(const Star_rot_Dirac_diff &)
Assignment to another Star_rot_Dirac_diff.
Definition star_rot_dirac_diff.C:126
Lorene::Star_rot_Dirac_diff::omega_max
double omega_max
Maximum value of .
Definition star_rot_dirac_diff.h:87
Lorene::Star_rot_Dirac::Star_rot_Dirac
Star_rot_Dirac(Map &mp_i, int nzet_i, const Eos &eos_i, int filter=0)
Standard constructor.
Definition star_rot_dirac.C:93
Lorene::Star
Base class for stars.
Definition star.h:175
Lorene::Tbl
Basic array class.
Definition tbl.h:161
Lorene
Lorene prototypes.
Definition app_hor.h:64
Lorene::Map
Map(const Mg3d &)
Constructor from a multi-domain 3D grid.
Definition map.C:139