write(>input.htm,  ****************************************************)
write(>>input.htm, )
write(>>input.htm, )
write(>>input.htm, 
)
write(>>input.htm,  SPELLOUT is the Q1-to-plain-English interpreter.)
write(>>input.htm,  If INCLuded at the end of the Q1 file or in the Q2 it)
write(>>input.htm,  analyses the settings made in the Q1) 
write(>>input.htm,  and reports its findings to the file input.htm. )
write(>>input.htm, )
write(>>input.htm, vredit = :vredit:)
  if(vredit.eq.t) then
  write(>>input.htm, It requires VREDIT=F at the top of the Q1 file)
  write(>>input.htm, in order to read and recount all the settings.)
  endif
write(>>input.htm,  ****************************************************)
write(>>input.htm,     ***  input of main problem-defining data ***)
write(>>input.htm, )
write(>>input.htm,  ****************************************************)
write(>>input.htm, )
write(>>input.htm,  The title is  :TITLE:) 
write(>>input.htm, )

if(steady) then
write(>>input.htm, scenario is steady-state)
else
write(>>input.htm, scenario is transient with :LSTEP: time steps and total time=:TLAST:)
endif              
write(>>input.htm,  grid settings)

IF(BFC) THEN
+  write(>>input.htm )
+  write(>>input.htm,  The grid is body-fitted)
ELSE
+  IF(CARTES) THEN
+    write(>>input.htm,  )
+    write(>>input.htm,  The grid is cartesian )
+  ELSE
+    write(>>input.htm,  The grid is cylindrical-polar )
+  ENDIF
ENDIF

write(>>input.htm, )
write(>>input.htm,  The geometrical size of the domain is...)
write(>>input.htm,  x-direction dimension = :xulast:, NX = :nx:, NREGX = :nregx:)
write(>>input.htm,  y-direction dimension = :yvlast:, NY = :ny:, NREGY = :nregy:)
write(>>input.htm,  z-direction dimension = :zwlast:, NZ = :nz:, NREGZ = :nregz:)
write(>>input.htm,  ****************************************************)
write(>>input.htm, )
INTEGER(NUMOBJ)
RSET(G,N,NUMOBJ)
write(>>input.htm, )
write(>>input.htm,  The number of objects is :numobj-1:)
 write(>>input.htm, )
  write(>>input.htm,  ****************************************************)
 write(>>input.htm,  special features.)
 write(>>input.htm, )
 write(>>input.htm, SPPNAM=:sppnam: egwf = :egwf: parsol = :parsol: stra = :stra:)
 write(>>input.htm, selref = :selref: resfac = :resfac: expert = :expert:)
 write(>>input.htm, readq1 = :readq1: conwiz = :conwiz: usp = :usp:)
write(>>input.htm, )
if(conwiz) then
write(>>input.htm,convergence wizard may alter relaxations etc.)
endif   
  write(>>input.htm,  Allowable number of  variables is NPHI, namely :NPHI:)
write(>>input.htm,  The names and index numbers of the solved-for)
write(>>input.htm,  dependent variables are as follows:-)
integer(idum1,idum2)
boolean(kesol,epsol,omsol,vossol,vosol,ltlsol,velcty)
real(vrmndf,vrmxdf)
DO ii=1,NPHI
  ii
  idum1
idum1=:isln(ii):
idum2=idum1/3
  idum2
idum2=idum2*3
  idum2
IF(idum1.EQ.idum2 ) THEN ! variable is solved
velcty=ii.gt.2.and.ii.lt.9
if(velcty) then
vrmndf=-1.0e6; vrmxdf=1.0e6
else
vrmndf=-1.0e10; vrmxdf=1.0e10
endif

write(>>input.htm, ****************************************************)
  name(ii)
if(ii.eq.13) then
epsol=t
  write(>>input.htm, 13 is solved. sol is :epsol:)
endif

if(:ii:.eq.12) then
kesol=t
  write(>>input.htm, ke is solved for. sol is :kesol:)
endif

