Skip to main content
Version: Develop 🚧

Running a Grid

A common task is to run UCLCHEM over a grid of parameter combinations. This notebook sets up a simple approach to doing so for regular grids.

import uclchem
import numpy as np
import pandas as pd
import os
from joblib import Parallel, delayed

A Simple Grid​

Define Parameter Space​

First, we define our parameter space. We do this by using numpy and pandas to produce a table of all possible combinations of some parameters of interest.

# This part can be substituted with any choice of grid
# here we just vary the density, temperature and zeta
temperatures = np.linspace(10, 50, 3)
densities = np.logspace(4, 6, 3)
zetas = np.logspace(1, 3, 3)

# meshgrid will give all combinations, then we shape into columns and put into a table
parameterSpace = np.asarray(np.meshgrid(temperatures, densities, zetas)).reshape(3, -1)
model_table = pd.DataFrame(parameterSpace.T, columns=["temperature", "density", "zeta"])

# keep track of where each model output will be saved and make sure that folder exists
model_table["outputFile"] = model_table.apply(
lambda row: f"../grid_folder/\{row.temperature\}_\{row.density\}_\{row.zeta\}.csv", axis=1
)
print(f"\{model_table.shape[0]\} models to run")
if not os.path.exists("../grid_folder"):
os.makedirs("../grid_folder")

27 models to run

model_table.head()
temperaturedensityzetaoutputFile
010.010000.010.0../grid_folder/10.0_10000.0_10.0.csv
110.010000.0100.0../grid_folder/10.0_10000.0_100.0.csv
210.010000.01000.0../grid_folder/10.0_10000.0_1000.0.csv
330.010000.010.0../grid_folder/30.0_10000.0_10.0.csv
430.010000.0100.0../grid_folder/30.0_10000.0_100.0.csv

Set up the model​

Next, we need a function that will run our model. We write a quick function that takes a row from our dataframe and uses it to populate a parameter dictionary for UCLCHEM and then run a cloud model. We can then map our dataframe to that function.

def run_model(row):
# basic set of parameters we'll use for this grid.
ParameterDictionary = \{
"endatfinaldensity": False,
"freefall": False,
"initialDens": row.density,
"initialTemp": row.temperature,
"zeta": row.zeta,
"outputFile": row.outputFile,
"finalTime": 1.0e6,
"baseAv": 10,
"abstol_min": 1e-22,
\}
result = uclchem.model.cloud(param_dict=ParameterDictionary)
return result[0] # just the integer error code

Run Grid​

The Simple Way​

We can use pandas apply to simply pass each row to our helper function in turn. This will take some time since we're running the models one by one. I'll use the head function just to run five rows as an example here.

%%time
result = model_table.head().apply(run_model, axis=1)

CPU times: user 42.8 s, sys: 653 ms, total: 43.5 s Wall time: 43.7 s

The Fast Way​

Alternatively, we can use multiprocessing to run the models in parallel. That will allow us to run many models simulataneously and make use of all the cores available on our machine.

%%time
results = Parallel(n_jobs=4, verbose=100)(
delayed(run_model)(row) for idx, row in model_table.iterrows()
)

[Parallel(n_jobs=4)]: Using backend LokyBackend with 4 concurrent workers.

