00001 /* 00002 * proto_star.h: derived class for evolution of proto stars. 00003 * 00004 *.......................................................................... 00005 * version 1: May 1999 Simon F. Portegies Zwart 00006 * version 2: 00007 *.......................................................................... 00008 * This file includes: 00009 * 1) definition of class proto_star 00010 * 00011 *.......................................................................... 00012 */ 00013 00014 #ifndef _PROTO_STAR 00015 # define _PROTO_STAR 00016 00017 #include "single_star.h" 00018 #include "brown_dwarf.h" 00019 #include "main_sequence.h" 00020 00021 // Known class declarations. 00022 00023 class brown_dwarf; 00024 class main_sequence; 00025 /*----------------------------------------------------------------------------- 00026 * proto_star -- a derived class for element evolution. 00027 *----------------------------------------------------------------------------- 00028 */ 00029 class proto_star : public single_star { 00030 private: 00031 00032 vec angular_momentum; 00033 00034 public : 00035 00036 proto_star(node* n) : single_star(n) {} 00037 ~proto_star() {} 00038 00039 stellar_type get_element_type() {return Proto_Star;} 00040 bool giant_star() {return true;} 00041 00042 void instantaneous_element(); 00043 void evolve_element(const real); 00044 void create_zero_age_object(); 00045 void create_binary_from_proto_star(); 00046 00047 // Mass transfer stability. 00048 real zeta_thermal(); 00049 real gyration_radius_sq(); 00050 00051 star* reduce_mass(const real); 00052 star* subtrac_mass_from_donor(const real, real&); 00053 void adjust_accretor_age(const real, const bool); 00054 void adjust_next_update_age(); 00055 void update_wind_constant(); 00056 00057 void stellar_wind(const real); 00058 real helium_core_mass(); 00059 00060 vec get_angular_momentum() {return angular_momentum;} 00061 void set_angular_momentum(vec v) {angular_momentum = v;} 00062 00063 // Friend constructors 00064 // friend planet::planet(proto_star &); 00065 friend brown_dwarf::brown_dwarf(proto_star &); 00066 friend main_sequence::main_sequence(proto_star &); 00067 00068 }; 00069 #endif // _PROTO_STAR 00070 00071 00072