if(:name(ii):.eq.'OMEG') then
omsol=t
write(>>input.htm, omsol=:omsol:)
  mesg(omsol=:omsol:
endif

if(:name(ii):.eq.'VOSG') then
vossol=t
write(>>input.htm, vossol=:vossol:)
  mesg(vossol=:vossol:
endif

If(:name(ii):.eq.'LTLS') then
ltlsol=t
write(>>input.htm, ltlsol=:ltlsol:)
  mesg(ltlsol=:ltlsol:
endif
  
write(>>input.htm,   variable :name(ii): with index :ii: has the settings)
write(>>input.htm, )
IF(:FIINIT(ii):.EQ.-10220) THEN
 write(>>input.htm,  initial values will be obtained from a restart file) 
ELSE
 write(>>input.htm,  whole-field initial value          = :fiinit(ii):)
ENDIF

IF(ii.GT.2.and enut.eq.0) then
write(>>input.htm,  laminar Prandtl number             = :prndtl(ii):)
ENDif
IF(ii.GT.2.AND.ENUT.NE.0.0) THEN
write(>>input.htm,   laminar & turbulent Prandtl numbers   = :prndtl(ii): & :prt(ii):)
ENDIF
write(>>input.htm,  iteration number in solver         = :liter(ii):)
IF(:ENDIT(ii):.LT.0) THEN
write(>>input.htm,  over-relaxation factor in solver   = :-endit(ii):)
ENDIF
  relaxation
IF(:DTFALS(ii):.GT.0) THEN
write(>>input.htm,  false-time-step relaxation factor  = :dtfals(ii):)
ELSE
write(>>input.htm,  linear relaxation factor           = :-dtfals(ii):)
ENDIF
  maxmin
if(:varmin(ii):.ne.vrmndf.and.:varmax(ii):.ne.vrmxdf) then
write(>>input.htm,minimum and minimum settings are :varmin(ii): and :varmax(ii): )
endif
IF(.NOT.SELREF) THEN
write(>>input.htm,  residual for solution cut-off      = :resref(ii):)
ENDIF
IF(:ISLN(ii)/5*5:.EQ.:ISLN(ii):) THEN
write(>>input.htm,                whole-field solver is activated )
ELSE
write(>>input.htm,                whole-field solver is NOT activated)
ENDIF
IF(NAME(ii).EQ.BLOK) THEN
write(>>input.htm,  block-correction feature is active)
ENDIF
ENDIF
enddo
   turbulence models
if(enut.lt.0.0) then
if(kesol) then
 if(epsol) then 
+ write(>>input.htm, turbulence model is k~epsilon)
 endif
 if(vossol) then 
+ write(>>input.htm, turbulence model is k~vorticity-squared)
 endif
 if(vosol) then
+ write(>>input.htm, turbulence model is k~vorticity)
 endif

else
  ltlsol
enut
 if(ltlsol) then
 if(enut.eq.grnd8) then 
+ write(>>input.htm, turbulence model is lvel)
 else
+ write(>>input.htm, turbulence model is mixing-length)
 endif
 endif
endif
endif

CHAR(CNT,fx,lx,fy,ly,fz,lz,ft,ltt,ct1,ct2,ct3,ct4)
INTEGER(IT1,IT2,ll)
REAL(RT1,RT2)
boolean(b1,b2,b3)
b1=f;b2=f;b3=f
write(>>input.htm,  ****************************************************)
write(>>input.htm,  SPEDAT information)
spedat(getv,output,nofield,l,b1)
write(>>input.htm, NOFIELD is :b1:)
spedat(getv,automesh,old-x,l,b1)
spedat(getv,automesh,old-y,l,b2)
spedat(getv,automesh,old-z,l,b3)
write(>>input.htm, automesh old-x,-y,-z is :b1: :b2: :b3:)
write(>>input.htm,  ****************************************************)
write(>>input.htm, )
write(>>input.htm,  The variables stored but not solved are:-)
write(>>input.htm, )
char(namvar)
  mesg(about to start do 1,nphi =:nphi:
DO II=1,NPHI
  write(>>input.htm,ii=:ii:)
  ii
idum1=isln(:ii:)
idum2=idum1/2
idum2=idum2*2
  idum2
  write(>>input.htm, isln of :namvar: = :idum1:
IF(idum1.eq.idum2) THEN
idum1=:isln(ii):
idum2=idum1/3
idum2=idum2*3
IF(idum1.ne.idum2 ) THEN    ! stored but not solved
namvar=name(ii)
if(fiinit(ii).ne.(-10220)) then
  mesg(fiinit(ii)=:fiinit(ii):
CT2=:fiinit(ii):
else
ct2=is_restarted_with
endif  
ct3=relaxation_factor = :-dtfals(ii):
write(>>input.htm, :name(ii):, :ct2:, :ct3:)
ct1=stored; ct2=:name(ii):; ct3=NONE
spedat(getv,:ct1:,:ct2:,c,ct3)
if(:ct3:.ne.NONE)then
write(>>input.htm, InForm formula is :ct3:)
endif
endif
ENDIF
ENDDO

 
GTPARG(CHSO,N,CT1,IT1,CT2,IT2)
IF(:N:.ne.N) then
+  write(>>input.htm, )
+  write(>>input.htm,  For CHSO patch, parameters are :ct1:, :it1:, :ct2:, :it2:)
endif
 write(>>input.htm,  ****************************************************)
 write(>>input.htm,  Material property information....)
   Note that information should also be supplied about tmp1, cp1, 
                                                       len1, etc
  first-phase density
if(rho1.gt.0) then
 write(>>input.htm,  1st-phase fluid density RHO1 is a constant equal to :RHO1:)
endif
IF(RHO1.EQ.GRND1) THEN
+  write(>>input.htm,  phase-1 density = :rho1a: + :rho1b: * enthalpy)
ENDIF
IF(RHO1.EQ.GRND2) THEN
+  write(>>input.htm,  phase-1 density = 1.0 / (:rho1a: + :rho1b: * enthalpy)
ENDIF
IF(RHO1.EQ.GRND3) THEN
+  write(>>input.htm,  phase-1 density = :rho1a:*(p1+:press0:)**:rho1b:+:rho1c:)
ENDIF
IF(RHO1.EQ.GRND4) THEN
+  write(>>input.htm,  phase-1 density = :rho1a: + :rho1b: * temperature)
ENDIF
IF(RHO1.EQ.GRND5) THEN
+  write(>>input.htm,  phase-1 density = :rho1b:*(p1+:press0:)/temperature)
ENDIF
IF(RHO1.EQ.GRND6) THEN
+  write(>>input.htm,  phase-1 density = (p1+:press0:)*(molecular weight)/T1)
ENDIF
IF(RHO1.EQ.GRND) THEN
+  write(>>input.htm,  phase-1 density is computed from user's GROUND coding)
ENDIF
IF(RHO2.EQ.GRND2) THEN
+  write(>>input.htm,  phase-2 density = 1.0 / (:rho2a: + :rho2b: * enthalpy))
ENDIF

 write(>>input.htm,  Reference-viscosity information)
IF(ENUL.Ge.0) then
 write(>>input.htm,  the reference laminar viscosity ENUL is equal to :ENUL: )
ENDIF
IF(ENUL.Eq.grnd1) then
 write(>>input.htm,  reference laminar viscosity = :enula: + :enulb: * T1)
ENDIF
IF(ENUL.Eq.grnd2) then
 write(>>input.htm,  ref. laminar viscosity = :enula:+:enulb:*T1+enulc:*T1**2)
ENDIF
IF(ENUL.Eq.grnd3) then
 write(>>input.htm,  ref. laminar viscosity = :enula:+:enulb:*T1**:enulc:)
ENDIF
IF(ENUL.Eq.grnd4) then
 write(>>input.htm,  ref. laminar viscosity = :enula: * (strain rate)**2)
 write(>>input.htm,                                   * (:enulb:-1.0)/2.0)
ENDIF
IF(ENUL.Eq.grnd) then
 write(>>input.htm,  laminar viscosity is computed from user's GROUND coding)
ENDIF
IF(EL1.EQ.GRND3) THEN
+write(>>input.htm,  the length scale varies linearly with longitudinal distance)
+  write(>>input.htm,  l = :el1a: + :el1b: * z)
ENDIF 
write(>>input.htm,  Turbulent-viscosity information)
write(>>input.htm, )
if(walla.gt.0.0) then 
write(>>input.htm, roughness height taken everywhere as :walla:)
endif
IF(ENUT.GT.0.0) THEN
+  write(>>input.htm,  Boussinesq model: )
+  write(>>input.htm,Turbulent effective viscosity = :enut:)
ENDIF
IF(ENUT.EQ.GRND1) THEN
+  write(>>input.htm,  linear function of length = :enuta: + :enutb: * len1)
endif
IF(ENUT.EQ.GRND2) THEN
+  write(>>input.htm, Prandtl mixing-length formula)
+  write(>>input.htm,  Turbulent effective viscosity = len1**2*(k-generation rate)**0.5 )
ENDIF
IF(ENUT.EQ.GRND3) THEN
+  write(>>input.htm,  energy~length formula formula:)
+  write(>>input.htm,  Turbulent effective viscosity = CMU * len1 * k ** 0.5)
ENDIF
IF(ENUT.EQ.GRND4) THEN
+  write(>>input.htm, two-phase velocity-slip formula)
+  write(>>input.htm,   Turbulent effective viscosity = :enuta: * LEN1 * ABS(vel1-vel2))*r1*r2)
ENDIF
IF(ENUT.EQ.GRND5) THEN
+  write(>>input.htm,  k~epsilon formula)
+  write(>>input.htm,   Turbulent effective viscosity = CMU * k**1.5 / epsilon)
ENDIF
IF(ENUT.EQ.GRND6) THEN
+  write(>>input.htm,  ke~vorticity-squared formula)
+  write(>>input.htm,   Turbulent effective viscosity = CMU * (k/vosq) ** 0.5)
ENDIF
IF(ENUT.EQ.GRND7) THEN
+  write(>>input.htm,  ke~vorticity formula)
+  write(>>input.htm,   Turbulent effective viscosity = CMU * k**0.5 / vorticity)
ENDIF
IF(ENUT.EQ.GRND8) THEN
+  write(>>input.htm,  universal-wall-law formula)
+  write(>>input.htm,   turbulent effective viscosity depends on local Re)
ENDIF
 
IF(.NOT.ONEPHS) THEN
  write(>>input.htm,  ****************************************************)
 write(>>input.htm,  Two-phase information)
+  IF(CFIPS.LT.0.0) THEN
+    write(>>input.htm, >
+    write(>>input.htm,   CFIPS= :CFIPS:)
+    write(>>input.htm,   CFIPA= :CFIPA:; CFIPB= :CFIPB:; CFIPC= :CFIPC:; CFIPD=:CFIPD:)
+    write(>>input.htm, )
+    IF(CFIPS.EQ.GRND4) THEN
+      write(>>input.htm,   CFIPS=GRND4 selects FIP=CFIPC*M1*R2*)
+      write(>>input.htm,     (( max(relspeed,CFIPA) )**CFIPB) * ( EL1**CFIPD ))
+    ENDIF
+    IF(CFIPS.EQ.GRND5) THEN
+      write(>>input.htm,    CFIPS=GRND5 selects FIP=CFIPC*M2*R1*)
+      write(>>input.htm,     (( max(relspeed,CFIPA) )**CFIPB) * ( EL1**CFIPD ))
+    ENDIF
+    IF(CFIPS.EQ.GRND4.OR.CFIPS.EQ.GRND5) THEN
+      write(>>input.htm,   where M2 is the phase-2 mass in the cell,)
+      write(>>input.htm,         R1 is the phase-1 volume fraction.)
+    ENDIF
+  ENDIF
ENDIF
 write(>>input.htm,  ****************************************************)
 write(>>input.htm,  SOLVER PARAMETERS)
 IF(:CSG3:.EQ.CNGR) THEN
+ write(>>input.htm,  conjugategradient solver is in use )
 ELSE
+ IF(:CSG3:.EQ.GAUSS) THEN
+  write(>>input.htm,  GAUSS-SEIDEL solver is in use)
+ ELSE
+  write(>>input.htm,  Stone-type solver is in use)
+  write(>>input.htm,  isolbk = :isolbk: isolx  = :isolx: isoly  = :isoly:)
+  write(>>input.htm,  isolz  = :isolz:  ovrrlx = :ovrrlx: usolve = :usolve:)
+ ENDIF
 ENDIF

  information about patches
write(>>input.htm, )
write(>>input.htm,  Patch information)
IF(NUMPAT.GT.0) THEN
 DO II=1,NUMPAT
write(>>input.htm, )
 CT1=:NAMPAT(ii):
 CASE BUOY OF
 WHEN :CT1:,4
write(>>input.htm,  BUOYA,B,C,D = :buoya:, :BUOYB:, :buoyc:, :buoyd:)
 ENDCASE
 GTPARG(:CT1:,N,CT2,IT1,CT3,IT2)
IF(XXX:CT3:.EQ.XXX) THEN
write(>>input.htm,  Patch name =  :CT1:)
ELSE
write(>>input.htm,  Name =  :CT1:     type =   :CT3:)
ENDIF
GTPARG(:CT1:,X,CT3,IT1,CT2,IT2)
fx= :CT3::IT1: 
lx=  :CT2::IT2:
GTPARG(:CT1:,Y,CT3,IT1,CT2,IT2)
fy= :CT3::IT1: 
ly=  :CT2::IT2:
GTPARG(:CT1:,Z,CT3,IT1,CT2,IT2)
fz= :CT3::IT1: 
lz=  :CT2::IT2:
IF(.NOT.STEADY) THEN
GTPARG(:CT1:,T,CT3,IT1,CT2,IT2)
ft= :CT3::IT1: 
ltt=  :CT2::IT2:
write(>>input.htm, ixf&l, iyf&l, izf&l  :fx:,:lx:,:fy:,:ly:,:fz:,:lz:,:ft:,:ltt:)
else
write(>>input.htm, ixf&l, iyf&l, izf&l  :fx:,:lx:,:fy:,:ly:,:fz:,:lz:)
ENDIF

DO JJ=1,NPHI
GETCOV(:CT1:,JJ,RT1,RT2)
IF(RT1.NE.-999.) THEN
if(:rt1:.eq.'-0.123456') then
write(>>input.htm,  For variable :NAME(JJ):, In-Form source is provided)
else
write(>>input.htm,  For variable :NAME(JJ):, co & val are :RT1: & :RT2:)
endif
ENDIF
ENDDO ! end 1,nph1 loop
enddo ! end 1,numpat loop
ENDIF

IF(DEBUG) THEN
write(>>input.htm, )
write(>>input.htm,  ****************************************************)
write(>>input.htm,  debug information)
write(>>input.htm,  debug has been activated)
write(>>input.htm,  flag=:flag:)
write(>>input.htm,  dbrho=:dbrho:)
write(>>input.htm,  dbrm=:dbemu:)
write(>>input.htm,  dbgam=:dbgam:)
write(>>input.htm,  dbt=:dbt:)
write(>>input.htm,  
) ENDIF integer(numobj) rset(g,n,numobj) if(numobj.gt.1) then + write(>>input.htm, ) + write(>>input.htm,Information by object using objinfo command) + write(>>input.htm, Object 1 is the domain) + write(>>input.htm, number name type material geometry grid) + do ii=2,numobj + objinfo(name,ii,ct1) + objinfo(type,ii,ct2) + objinfo(material,ii,ct3) + if(:ct3:.ne.none) then + endif + objinfo(geometry,ii,ct4) + objinfo(grid,ii,ct5) + write(>>input.htm,:ii: :ct1: :ct2: :ct3: :ct4: :ct5:) + enddo endif + write(>>input.htm, ) if(numpat.gt.0) then + write(>>input.htm,Information by patch using objinfo command)) + write(>>input.htm,number name type material geometry) + do ii=1,numpat + objinfo(name,-ii,ct1) + if(:ct1:.ne.none) then + objinfo(type,-ii,ct2) + objinfo(material,-ii,ct3) + if(:ct3:.ne.none) then + endif + objinfo(geometry,-ii,ct4) + else write(>>input.htm,Patch :nampat(ii): is not generated by any object) + endif + write(>>input.htm,:ii: :ct1: :ct2: :ct3: :ct4: ) + enddo endif