[Matlab] Add fwdRateConstants and revRateConstants functions

Resolves Issue 125.
This commit is contained in:
Bryan W. Weber 2014-01-06 18:46:36 +00:00
parent 16335a0932
commit 120c6e742c
3 changed files with 24 additions and 0 deletions

View file

@ -0,0 +1,9 @@
function kf = fwdRateConstants(a)
%FWDRATECONSTANTS Forward reaction rate constants for all the reactions.
%
% kf = fwdRateConstants(a)
%
% Returns a column vector of the forward rate constants of
% all of the reactions.
%
kf = kinetics_get(a.id,15,0);

View file

@ -0,0 +1,9 @@
function kr = revRateConstants(a)
%REVRATECONSTANTS Reverse reaction rate constants for all the reactions.
%
% kr = revRateConstants(a)
%
% Returns a column vector of the reverse rate constants of
% all of the reactions.
%
kr = kinetics_get(a.id,16,0);

View file

@ -93,6 +93,12 @@ void kineticsmethods(int nlhs, mxArray* plhs[],
case 14:
ok = kin_getEquilibriumConstants(kin,nr,h);
break;
case 15:
ok = kin_getFwdRateConstants(kin,nr,h);
break;
case 16:
ok = kin_getRevRateConstants(kin,1,nr,h);
break;
default:
;
}