Scaled VAL models database ========================== scaling of temperature - parameter tp scaling of column mass - parameter mp tp=-0.03+k*0.001 k=0-60; 61 values in the range -0.03,...,0,...,0.03 mp= 0.2+j*0.1 j=0-48; 49 values in the range 0.2,...,1,...,5 original initial VAL models correspond to tp=0 (k=30) and mp=1 (j=8) Each initial VAL model is scaled in the following order: for k=0,60 do begin ; tp loop for j=0,48 do begin ; mp loop tp=-0.03+k*0.001 mp= 0.2+j*0.1 model[VAL,j*k]=scaling(VAL,tp,mp) endfor endfor Each initial VAL model is scaled to 49*61=2989 versions. The original initial VAL model is at the position k=30, j=8, i.e., 49*30+8 = 1478 of the range 0--2988. The synthetic profiles are ordered in the same way as the models, i.e., they have the same ID number = 49*k+j. ---------------------------------------------------- Retrieval of tp, mp from ID number: k = ID/49 j = ID mod 49 tp = -0.03+k*0.001 = -0.03+(ID/49)*0.001 mp = 0.2+j*0.1 = 0.2+(ID mod 49)*0.1 Retrieval of ID number from tp, mp: k = fix((tp+0.03)*1000) j = fix((mp-0.2)*10) ID = 49*k+j, that is, ID = 49*fix((tp+0.03)*1000)+fix((mp-0.2)*10) ------------------------------------------------------ Some scaled models did not converge and contain NaNs Each directory contains 2989 scaled VAL models A--F, from 'MODEL_INP00000.DAT' to 'MODEL_INP02988.DAT', where 'MODEL_INP1478.DAT' is the initial VAL model. Files in the directories VAL_? contain 8 columnms --------------------------------------------------------- id, m, T, v_t, n_el, rho, z, tau_500 [cgs units] m = column mass, T = temperature, v_t = microturbulence, n_el = electron density, rho = gas density, z = geom.depth, tau_500 = optical depth --------------------------------------------------------- and 103 rows. z [cm] increases from top (0) to bottom. ---------------------------------------- The conversion of z to geometrical height h (km, 0 at tau_500=1) is for i=0,102 do h[i] = (z[102]-7.5e6-z[i])/1.e5, because tau_500=1 is near 7.5e6 cm (75 km) in all models. Calculation of gas pressure Pg ------------------------------ Total pressure Pt in hydrostatic equilibrium: dPt/dm = g --> Pt(m) = gm + Pt(0), g = 27398 cm/s^2, Pt(0) set to 0 Pg = Pt - Pturb = Pt - 1/2*rho*v_t^2 -------------------------------------------------------------------- READ_MODEL_ID.PRO PRO read_model_id,init_model,id,modin,flag ; ; Reading scaled models and calculation of geometrical height h [km] ; and pressures Pt (total), Pg (gas). ; All quantities, except h [km], are in cgs units. ; ; INPUT: ; init_model (string) in the form 'C' defines the folder name ; id (integer) - ID number of the model in the folder 'VAL_'+init_model ; ; OUTPUTS: ; modin - model array DOUBLE(10,103) ; ------------------------------ ; [h,m,T,vt,nel,rho,Pg,Pt,z,tau] ; ------------------------------ ; flag = 1 when the model is ok, flag = 0 when the model contains NaN READ_MODEL_TM.PRO PRO read_model_tm,init_model,tp,mp,modin,flag ; ; Reading scaled models and calculation of geometrical height h [km] ; and pressures Pt (total), Pg (gas). ; All quantities, except h [km], are in cgs units. ; ; INPUT: ; init_model (string) in the form 'C' defines the folder name ; 'VAL_'+init_model ; tp - temperature parameter in the range -0.03 to 0.03 ; mp - column-mass parameter in the range 0.2 to 5 ; ; OUTPUTS: same as read_model_id.pro