uclchem / UCLCHEM

UCLCHEM - A gas-grain chemical code for Astrochemistry.
MIT License
29 stars 14 forks source link

Models have occassional final time step truncation #11

Closed tomasjames closed 4 years ago

tomasjames commented 4 years ago

Occassional models, when run with grid.py, have their final time step truncated such that the abundance of some molecules is not written out.

This is leading to errors when plotting these abundances as a function of time, as the array dimensions do not match (i.e. python is able to find the time step for that entry, but not the molecular abundance as it has been truncated).

jonholdship commented 4 years ago

Bug fixed! Added close statements to wrap.f90, writing to file is completed before file is closed and so no truncation occurs.