thcl.f
function thcl(temp)
c
c function thcl evaluates the freon liquid thermal conductivity
c as a function of liquid enthalpy
c
c liquid temperature temp in (j/kg)
c thermal conductivity thcl in (w/m/k)
c
c
c
dimension tabl(4,26)
save ilast
data ilast/15/,ntab/26/
data tabl/
& 1.99826700E+02, 1.15267000E-01,-3.03660304E-04, 6.96601393E-07,
& 2.10937800E+02, 1.11979000E-01,-2.88180288E-04, 6.96601393E-07,
& 2.22048900E+02, 1.08863000E-01,-2.72700273E-04,-6.88501377E-07,
& 2.33160000E+02, 1.05748000E-01,-2.88000288E-04, 6.88501377E-07,
& 2.44271100E+02, 1.02633000E-01,-2.72700273E-04,-6.96601393E-07,
& 2.55382200E+02, 9.95170000E-02,-2.88180288E-04, 7.04701409E-07,
& 2.66493300E+02, 9.64020000E-02,-2.72520273E-04,-7.04701409E-07,
& 2.77604400E+02, 9.32870000E-02,-2.88180288E-04, 6.96822277E-07,
& 2.88715600E+02, 9.01710000E-02,-2.72695225E-04,-6.88955687E-07,
& 2.99826700E+02, 8.70560000E-02,-2.88005336E-04, 6.88955687E-07,
& 3.10937800E+02, 8.39410000E-02,-2.72695225E-04,-6.97055703E-07,
& 3.22048900E+02, 8.08250000E-02,-2.88185336E-04, 7.05155719E-07,
& 3.33160000E+02, 7.77100000E-02,-2.72515225E-04,-7.05155719E-07,
& 3.44271100E+02, 7.45950000E-02,-2.88185336E-04, 6.97055703E-07,
& 3.55382200E+02, 7.14790000E-02,-2.72695225E-04,-6.88955687E-07,
& 3.66493300E+02, 6.83640000E-02,-2.88005336E-04, 6.88955687E-07,
& 3.77604400E+02, 6.52490000E-02,-2.72695225E-04,-6.96822277E-07,
& 3.88715600E+02, 6.21330000E-02,-2.88180288E-04, 7.04701409E-07,
& 3.99826700E+02, 5.90180000E-02,-2.72520273E-04,-7.04701409E-07,
& 4.10937800E+02, 5.59030000E-02,-2.88180288E-04, 6.96601393E-07,
& 4.22048900E+02, 5.27870000E-02,-2.72700273E-04,-4.89240978E-06,
& 4.33160000E+02, 4.91530000E-02,-3.81420381E-04, 6.80401361E-07,
& 4.44271100E+02, 4.49990000E-02,-3.66300366E-04,-6.28561257E-06,
& 4.55382200E+02, 4.01530000E-02,-5.05980506E-04,-2.45592491E-05,
& 4.66493300E+02, 3.14990000E-02,-1.05174105E-03,-2.18924207E-04,
& 4.70937800E+02, 2.25000000E-02, 0.00000000E+00, 0.00000000E+00/
x=temp
c Start the search from the last point of table use index
c
if (x.le.tabl(1,ilast+1)) then
c
c Search down the table from point of last use
c
do 20 i1=ilast,1,-1
if(x.ge.tabl(1,i1)) go to 60
20 continue
c write(6,*) 'x = ', x, ' is below the table range'
i1=1
go to 60
else
c
c Search up the table from point of last use
c
do 40 i1=ilast+1,ntab-1
if(x.le.tabl(1,i1+1)) go to 60
40 continue
c write(6,*) 'x = ', x, ' is above the table range'
i1=ntab-1
go to 60
endif
c
c Bounding points found, interpolate
c
60 dx=(x-tabl(1,i1))
thcl=tabl(2,i1)+tabl(3,i1)*dx+tabl(4,i1)*dx**2
ilast=i1
120 continue
return
end