7
7
8
8
// -----------------------------------------------------------------------------
9
9
// Set initial conditions for the neutrals.
10
- // Two methods implemented so far:
10
+ // If user wants to restart, then read the restart files.
11
+ // Otherwise, initialize the neutrals.
12
+ //
13
+ // Two methods of initialization implemented so far:
11
14
// - Planet: Use fixed density values in the planet.in file and the
12
15
// temperature profile to set the densities and temperature.
13
16
// Densities are filled with hydrostatic solution.
@@ -35,9 +38,12 @@ bool Neutrals::initial_conditions(Grid grid,
35
38
36
39
report.print (3 , " Creating Neutrals initial_condition" );
37
40
41
+ // ----------------------------------------------------------
42
+ // Restart file:
43
+
38
44
if (input.get_do_restart ()) {
39
45
report.print (1 , " Restarting! Reading neutral files!" );
40
- didWork = restart_file (input.get_restartin_dir (), DoRead);
46
+ didWork = restart_file (input.get_restartin_dir (), grid. get_gridtype (), DoRead);
41
47
42
48
if (!didWork)
43
49
report.error (" Reading Restart for Neutrals Failed!!!" );
@@ -46,6 +52,9 @@ bool Neutrals::initial_conditions(Grid grid,
46
52
json ics = input.get_initial_condition_types ();
47
53
std::string icsType = mklower (ics[" type" ]);
48
54
55
+ // ----------------------------------------------------------
56
+ // MSIS:
57
+
49
58
if (icsType == " msis" ) {
50
59
report.print (2 , " Using MSIS for Initial Conditions" );
51
60
@@ -98,6 +107,9 @@ bool Neutrals::initial_conditions(Grid grid,
98
107
} // msis init worked ok
99
108
} // type = msis
100
109
110
+ // ----------------------------------------------------------
111
+ // Planet:
112
+
101
113
if (icsType == " planet" ) {
102
114
report.print (2 , " Using planet for Initial Conditions" );
103
115
@@ -161,7 +173,6 @@ bool Neutrals::initial_conditions(Grid grid,
161
173
162
174
// Make the initial condition in the lower ghost cells to be consistent
163
175
// with the actual lowwer BC:
164
- // Set the lower boundary condition:
165
176
166
177
for (int iSpecies = 0 ; iSpecies < nSpecies; iSpecies++) {
167
178
species[iSpecies].density_scgc .slice (0 ).
0 commit comments