Quantcast
Channel: Latest Discussions - COMSOL Forums
Viewing all articles
Browse latest Browse all 26527

Simple example to solve ODE

$
0
0
Hi,

I am a complete newbie with COMSOL (I have the MultiPhysics module, version 4.3a), and I have only followed some initial tutorial examples in the manual (e.g. "the wrench").
However, as I understood, there are also ways to solve ODEs (ordinary differential equations). I wanted to start with something really simple, and on the internet I found some example involving the predatory model:
#rabbits: dr/dt = a*r - b*r*f
#foxes: df/dt = -c*f + d*r*f
However, the example I found is clearly meant for a different COMSOL version because the description of buttons/menus to use does not correspond to my version.
To give it a go anyway, I used the "Global ODEs and DAEs" node, and in the "Global Equations 1" settings window, defined:
r*(a-b*f)-rt (initial value r: 100, initial value rt: 0)
-f*(c-d*r)-ft (initial value f: 100, initial value ft: 0)
My question is (and this might come from a complete misunderstanding of how COMSOL works):
- Where do I define the upper and lower bounds for t? (In the geometry, but how?)
- how do I get a plot showing r and f versus t? (Do I need to use "parameter sweep" for this?)
- Is it possible to just solve a 1-D ODE without selecting any kind of other physics models?
- Is there any example around for version 4.3a?
- (I actually tried to just click on "Study1->Calculate" and while the program does not complain, I also have no idea how to get the plot I want)

Best regards,

Machiel

Viewing all articles
Browse latest Browse all 26527

Trending Articles