10 #include "earthmodel.hh" 24 const double FIRNDEPTH=-150.;
32 const double scale_factor=0.97276901289;
33 const double ellipsoid_inv_f = 298.257223563;
34 const double ellipsoid_b = EarthModel::R_EARTH*(1-(1/ellipsoid_inv_f));
35 const double eccentricity = sqrt((1/ellipsoid_inv_f)*(2-(1/ellipsoid_inv_f)));
36 const double bedmap_a_bar = pow(eccentricity,2)/2 + 5*pow(eccentricity,4)/24 + pow(eccentricity,6)/12 + 13*pow(eccentricity,8)/360;
37 const double bedmap_b_bar = 7*pow(eccentricity,4)/48 + 29*pow(eccentricity,6)/240 + 811*pow(eccentricity,8)/11520;
38 const double bedmap_c_bar = 7*pow(eccentricity,6)/120 + 81*pow(eccentricity,8)/1120;
39 const double bedmap_d_bar = 4279*pow(eccentricity,8)/161280;
40 const double bedmap_c_0 = (2*EarthModel::R_EARTH / sqrt(1-pow(eccentricity,2))) * pow(( (1-eccentricity) / (1+eccentricity) ),eccentricity/2);
42 #ifdef ICEMODEL_DEBUG_TREE 64 balloon.SetXYZ(0,0,0);
71 enterice.SetXYZ(0,0,0);
72 exitice.SetXYZ(0,0,0);
73 exitearth.SetXYZ(0,0,0);
95 TH2D h_ground_elevation;;
111 int xLowerLeft_ground;
112 int yLowerLeft_ground;
115 int xLowerLeft_water;
116 int yLowerLeft_water;
120 void IceENtoLonLat(
int e,
126 void GroundENtoLonLat(
int e,
130 void WaterENtoLonLat(
int e,
137 vector<double> volume_inhorizon;
138 IceModel(
int model=0,
int earth_mode=0,
int WEIGHTABSORPTION_SETTING=1);
140 double IceThickness(
double lon,
double lat);
141 double IceThickness(
const Position& pos) ;
142 double Surface(
double lon,
double lat) ;
143 double Surface(
const Position& pos) ;
144 double SurfaceAboveGeoid(
double lon,
double lat);
145 double SurfaceAboveGeoid(
const Position& pos) ;
146 double WaterDepth(
double lon,
double lat);
147 double WaterDepth(
const Position& pos);
150 void GetMAXHORIZON(
Balloon *bn1);
151 int RossIceShelf(
const Position &position);
152 int IceOnWater(
const Position &postition);
153 int RossExcept(
const Position &position);
154 int RonneIceShelf(
const Position &position);
156 int AcceptableRfexit(
const Vector &nsurf_rfexit,
const Position &rfexit,
const Vector &n_exit2rx);
157 double GetBalloonPositionWeight(
int ibnpos);
158 int OutsideAntarctica(
const Position &pos);
159 int OutsideAntarctica(
double lat);
160 int WhereDoesItEnterIce(
const Position &posnu,
165 int WhereDoesItExitIce(
const Position &posnu,
169 int WhereDoesItExitIceForward(
const Position &posnu,
176 void CreateCartesianTopAndBottom(
int resolution,
bool force_new =
false);
177 const TH2 * GetCartesianTop()
const {
return cart_ice_top; }
178 const TH2 * GetCartesianBottom()
const {
return cart_ice_bot; }
179 bool CartesianIsInIce(
double x,
double y,
double z);
181 int GetIceIntersectionsCartesian(
const Position &posnu,
const Vector &nnu,
182 std::vector<std::pair<double,double> > & intersections,
double initial_step_size = 50,
int map_resolution=1000);
185 void CreateHorizons(
Settings *settings1,
Balloon *bn1,
double theta_bn,
double phi_bn,
double altitude_bn,ofstream &foutput);
187 double GetN(
double depth);
189 double EffectiveAttenuationLength(
Settings *settings1,
const Position &pos,
const int &whichray);
191 void FillArraysforTree(
double lon_ground[1068][869],
double lat_ground[1068][869],
double lon_ice[1200][1000],
double lat_ice[1200][1000],
double lon_water[1200][1000],
double lat_water[1200][1000]);
192 int PickUnbiased(
Interaction *interaction1,
double len_int_kgm2,
double & position_weight,
double chord_step,
Vector * force_dir = 0);
194 int PickUnbiasedPointSourceNearBalloon(
Interaction *interaction1,
195 const Position * balloon_position,
double max_ps_distance,
double chord_step,
196 double len_int_kgm2,
const Vector * force_dir = 0);
198 double getSampleX()
const {
return sample_x; }
199 double getSampleY()
const {
return sample_y; }
201 void LonLattoEN(
double lon,
209 int DEPTH_DEPENDENT_N;
215 double volume_inhorizon_average;
216 vector< vector<int> > ilon_inhorizon;
217 vector< vector<int> >ilat_inhorizon;
218 vector< vector<int> >easting_inhorizon;
219 vector< vector<int> >northing_inhorizon;
220 vector<double> maxvol_inhorizon;
224 double sample_x, sample_y;
228 TFile *cart_ice_file;
232 double Area(
double latitude);
234 void ENtoLonLat(
int e_coord,
246 void ReadIceThickness();
247 void ReadGroundBed();
248 void ReadWaterDepth();
252 const static int N_sheetup=2810;
253 double d_sheetup[N_sheetup], l_sheetup[N_sheetup];
254 const static int N_shelfup=420;
255 double d_shelfup[N_shelfup], l_shelfup[N_shelfup];
256 const static int N_westlandup=420;
257 double d_westlandup[N_westlandup],l_westlandup[N_westlandup];
259 const static int N_sheetdown=2810;
260 double d_sheetdown[N_sheetup], l_sheetdown[N_sheetdown];
261 const static int N_shelfdown=420;
262 double d_shelfdown[N_shelfdown], l_shelfdown[N_shelfdown];
263 const static int N_westlanddown=420;
264 double d_westlanddown[N_westlanddown],l_westlanddown[N_westlanddown];
Reads in and stores input settings for the run.
This class is a 3-vector that represents a position on the Earth's surface.
Stores everything about a particular neutrino interaction. Interaction.
Shape of the earth, ice thicknesses, profiles of earth layers, densities, neutrino absorption...
Handles everything related to balloon positions, payload orientation over the course of a flight...
This class represents a three-vector. Operators are overloaded to provide for the familiar operations...
Ice thicknesses and water depth.