Need to develop the scilab code for the following problem

System under consideration is

xn+1=axn+μ forxn≤0
bxn+μ-1 forxn>0

Xn+1 is calculated depend on the xn values in each iteration

Code needs to do following steps:

Let initial value of xn=0;then

First iteration n=0:

As xn <0

Xn+1= axn+µ → x1=ax0+µ

Let this value >0 → x1 >0

Second Iteration n=1:

Xn+1=bxn+µ-1 → x2=bx1+µ-1 → x2=b(ax0+µ)+µ-1

Note: Need to store the x1,x2 variables in array .

Scilab 28-03-21, 8:22 a.m. ShankarmaniG
This is a lab journal question; if you need help, look at the other similar labs in the Scilab Lab migration project. The Scilab Lab Migration project has over 100 solved labs; all you have to do is look for the experiment in the correct lab and get the solution.
13-01-22, 5:41 p.m. Rashmi

Log-in to answer to this question.