intvar_mod.f
40 lines · 1 definitions · on GitHub (7be4133)
Python version: intvar_mod.py, 28 lines, on the right (switch to Python above the code).
Purpose
INTVAR_MOD holds the structure variables at the interfaces between shells (the midpoints in radius), for the rotation routines, shared by SETUPV, VCIRC, GETFC and SECULR. It replaces COMMON/INTVAR/ (MHP via Claude, 10/14/26); JSON comes from DIMENSIONS_MOD. All members are arrays of JSON.
What its variables hold, who sets them, who reads them. All are set by SETUPV:
RM: the radius of the interface between shellsI-1andI, the mean of the two shells' radii.- At each interface, by four-point Lagrangian interpolation in radius (the first and last interfaces from the first and last four points):
PM,TM,DM($P$, $T$, $\rho$, unlogged),ALM($L$, cgs),HS3(the mass),HGM(gravity),DELMI,DELAMI(the radiative and adiabatic gradients),QDTMI(a thermodynamic derivative),EPSILM(the energy generation rate). SETUPVuses them to build the circulation coefficients;VCIRCreadsRM,HGM,ALM;GETFCreadsRM,DM;SECULRreadsRM.
Design
A blanket USE INTVAR_MOD. At rp_1, CODIFF also declared the block without using it.
Definitions
moduleINTVAR_MOD
Uses modules DIMENSIONS_MOD
Change log
The changes since rp_1
Changed since rp_1. New file: COMMON/INTVAR/ as a module (CODIFF's unused declaration dropped).