Jump to content

Using Scilab ODE solver

Featured Replies

This might be a dumb question but when solving ODE's with scilab and you set the independent variable points at which you want to evaluate, what is the middle number used for in t = 0:0.1:5 for the example:

 

function dx = f ( t , x )

dx = sin (2 t ) ;

endfunction

 

t0 = 0

x0= -0.5

t=0:0.1:5;

x = ode(x0, t0, t, f);

plot2d(t, x)

 

Here's the link for the example: http://scilab.in/files/workshops/15-04-2010-mumbai/sengupta-ode.pdf

 

 

Thanks for the help!

This might be a dumb question but when solving ODE's with scilab and you set the independent variable points at which you want to evaluate, what is the middle number used for in t = 0:0.1:5 for the example:

 

Like in Matlab, that command will create a vector t with values from zero to 5 with stepsize 0.1, i.e.

 

t = [0, 0.1, 0.2, 0.3, .... 4.8, 4.9, 5.0].

Archived

This topic is now archived and is closed to further replies.

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.