Here is a sample code:CAPE-OPEN error, caused by: in ICapeThermoMaterial::GetSinglePhaseProp of 'feed': no values set for heatCapacityCp, phase Vapor, CalcType mixture (2x)
Code: Select all
CAPEOPEN_1_2::CapeThermoMaterial foo;
foo = feed->getMaterial()
CapeArrayStringImpl phaseLabels;
CapeArrayEnumerationImpl<CAPEOPEN_1_2::CapePhaseStatus> phaseStatus;
foo.GetPresentPhases(phaseLabels, phaseStatus);
CapeArrayRealImpl Cp;
Cp.resize(phaseLabels.size());
for (ConstCapeString phaseLabel : phaseLabels) {
CapeArrayRealImpl phaseCp;
foo.GetSinglePhaseProp(ConstCapeString(COBIATEXT("heatCapacityCp")),
phaseLabel, ConstCapeString(COBIATEXT("mole")), phaseCp);
Cp.emplace_back(phaseCp[0]);
}