我用fortran调用refprop,用的subroutine TPFLSH (t,p,z,D,Dl,Dv,x,y,q,e,h,s,cv,cp,w,ierr,herr),将计算后得到的焓除以摩尔质量wm=WMOL(z),得到kJ/kg,但与安装的nist软件测得值对比。单工质两者相同,多组分工质两者就有大的差异比如差17kJ/kg。多工质为甲烷和乙烷,摩尔分数为0.93和0.07。求帮助。

program ex
  implicit none
  integer,parameter          ::ncomp=2
  character(len=255)         ::hfiles(ncomp),hfmix,herr
  character(len=3)           ::hrf
  integer                    ::ierr
  real(kind=8)               ::t,p,D,Dl,Dv,q,e,h,s,cv,cp,w
  real(kind=8)               ::z(ncomp),x(ncomp),y(ncomp)
  real(kind=8)               ::wm
  real(kind=8),external      ::WMOL

  hfiles(1)="fluids\METHANE.FLD" 
  hfiles(2)="fluids\ETHANE.FLD" 
  hfmix="fluids\hmx.bnc"
  hrf="DEF"

  t=352.0 
  p=15000.0
  z=(/0.93,0.07/)

  call SETUP(ncomp,hfiles,hfmix,hrf,ierr,herr)
  if(ierr .ne. 0)then
    write(*,*)herr
  end if

  call TPFLSH(t,p,z,D,Dl,Dv,x,y,q,e,h,s,cv,cp,w,ierr,herr) 
  if(ierr .ne. 0)then
    write(*,*)herr
  end if
  wm=WMOL(z) 


  write(*,*)"比焓:",h,"J/mol"
  write(*,*)"比熵:",s,"J/(mol.K)"

  write(*,*)"摩尔质量:",wm,'g/mol'

end program