function result = fH(H,T,MflowN2,MflowH2,MflowNH3,FeedAr,FeedCH4,CpCoef)
result = H - (MflowN2*HtCap(1,T,CpCoef)+MflowH2*HtCap(2,T,CpCoef) ...
    +MflowNH3*HtCap(3,T,CpCoef)+FeedAr*HtCap(4,T,CpCoef) ...
    +FeedCH4*HtCap(5,T,CpCoef))*T;