[Parallel(n_jobs=4)]: Done 1 tasks | elapsed: 7.4s [Parallel(n_jobs=4)]: Done 2 tasks | elapsed: 8.1s [Parallel(n_jobs=4)]: Done 3 tasks | elapsed: 9.3s [Parallel(n_jobs=4)]: Done 4 tasks | elapsed: 13.8s [Parallel(n_jobs=4)]: Done 5 tasks | elapsed: 14.9s [Parallel(n_jobs=4)]: Done 6 tasks | elapsed: 17.5s [Parallel(n_jobs=4)]: Done 7 tasks | elapsed: 23.0s [Parallel(n_jobs=4)]: Done 8 tasks | elapsed: 25.6s [Parallel(n_jobs=4)]: Done 9 tasks | elapsed: 29.9s [Parallel(n_jobs=4)]: Done 10 tasks | elapsed: 42.2s [Parallel(n_jobs=4)]: Done 11 tasks | elapsed: 49.9s [Parallel(n_jobs=4)]: Done 12 tasks | elapsed: 55.0s [Parallel(n_jobs=4)]: Done 13 tasks | elapsed: 58.1s [Parallel(n_jobs=4)]: Done 14 tasks | elapsed: 1.2min [Parallel(n_jobs=4)]: Done 15 tasks | elapsed: 1.2min [Parallel(n_jobs=4)]: Done 16 tasks | elapsed: 1.2min [Parallel(n_jobs=4)]: Done 17 tasks | elapsed: 1.5min [Parallel(n_jobs=4)]: Done 18 tasks | elapsed: 1.5min [Parallel(n_jobs=4)]: Done 19 tasks | elapsed: 1.7min [Parallel(n_jobs=4)]: Done 20 tasks | elapsed: 1.9min [Parallel(n_jobs=4)]: Done 21 out of 27 | elapsed: 2.0min remaining: 34.1s [Parallel(n_jobs=4)]: Done 22 out of 27 | elapsed: 2.0min remaining: 27.1s [Parallel(n_jobs=4)]: Done 23 out of 27 | elapsed: 2.2min remaining: 23.2s [Parallel(n_jobs=4)]: Done 24 out of 27 | elapsed: 2.2min remaining: 16.7s [Parallel(n_jobs=4)]: Done 25 out of 27 | elapsed: 2.5min remaining: 11.8s [Parallel(n_jobs=4)]: Done 27 out of 27 | elapsed: 6.2min finished CPU times: user 218 ms, sys: 150 ms, total: 368 ms Wall time: 6min 13s

Checking Your Grid​

After running, we should do two things. First, let's add results to our dataframe as a new column. Positive results mean a successful UCLCHEM run and negative ones are unsuccessful. Then we can run each model through check_element_conservation to check the integration was successful. We'll use both these things to flag models that failed in some way.

def element_check(output_file):
df = uclchem.analysis.read_output_file(output_file)
# get conservation values
conserves = uclchem.analysis.check_element_conservation(df)
# check if any error is greater than 1%
return all([float(x[:-1]) < 1 for x in conserves.values()])
model_table["run_result"] = results
model_table["elements_conserved"] = model_table["outputFile"].map(element_check)
# check both conditions are met
model_table["Successful"] = (model_table.run_result >= 0) & (
model_table.elements_conserved
)
model_table.head()
temperaturedensityzetaoutputFilerun_resultelements_conservedSuccessful
010.010000.010.0../grid_folder/10.0_10000.0_10.0.csv0TrueTrue
110.010000.0100.0../grid_folder/10.0_10000.0_100.0.csv0TrueTrue
210.010000.01000.0../grid_folder/10.0_10000.0_1000.0.csv0TrueTrue
330.010000.010.0../grid_folder/30.0_10000.0_10.0.csv0TrueTrue
430.010000.0100.0../grid_folder/30.0_10000.0_100.0.csv0TrueTrue

Complex Grid​

The above was straightforward enough but what about a modelling a grid of shocks? Not only do we want to loop over relevant parameters, we also need to run a few preliminary models to give ourselves starting abundances. We'll start by defining two helper functions, one to run our preliminary cloud and one to run the shock.

Let's further imagine that we want to obtain the abundances of several species at the end of the model. We can use the out_species parameter to specify which species we want to track and return them to our dataframe.

out_species = ["CO", "H2O", "CH3OH"]


def run_prelim(density):
# basic set of parameters we'll use for this grid.
ParameterDictionary = \{
"endatfinaldensity": True,
"freefall": True,
"initialDens": 1e2,
"finalDens": float(density),
"initialTemp": 10.0,
"abundSaveFile": f"../grid_folder/starts/\{density:.0f\}.csv",
"baseAv": 1,
\}
result = uclchem.model.cloud(param_dict=ParameterDictionary)
return result


