oldmod_mod.f
43 lines · 1 definitions · on GitHub (7be4133)
Python version: oldmod_mod.py, 28 lines, on the right (switch to Python above the code).
Purpose
OLDMOD_MOD holds the model at the start of the step (the "old" model): its structure, composition, effective temperature, and surface luminosity, shared by 17 routines. It replaces COMMON/OLDMOD/ (MHP via Claude, 10/14/26); JSON comes from DIMENSIONS_MOD.
What its variables hold, who sets them, who reads them.
HPO,HTO,HRO,HLO,HDO(JSONeach): $\log P$, $\log T$, $\log r$, $L$ and $\log\rho$ of the old model. Saved byHPOINT(when it remaps the model onto a new grid, interpolating them withOSPLIN), by the main program ("save old model for PTIME") and bySTARIN. Read byPTIME(the time step from the structure changes),MIDMOD(interpolation within the step),LIRATE88(the old rates) andLIBURN,LIBURN2.HCOMPP(15,JSON): the old composition, saved by the main program, HPOINT,GETWandBURSMIX; read by the burning routines (KEMCOM,EQBURN,DBURN,DBURNM, LIRATE88), MIDMOD,CHECKCandCRRECT.HSS(JSON): the old mass coordinates, against which HPOINT interpolates (and the new grid while HPOINT builds it).LCO,LCZO(JSONeach): the old convective flags, saved by HPOINT (LCZOalso by STARIN);LCOis read by MIDMOD,LCZObyCRRECT, which passes it toGETROT.TEFFLO,HLSURO: the old $\log T_\mathrm{eff}$ ("JVS 04/14") and surface luminosity, saved by the main program, HPOINT (before it remaps the model) and STARIN; read byENTIME, which compares them with the new model.
Design
A blanket USE OLDMOD_MOD. HPOINT also uses HPO, HTO and HDO as scratch arrays ("note HDO is being used as a dummy array here"), so between HPOINT and the next save they do not hold the old model. At rp_1, MIX and SECULR also declared the block without using it; they no longer do.
Definitions
moduleOLDMOD_MOD
Uses modules DIMENSIONS_MOD
Change log
The changes since rp_1
Changed since rp_1. New file: COMMON/OLDMOD/ as a module (two unused declarations dropped).
Changed since a8a5950. The point count MO is replaced by HLSURO, the old model's surface luminosity, which is what ENTIME needs: HLO(MO) was not the surface once HPOINT had changed the number of points. Since CRRECT passes LCZO to GETROT (crrect.f changed, not this file), LCZO is read, which settles former question 1.