File Exchange

image thumbnail

Sensitivity Analysis for ODEs and DAEs

version 1.2 (230 KB) by

Solves ODE/DAE systems (as ODE15s solver) and studies dependence of solutions wrt parameters.

13 Downloads

Updated

View License

The zip file contains
1) The two m-files, SENS_IND and SENS_SYS.
2) Four MATLAB 5.3 files which are not in Matlab R 6.1 and may be called from SENS_SYS and SENS_IND:
ntrp15s.m, odezero.m, icdae.m, icsdae.m.
3)The file Description.pdf, which explains how to use the functions and gives a short overview of the algorithms.
Both m-files SENS_IND and SENS_SYS have been created as modifications of the ODE15s MATLAB ODE/DAE solver (in fact, have been written "over" it ) so that apart from solving the system, approximate the derivatives of the solution with respect to some parameter(s).
SENS_IND and SENS_SYS use different algorithms for the same task (see the Description.pdf file for small overview).
In the pdf file, you can find as well two examples, one to show the available features and other showing how to use these functions to solve simple BVPs by "single shooting" (The functions have many more possible uses: parameter identification, multiple shooting, small optimal control problems, ...)

The four MATLAB 5.3 files may be set just in the same directory of SENS_IND and SENS_SYS, if you have
MATLAB 6.*

Please, e-mail us if you have any comment or find problems.

Comments and Ratings (8)

Guan Wang

I cannot get the version to work that uses odeset, I followed the pdf and tried this version.

opt = odeset(’AbsTolf’,1e-8,’RelTol’,1e-8,’Vectorized’,’on’);
[tn,yn,dydu]=sens_sys('gasoil',0:0.1:4,[1 ;0],opt,[0.9875;0.2566;0.3323],1);

I get the following error:
Error using odeget (line 74)
Unrecognized property name 'MassConstant'. See ODESET for possibilities.
Error in sens_sys (line 349)
Mconstant = odeget(options,'MassConstant');

Vaibhav

Works fine. Is it possible to pass extra parameter in the ODEFUN file? At present it accepts only quotes ('ODEFUN') form. Is it possible to use @ODEFUN format. In the later, we can manipulate the number of inputs, which is generally required in optimization.

Edo Ab

Very useful. However, I would add more into the description file even if it means adding descriptions of ODE solvers and sensitivity analysis the writer finds a prerequisite.

Faisal javed

can ode45 be used for nonlinear odes solution (e.g 2 DOf gyroscopes)

Alaa El -din Kadib

Please send me information about sensitivity analysis and finite differences.

MJ Major

Certainly helpful; offered a much needed ODE solver which had been discarded.

John Hedengren

A much needed tool for modellers to appropriately understant model uncertainty.

Updates

1.2

Old versions of the odeset.m and odeget.m functions have been included in the zip file, because in recent Matlab versions these functions have been changed, and do not work properly with sens_sys.m and sens_ind.m

1.0

update for bsd license

Errors in the m-files The vectorization option was active,
while the default is inactive;
Also some minor mistakes in the description file, and it seems
that there were some symbols that did not print correctly.

MATLAB Release
MATLAB 5.3 (R11)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Win prizes and improve your MATLAB skills

Play today