Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed
arrows point from an interface to procedures which implement that interface.
This could include the module procedures in a generic interface or the
implementation in a submodule of an interface in a parent module.
Source Code
subroutine findT(tpoint,Ypoint,fl)! Fast search option to find correct temperature ! from temporal evolution function. Only possible this way because T is a monotonously! decreasing function for the interpolated tables! Uses eq. A7 from Townsend 2009 for piecewise power lawsdouble precision,intent(OUT)::tpointdouble precision,intent(IN)::Ypointtype(rc_fluid),intent(in)::fldouble precision::factorinteger::jl,jc,jh,iif(Ypoint>=fl%Yc(1))thentpoint=fl%tcoolminelse if(Ypoint==fl%Yc(fl%ncool))thentpoint=fl%tcoolmaxelsejl=0jh=fl%ncool+1do if(jh-jl<=1)exitjc=(jh+jl)/2if(Ypoint<=fl%Yc(jc))thenjl=jcelsejh=jcend if end do! Linear interpolation to obtain correct temperaturetpoint=fl%tcool(jl)+(Ypoint-fl%Yc(jl))&*(fl%tcool(jl+1)-fl%tcool(jl))&/(fl%Yc(jl+1)-fl%Yc(jl))end if end subroutine findT