Does anyone know how to convert this program from pascal to matlab? The goto statement is really confusing me. I just don't understand how it flows with the goto statements in there. If going to matlab cannot be explained , if I could get an explanation of what exactly this program is doing that would be great. I would really appreciate it.
Thanks, Tina
Bhigh:= 1.5E+11;
Blow := 1.5E+2;
100:
B := (Bhigh + Blow)/2.0;
w[1] := Ts; {Surface Temperature}
w[2] := (Ts-T0)/(d1*d2) + L; {Surface Temperature Slope}
y := 0.0;
repeat
If w[1] > 1.0 then begin
Blow := B;
goto 100;
end;
If w[2] < 0.0 then begin
Bhigh := B;
goto 100;
end;
Runge( Equations0, 2, 0.01, y, w );
{writeln(B:25:20,y:10:5);}
until Bhigh-Blow < 0.00000005;
Thanks, Tina
Bhigh:= 1.5E+11;
Blow := 1.5E+2;
100:
B := (Bhigh + Blow)/2.0;
w[1] := Ts; {Surface Temperature}
w[2] := (Ts-T0)/(d1*d2) + L; {Surface Temperature Slope}
y := 0.0;
repeat
If w[1] > 1.0 then begin
Blow := B;
goto 100;
end;
If w[2] < 0.0 then begin
Bhigh := B;
goto 100;
end;
Runge( Equations0, 2, 0.01, y, w );
{writeln(B:25:20,y:10:5);}
until Bhigh-Blow < 0.00000005;