def run_model(row):
# basic set of parameters we'll use for this grid.
ParameterDictionary = \{
"endatfinaldensity": False,
"freefall": False,
"initialDens": float(row.density),
"initialTemp": 10.0,
"outputFile": row.outputFile,
"abundLoadFile": f"../grid_folder/starts/\{row.density:.0f\}.csv",
"finalTime": 1.0e5,
"abstol_factor": 1e-14,
"abstol_min": 1e-20,
"reltol": 1e-6,
"baseAv": 1,
\}
result = uclchem.model.cshock(
row.shock_velocity, param_dict=ParameterDictionary, out_species=out_species
)
# First check UCLCHEM's result flag to seeif it ran succesfully, if it is return the abundances
if result[0] == 0:
return result[:]
# if not, return NaNs because model failed
else:
return [np.nan] * len(out_species)

Then we define our parameter space again. We'll create two folders, one to store a set of initial abundances for each starting density in our model and another to store our shock outputs.

# This part can be substituted with any choice of grid
# here we just combine various initial and final densities into an easily iterable array
shock_velocities = np.linspace(10, 50, 3)
densities = np.logspace(4, 6, 3)

parameterSpace = np.asarray(np.meshgrid(shock_velocities, densities)).reshape(2, -1)
model_table = pd.DataFrame(parameterSpace.T, columns=["shock_velocity", "density"])
model_table["outputFile"] = model_table.apply(
lambda row: f"../grid_folder/shocks/\{row.shock_velocity\}_\{row.density\}.csv", axis=1
)
print(f"\{model_table.shape[0]\} models to run")

for folder in ["starts", "shocks"]:
if not os.path.exists(f"../grid_folder/\{folder\}"):
os.makedirs(f"../grid_folder/\{folder\}")

9 models to run

We can then run our preliminary models followed by our science models. The science models will return the abundances at the final time step of each run so we can unpack those directly to our dataframe.

results = Parallel(n_jobs=4, verbose=100)(
delayed(run_prelim)(dens) for dens in densities
)

[Parallel(n_jobs=4)]: Using backend LokyBackend with 4 concurrent workers.

results = Parallel(n_jobs=4, verbose=100)(
delayed(run_model)(row) for idx, row in model_table.iterrows()
)

