'/Homework II (3) workfile hw2_3 u 1 251 series u=0 series h=0.5 series x=0 vector(50) yfup=0 vector(50) yfdown=0 scalar count=0 series v1=nrnd series v2=nrnd smpl 2 251 series x=0.5*x(-1)+v1 for !i=2 to 251 h(!i)=0.5+0.2*u(!i-1)^2+0.65*h(!i-1) u(!i)=@sqrt(h(!i))*v2(!i) next series y=1+0.8*x+u smpl 2 201 equation eq1.ls y c x for !j=0 to 49 smpl 202+!j 202+!j eq1.forecast yftemp uftemp yfup(!j+1)=yftemp(202+!j)+2*uftemp(202+!j) yfdown(!j+1)=yftemp(202+!j)-2*uftemp(202+!j) count=count+(y(!j+202)yfdown(!j+1))*(y(!j+202)yfup(!j+1)) next