From b4826c9b9c2c28b0d5eddce7ae8a87c2b1610167 Mon Sep 17 00:00:00 2001 From: Ray Speth Date: Mon, 16 Jun 2014 22:00:30 +0000 Subject: [PATCH] [Matlab/Reactor] Use 'nonorm' when setting mass fractions --- interfaces/matlab/toolbox/conhp.m | 3 ++- interfaces/matlab/toolbox/conuv.m | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/interfaces/matlab/toolbox/conhp.m b/interfaces/matlab/toolbox/conhp.m index d5b5f5b7f..8789573bb 100755 --- a/interfaces/matlab/toolbox/conhp.m +++ b/interfaces/matlab/toolbox/conhp.m @@ -8,7 +8,8 @@ function dydt = conhp(t,y,gas,mw) %#ok % Set the state of the gas, based on the current solution vector. -set(gas, 'T', y(1), 'P', pressure(gas), 'Y', y(2:end)); +setMassFractions(gas, y(2:end), 'nonorm'); +set(gas, 'T', y(1), 'P', pressure(gas)); % energy equation wdot = netProdRates(gas); diff --git a/interfaces/matlab/toolbox/conuv.m b/interfaces/matlab/toolbox/conuv.m index 8b060881b..276f89e58 100755 --- a/interfaces/matlab/toolbox/conuv.m +++ b/interfaces/matlab/toolbox/conuv.m @@ -8,7 +8,8 @@ function dydt = conuv(t,y,gas,mw) %#ok % Set the state of the gas, based on the current solution vector. -set(gas, 'T', y(1), 'Rho', density(gas), 'Y', y(2:end)); +setMassFractions(gas, y(2:end), 'nonorm'); +set(gas, 'T', y(1), 'Rho', density(gas)); nsp = nSpecies(gas); % energy equation