[Parallel(n_jobs=4)]: Using backend LokyBackend with 4 concurrent workers. At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5335516294406D+09 ISTATE -1: Reducing time step to 37025057.016786143 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5337421822880D+09 ISTATE -1: Reducing time step to 36716425.432567358 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5338870980660D+09 ISTATE -1: Reducing time step to 36481556.721932642 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5578538245666D+09 ISTATE -1: Reducing time step to 61184164.576365016 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5275624753235D+12 ISTATE -1: Reducing time step to 25031525286063.090 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.3624332510045D+12 ISTATE -1: Reducing time step to 9335740036630.7051 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5848597632469D+12 ISTATE -1: Reducing time step to 22120518952113.727 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5579887306693D+09 ISTATE -1: Reducing time step to 60960745.314617805 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8122437636366D+12 R2 = 0.3351314472062D+04 ISTATE -5 - shortening step at time 25703.916570777641 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.9667454198516D+12 R2 = 0.1149101028733D-05 ISTATE -5 - shortening step at time 30593.209488974091 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1166434749650D+13 R2 = 0.2220049248659D+03 ISTATE -5 - shortening step at time 36912.492077539842 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1167611392815D+13 R2 = 0.6656890691008D+03 ISTATE -5 - shortening step at time 36949.727620723010 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1178287693214D+13 R2 = 0.4072462170449D-04 ISTATE -5 - shortening step at time 37287.585228285512 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1167831922315D+13 R2 = 0.2855535747341D+04 ISTATE -5 - shortening step at time 36956.706402376993 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1167923574272D+13 R2 = 0.1416265357005D+03 ISTATE -5 - shortening step at time 36959.606780764043 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1168154780560D+13 R2 = 0.1943892680823D+04 ISTATE -5 - shortening step at time 36966.923435451135 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1414345141165D+13 R2 = 0.9733822968482D+04 ISTATE -5 - shortening step at time 44757.757631792883 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1168943279340D+13 R2 = 0.2597716335951D-04 ISTATE -5 - shortening step at time 36991.875928468980 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1169071520458D+13 R2 = 0.1597357776302D+04 ISTATE -5 - shortening step at time 36995.934191705179 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1169220297724D+13 R2 = 0.9990739747528D+03 ISTATE -5 - shortening step at time 37000.642333048476 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1169511894755D+13 R2 = 0.5058567054156D+03 ISTATE -5 - shortening step at time 37009.870087169606 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1550849118130D+13 R2 = 0.6483857579871D-04 ISTATE -5 - shortening step at time 49077.503738286956 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1169715639283D+13 R2 = 0.1744845365680D+04 ISTATE -5 - shortening step at time 37016.317698834122 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1552244186825D+13 R2 = 0.9187899890813D-04 ISTATE -5 - shortening step at time 49121.651481801375 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1289447841315D+13 R2 = 0.1378455055303D-04 ISTATE -5 - shortening step at time 40805.311434004245 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1290251640064D+13 R2 = 0.4423940862798D+03 ISTATE -5 - shortening step at time 40830.748103295118 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1290759462532D+13 R2 = 0.1449041774656D+03 ISTATE -5 - shortening step at time 40846.818434552792 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3212605409996D+11 R2 = 0.9487090607619D-07 ISTATE -5 - shortening step at time 1016.6472816442981 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1290891532280D+13 R2 = 0.3340968975726D-04 ISTATE -5 - shortening step at time 40850.997856946778 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1291064805460D+13 R2 = 0.5545927521902D+03 ISTATE -5 - shortening step at time 40856.481185443190 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1875370676837D+13 R2 = 0.1945327079762D-05 ISTATE -5 - shortening step at time 59347.173317633074 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3678651326443D+11 R2 = 0.3858220650600D-04 ISTATE -5 - shortening step at time 1164.1301665959361 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2062549968121D+13 R2 = 0.1116644664220D-05 ISTATE -5 - shortening step at time 65270.568611412535 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2062750120629D+13 R2 = 0.1254519469361D+04 ISTATE -5 - shortening step at time 65276.902551546147 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2062850593192D+13 R2 = 0.5674979910345D+03 ISTATE -5 - shortening step at time 65280.082063029768 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2062905791493D+13 R2 = 0.1021370979395D+03 ISTATE -5 - shortening step at time 65281.828844715666 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2063153794621D+13 R2 = 0.1011730551787D+04 ISTATE -5 - shortening step at time 65289.677044971031 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1885533205539D+13 R2 = 0.7075798532258D-06 ISTATE -5 - shortening step at time 59668.772327184051 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4569942640962D+11 R2 = 0.1539070755750D-06 ISTATE -5 - shortening step at time 1446.1843800513079 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2063215484970D+13 R2 = 0.2054504462855D-04 ISTATE -5 - shortening step at time 65291.629271199330 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4631858445910D+11 R2 = 0.1757589004069D-02 ISTATE -5 - shortening step at time 1465.7779892119986 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2063552943002D+13 R2 = 0.1453679572896D+04 ISTATE -5 - shortening step at time 65302.308322862038 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2063671333860D+13 R2 = 0.2030026229383D+03 ISTATE -5 - shortening step at time 65306.054868986314 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2076023169579D+13 R2 = 0.3436007284567D-06 ISTATE -5 - shortening step at time 65696.935746183226 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2076164303312D+13 R2 = 0.1194592568328D+04 ISTATE -5 - shortening step at time 65701.402003534196 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2146456894165D+13 R2 = 0.1106321681621D+06 ISTATE -5 - shortening step at time 67925.851081182278 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4984282901989D+11 R2 = 0.1476175558270D-05 ISTATE -5 - shortening step at time 1577.3047158194111 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5484925337511D+11 R2 = 0.7038366722792D-05 ISTATE -5 - shortening step at time 1735.7358663011037 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5493931277967D+11 R2 = 0.5346816162889D+03 ISTATE -5 - shortening step at time 1738.5858474580498 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2267894316430D+13 R2 = 0.1379628225853D-05 ISTATE -5 - shortening step at time 71768.807481974130 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5500171001321D+11 R2 = 0.9013063648500D+02 ISTATE -5 - shortening step at time 1740.5604434558586 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5581136531366D+09 ISTATE -1: Reducing time step to 60753757.328615919 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2494333111372D+13 R2 = 0.1124296052978D-05 ISTATE -5 - shortening step at time 78934.592132016551 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.7953322710271D+11 R2 = 0.6068119935427D-06 ISTATE -5 - shortening step at time 2516.8742754022073 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8732488424293D+11 R2 = 0.1373283059164D-05 ISTATE -5 - shortening step at time 2763.4457038902410 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2743868469188D+13 R2 = 0.6031783486930D-05 ISTATE -5 - shortening step at time 86831.280670501175 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.9623908573851D+11 R2 = 0.1579775762817D-04 ISTATE -5 - shortening step at time 3045.5406879273983 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1056492605072D+12 R2 = 0.4824509132425D-06 ISTATE -5 - shortening step at time 3343.3310287090144 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1062051292277D+12 R2 = 0.1061151278702D-03 ISTATE -5 - shortening step at time 3360.9218110017737 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1160997537601D+12 R2 = 0.1176676234018D-05 ISTATE -5 - shortening step at time 3674.0428405089783 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1163937793092D+12 R2 = 0.1833456713515D+03 ISTATE -5 - shortening step at time 3683.3474464946744 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1275924895272D+12 R2 = 0.1143798613529D-04 ISTATE -5 - shortening step at time 4037.7370103557255 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4395591895412D+12 R2 = 0.1171440439679D-06 ISTATE -5 - shortening step at time 13910.100934849299 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4834979843115D+12 R2 = 0.4248274037828D-07 ISTATE -5 - shortening step at time 15300.569123782352 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5582138671279D+09 ISTATE -1: Reducing time step to 60587638.199620269 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5849799961933D+12 R2 = 0.6283662633056D-07 ISTATE -5 - shortening step at time 18512.025195989845 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6434671451818D+12 R2 = 0.1798403888089D-07 ISTATE -5 - shortening step at time 20362.884341196845 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8564223272750D+12 R2 = 0.2115611372332D-06 ISTATE -5 - shortening step at time 27101.972382121214 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1379244773499D+13 R2 = 0.1053269119022D-06 ISTATE -5 - shortening step at time 43646.986503124099 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1668867720969D+13 R2 = 0.1542742271797D-07 ISTATE -5 - shortening step at time 52812.269650920323 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1835751705551D+13 R2 = 0.1289877589706D-06 ISTATE -5 - shortening step at time 58093.408403515285 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5583078597776D+09 ISTATE -1: Reducing time step to 60431774.074822776 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2221253451040D+13 R2 = 0.7056911402998D-07 ISTATE -5 - shortening step at time 70292.830729120251 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6019073918102D+11 R2 = 0.1762502404619D-05 ISTATE -5 - shortening step at time 1904.7702272474369 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037050802231D+10 ISTATE -1: Reducing time step to 20093452451.680614 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6062913053246D+11 R2 = 0.1638273598721D-03 ISTATE -5 - shortening step at time 1918.6433712805313 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6572508640559D+11 R2 = 0.8772962197884D-06 ISTATE -5 - shortening step at time 2079.9077976453855 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6596324429774D+11 R2 = 0.6825860967081D-05 ISTATE -5 - shortening step at time 2087.4444398017649 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6623751112820D+11 R2 = 0.1450966460740D+03 ISTATE -5 - shortening step at time 2096.1237698797786 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6636324705989D+11 R2 = 0.9880599722037D+03 ISTATE -5 - shortening step at time 2100.1027550598651 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.7956755530785D+11 R2 = 0.3696933045875D-06 ISTATE -5 - shortening step at time 2517.9606110077543 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8747216495131D+11 R2 = 0.6991752296575D-05 ISTATE -5 - shortening step at time 2768.1064858009240 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8754924320061D+11 R2 = 0.1395493605349D-04 ISTATE -5 - shortening step at time 2770.5456709053310 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8766474880043D+11 R2 = 0.8608890040219D+03 ISTATE -5 - shortening step at time 2774.2009114061029 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8775350048082D+11 R2 = 0.2745464651002D-05 ISTATE -5 - shortening step at time 2777.0095088867515 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5584008754231D+09 ISTATE -1: Reducing time step to 60277475.029261358 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1866640043705D+12 R2 = 0.8572398372024D+01 ISTATE -5 - shortening step at time 5907.0887459014893 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2052584001552D+12 R2 = 0.5292236157888D-06 ISTATE -5 - shortening step at time 6495.5189922523377 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2258278333125D+12 R2 = 0.4733989427460D+02 ISTATE -5 - shortening step at time 7146.4504212810516 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2730215231419D+12 R2 = 0.4715867581554D-06 ISTATE -5 - shortening step at time 8639.9216184161178 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037066801555D+10 ISTATE -1: Reducing time step to 20093085528.711781 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3002536020179D+12 R2 = 0.2108206170470D-05 ISTATE -5 - shortening step at time 9501.6962663902268 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4395401483307D+12 R2 = 0.2211613989437D-06 ISTATE -5 - shortening step at time 13909.498364897116 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5318161916820D+12 R2 = 0.9365899574633D+01 ISTATE -5 - shortening step at time 16829.626319052102 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.5318490304554D+12 R2 = 0.7379786398131D-06 ISTATE -5 - shortening step at time 16830.665520739753 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6434778852150D+12 R2 = 0.2158453911462D-06 ISTATE -5 - shortening step at time 20363.224215663402 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5584764499842D+09 ISTATE -1: Reducing time step to 60152067.814386435 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8564207716730D+12 R2 = 0.6118815217590D+01 ISTATE -5 - shortening step at time 27101.923154208242 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1379229195480D+13 R2 = 0.2791933563082D-05 ISTATE -5 - shortening step at time 43646.493527842562 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1379236605006D+13 R2 = 0.8246852089811D+01 ISTATE -5 - shortening step at time 43646.728006513782 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037079031834D+10 ISTATE -1: Reducing time step to 20092805042.648476 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1517157053307D+13 R2 = 0.2640179150402D-06 ISTATE -5 - shortening step at time 48011.299155284483 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1668861570879D+13 R2 = 0.1187711933423D+01 ISTATE -5 - shortening step at time 52812.075027809558 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1668869383652D+13 R2 = 0.4551286979319D-06 ISTATE -5 - shortening step at time 52812.322267461932 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1835742461936D+13 R2 = 0.2521377324372D+01 ISTATE -5 - shortening step at time 58093.115884040373 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5585572755919D+09 ISTATE -1: Reducing time step to 60017907.093298167 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2019317644598D+13 R2 = 0.3152782532574D-06 ISTATE -5 - shortening step at time 63902.457107540919 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2221250509813D+13 R2 = 0.7373395586521D-07 ISTATE -5 - shortening step at time 70292.737652322816 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037091518668D+10 ISTATE -1: Reducing time step to 20092518671.835888 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2443366131128D+13 R2 = 0.2136686351367D-05 ISTATE -5 - shortening step at time 77321.713010374922 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2956466031688D+13 R2 = 0.2032520688308D-06 ISTATE -5 - shortening step at time 93559.051635690965 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5586355736731D+09 ISTATE -1: Reducing time step to 59887902.332642876 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037101739256D+10 ISTATE -1: Reducing time step to 20092284273.968025 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037112980263D+10 ISTATE -1: Reducing time step to 20092026473.161282 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037123207463D+10 ISTATE -1: Reducing time step to 20091791922.251476 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037133219462D+10 ISTATE -1: Reducing time step to 20091562306.143318 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037143155437D+10 ISTATE -1: Reducing time step to 20091334432.932369 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.8037151917220D+10 ISTATE -1: Reducing time step to 20091133488.320671 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.5195087796204D+11 ISTATE -1: Reducing time step to 348380717389.52661 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6040955475817D+11 R2 = 0.1096779129307D-07 ISTATE -5 - shortening step at time 1911.6947708282948 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6041587124232D+11 R2 = 0.1362499960324D+02 ISTATE -5 - shortening step at time 1911.8946595671098 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6042140087360D+11 R2 = 0.2138495319862D-04 ISTATE -5 - shortening step at time 1912.0696478987077 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6042913765509D+11 R2 = 0.1545026632908D-05 ISTATE -5 - shortening step at time 1912.3144827561578 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6043536756342D+11 R2 = 0.1193062721983D+02 ISTATE -5 - shortening step at time 1912.5116317538477 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6044248578155D+11 R2 = 0.4475434455206D-06 ISTATE -5 - shortening step at time 1912.7368918211218 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6044868855065D+11 R2 = 0.4039665118968D+01 ISTATE -5 - shortening step at time 1912.9331819825004 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6045482109501D+11 R2 = 0.2470307575126D+02 ISTATE -5 - shortening step at time 1913.1272498421019 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6046206656054D+11 R2 = 0.4951416476650D+01 ISTATE -5 - shortening step at time 1913.3565367260758 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6046908034337D+11 R2 = 0.4834354483672D-05 ISTATE -5 - shortening step at time 1913.5784918786464 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6735356228474D+11 R2 = 0.8858300932160D-07 ISTATE -5 - shortening step at time 2131.4418444537359 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6768986549635D+11 R2 = 0.4972428848123D+03 ISTATE -5 - shortening step at time 2142.0843511504690 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.9796556989366D+11 R2 = 0.1121741282765D-06 ISTATE -5 - shortening step at time 3100.1762624577013 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.9807246937832D+11 R2 = 0.2629368625177D-05 ISTATE -5 - shortening step at time 3103.5591575416397 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.9822832218142D+11 R2 = 0.5999469556134D-05 ISTATE -5 - shortening step at time 3108.4912082727615 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1428810335213D+12 R2 = 0.1763857944883D-05 ISTATE -5 - shortening step at time 4521.5516937117736 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1429812724701D+12 R2 = 0.1279821046433D-04 ISTATE -5 - shortening step at time 4524.7238123463439 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1432422025451D+12 R2 = 0.8682128241857D-05 ISTATE -5 - shortening step at time 4532.9810931994289 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1570712776519D+12 R2 = 0.1684043996923D+02 ISTATE -5 - shortening step at time 4970.6100522759943 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2089146231981D+12 R2 = 0.5216511058888D-06 ISTATE -5 - shortening step at time 6611.2222531056550 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2298507996836D+12 R2 = 0.1849543502211D-05 ISTATE -5 - shortening step at time 7273.7594836584376 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3363061657728D+12 R2 = 0.2246473289700D+02 ISTATE -5 - shortening step at time 10642.600182683222 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3363484301836D+12 R2 = 0.1864169437358D-04 ISTATE -5 - shortening step at time 10643.937664037679 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3699085863206D+12 R2 = 0.1034635565903D-05 ISTATE -5 - shortening step at time 11705.967921539310 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3699310381546D+12 R2 = 0.3862635638749D-05 ISTATE -5 - shortening step at time 11706.678422614965 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3699802870764D+12 R2 = 0.1157816627559D+03 ISTATE -5 - shortening step at time 11708.236932797194 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4069067970558D+12 R2 = 0.1954884075554D+02 ISTATE -5 - shortening step at time 12876.797375183369 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.4475689178433D+12 R2 = 0.1952240924551D-05 ISTATE -5 - shortening step at time 14163.573349470491 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.6552342432946D+12 R2 = 0.2379055386293D-06 ISTATE -5 - shortening step at time 20735.260863752770 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.7207282214195D+12 R2 = 0.2278018242460D+01 ISTATE -5 - shortening step at time 22807.855108211104 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.7207345716343D+12 R2 = 0.2563922774861D-05 ISTATE -5 - shortening step at time 22808.056064375985 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.8720640307390D+12 R2 = 0.3353640639289D-06 ISTATE -5 - shortening step at time 27596.962998069492 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1160689207256D+13 R2 = 0.4116720807359D-06 ISTATE -5 - shortening step at time 36730.671115680387 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1184080221495D+13 R2 = 0.3700473970204D+04 ISTATE -5 - shortening step at time 37470.893085285461 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1276764945468D+13 R2 = 0.1484349207984D-06 ISTATE -5 - shortening step at time 40403.953970503419 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1404431931998D+13 R2 = 0.9187909582311D-07 ISTATE -5 - shortening step at time 44444.048480947684 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1404440601902D+13 R2 = 0.1737218177251D-05 ISTATE -5 - shortening step at time 44444.322844988128 years At current T(=R1), MXSTEP(=I1) steps
taken on this call before reaching TOUT.
In the above message, I1 = 10000 In the above message, R1 = 0.1469844109525D+13 ISTATE -1: Reducing time step to 348860668800361.06 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1699348452297D+13 R2 = 0.1296189198438D+01 ISTATE -5 - shortening step at time 53776.849756219926 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.1869285763716D+13 R2 = 0.2794009520411D-07 ISTATE -5 - shortening step at time 59154.612775811620 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2056206828138D+13 R2 = 0.1255629511748D-06 ISTATE -5 - shortening step at time 65069.836333466737 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2521374357026D+13 R2 = 0.1365919764344D+04 ISTATE -5 - shortening step at time 79790.327753979582 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2736797882568D+13 R2 = 0.6336836556578D-06 ISTATE -5 - shortening step at time 86607.527929365460 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.2736802428263D+13 R2 = 0.9641643849776D-06 ISTATE -5 - shortening step at time 86607.671780484976 years At T(=R1) and step size H(=R2), the
corrector convergence failed repeatedly
or with ABS(H) = HMIN.
In the above message, R1 = 0.3010476630837D+13 R2 = 0.3394451027001D+01 ISTATE -5 - shortening step at time 95268.247811304143 years

