Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Scicos 4.2 If Then Else Block

18 views
Skip to first unread message

johnny

unread,
Nov 10, 2009, 2:31:58 PM11/10/09
to
Hello,

I'm new in using scilab/scicos and I've a problem regarding conditions
in scicos. I was thinking about using the "If Then Else block", but I
don't know how to use this one correctly. Unfortunately I couldn't
find any working example with this block in the web, so I hope I can
find support here ...

Problem:
Man with a parachute jumps out of an aircraft at 2000 meters. At 1000
meters the parachute is automatically opened, therefore the
calculation of the speed changes.

I just did this in scilab with "if ... then ... else ... end" by
changing a specific variable, but I'm not sure how to model this in
scicos!

This is the current state of my simulation, which is currently only
simulating a falling man: http://img188.imageshack.us/img188/2825/skydiverq.jpg
The value of the constant block "r" shall be changed or another
calculation (%pi * R ^2) has to be multiplied by "a".

How can I realize this behavior in scicos?


Regards
Jan

mike

unread,
Nov 15, 2009, 4:44:15 AM11/15/09
to
I think you could use the "if in > 0" - block from Events and the
selector (2 inputs, 1 output) from Branching.

regards
mike

johnny schrieb:

Serge Steer

unread,
Nov 16, 2009, 5:26:41 AM11/16/09
to
It is better to use a zero crossing block (for exemple +to- with z-1000
as an input (where z is the altitude)

The use the generated event to activate the parachute model (it adds a
force). You can use a switch block (first event input connected to an
event generator at t=0 and the second one to the output of the zero
crossing block.

Serge
johnny a �crit :

0 new messages