4.5

4.5 | 4 ratings Rate this file 7 Downloads (last 30 days) File Size: 16.55 KB File ID: #9904
image thumbnail

ODE Progress Bar and Interrupt

by Tim Franklin

 

06 Feb 2006 (Updated 19 May 2006)

ODE integration progress bar, interrupt control and estimated time to completion

| Watch this File

File Information
Description

This program displays a progress bar indicating where the ode integrator is in the specified time scale. The program allows the premature termination of an integration without loss of data. Ellapsed time and estimated time to completion are displayed below the integration bar.

This is very simple to add to existing code. Simply add the following to your ode options:
('OutputFcn',@odeprog,'Events',@odeabort)
and place the two files in the same directory as the running program.

A progress bar will display on the far left of your screen. Pressing the 'ABORT' button prematurely exits the integration while retaining the data up to the point of termination.

An example implementation is included with the program (main.m)

Jesse Norris contributed to this work.

MATLAB release MATLAB 7.0.4 (R14SP2)
Other requirements Resolution of 1280x1024 or higher recommended
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (4)
22 Apr 2006 valery kiselev  
29 Oct 2009 Vappu Reijonen

Thank you, this program saved my day!

19 Mar 2010 Bryan

Thanks for this wonderful program. Really saved me from a lot of headache :)....

29 Jan 2011 Chen

Thank you for a very useful program.

However, there is a small "bug": the drawnow call should not be placed outside the if-else blocks of the main function. This causes significant computational overhead, despite the author's intention to avoid it by limiting the "refresh" to once in 0.5 seconds.

Please login to add a comment or rating.
Updates
19 May 2006

Minor improvements made

Tag Activity for this File
Tag Applied By Date/Time
differential equations Tim Franklin 22 Oct 2008 08:14:52
simulation Tim Franklin 22 Oct 2008 08:14:52
status Tim Franklin 22 Oct 2008 08:14:52
bar Tim Franklin 22 Oct 2008 08:14:52
ode Tim Franklin 22 Oct 2008 08:14:52
progress Tim Franklin 22 Oct 2008 08:14:52
interrupt Tim Franklin 22 Oct 2008 08:14:52
abort Tim Franklin 22 Oct 2008 08:14:52
terminate Tim Franklin 22 Oct 2008 08:14:52

Contact us at files@mathworks.com