model_table[["Result", "Dissipation Time"] + out_species] = results
model_table
shock_velocitydensityoutputFileResultDissipation TimeCOH2OCH3OH
010.010000.0../grid_folder/shocks/10.0_10000.0.csv0.01171.8987345.973692e-052.390674e-052.573049e-11
130.010000.0../grid_folder/shocks/30.0_10000.0.csv0.01171.8987342.502361e-052.420695e-059.976796e-07
250.010000.0../grid_folder/shocks/50.0_10000.0.csv0.01171.8987341.339461e-051.069392e-055.981371e-07
310.0100000.0../grid_folder/shocks/10.0_100000.0.csv0.0117.1898731.233292e-071.140102e-091.453093e-11
430.0100000.0../grid_folder/shocks/30.0_100000.0.csv0.0117.1898731.146282e-221.279723e-201.181856e-20
550.0100000.0../grid_folder/shocks/50.0_100000.0.csv0.0117.1898731.252981e-231.076729e-211.259819e-21
610.01000000.0../grid_folder/shocks/10.0_1000000.0.csv0.011.7189873.743088e-276.926607e-231.151194e-22
730.01000000.0../grid_folder/shocks/30.0_1000000.0.csv0.011.7189872.389471e-291.420828e-231.372137e-23
850.01000000.0../grid_folder/shocks/50.0_1000000.0.csv0.011.7189874.851176e-292.837123e-233.136032e-23

Summary​

There are many ways to run grids of models and users will naturally develop their own methods. This notebook is just a simple example of how to run UCLCHEM for many parameter combinations whilst producing a useful output (the model_table) to keep track of all the combinations that were run. In a real script, we'd save the model file to csv at the end.

For much larger grids, it's recommended that you find a way to make your script robust to failure. Over a huge range of parameters, it is quite likely UCLCHEM will hit integration trouble for at least a few parameter combinations. Very occasionally, UCLCHEM will get caught in a loop where it fails to integrate and cannot adjust its strategy to manage it. This isn't a problem for small grids as the model can be stopped and the tolerances adjusted. However, for very large grids, you may end up locking all threads as they each get stuck on a different model. The best solution we've found for this case is to add a check so that models in your dataframe are skipped if their file already exists, this allows you to stop and restart the grid script as needed.