home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C!T ROM 2
/
ctrom_ii_b.zip
/
ctrom_ii_b
/
PROGRAM
/
PASCAL
/
NRPAS13
/
QROMO.DEM
< prev
next >
Wrap
Text File
|
1991-04-29
|
572b
|
32 lines
PROGRAM d4r6(input,output);
(* Driver for routine QROMO *)
CONST
x1=0.0;
x2=1.5707963;
n=5;
TYPE
glnarray = ARRAY [1..n] OF real;
VAR
glit : integer;
result : real;
FUNCTION func(x: real): real;
BEGIN
func :=sqrt(x)/sin(x)
END;
(*$I MODFILE.PAS *)
(*$I MIDSQL.PAS *)
(*$I POLINT.PAS *)
(*$I QROMO.PAS *)
BEGIN
writeln('Improper integral:');
writeln;
qromo(x1,x2,result);
writeln('Function: sqrt(x)/sin(x) Interval: (0,pi/2)');
writeln('Using: MIDSQL Result:',result:8:4);
END.