Fortran ~ Trapezoidal rule - Ishwaranand

Ishwaranand News

Fortran ~ Trapezoidal rule

Fortran Trapezoidal rule

trapezoidal rule calculator,trapezoidal rule example problems pdf, trapezoidal rule simple definition, trapezoidal rule diagram, trapezoidal rule formula for volume, trapezoidal rule matlab, trapezoidal rule ppt, trapezoidal rule and simpson's rule, trapezoidal rule in surveying, trapezoidal rule mcq, trapezoidal rule area of irregular shape, trapezoidal shape, trapezoidal rule worksheet, trapezoidal area formula, ap calculus bc riemann sums, midpoint rule formula, composite midpoint rule example, midpoint rule khan academy, midpoint rule matlab, midpoint rule double integral, midpoint rule calculator, trapezoidal formula is also known as, advantages of trapezoidal rule, trapezoidal and simpson's rule pdf, numerical integration excel trapezoidal rule, numerical double integration trapezoidal rule, trapezoidal rule application in real life, simpson's 1/3 rule in c, trapezoidal rule code matlab, trapezoidal rule c program, trapezoidal rule algorithm, 2d trapezoidal rule python, simpson's 3/8 rule in c, trapezoidal rule calculator, trapezoidal rule example problems pdf, trapezoidal rule simple definition, trapezoidal rule diagram, trapezoidal rule formula for volume, trapezoidal rule matlab, trapezoidal rule ppt, trapezoidal rule and simpson's rule, trapezoidal rule in surveying, trapezoidal rule mcq, trapezoidal rule area of irregular shape, trapezoidal shape, trapezoidal rule worksheet, trapezoidal area formula,
Image Source ~ Crafted With ©Ishwaranand - 2020 ~ Image by ©Ishwaranand

Q.  Write Program using Trapezoidal rule to Calculate the area under a curve...?

PROGRAM TRPRUL

C
C         PROGRAM TO DEMONSTRATE APPLICATION OF TRAPEZOIDAL RULE
C
C        THIS PROGRAM NUMERICALLY INTEGRATES GIVEN EXPRESSION WITHIN
C        SPECIFIED LIMITS OF INTEGRATION
C        AS INTEGRAL OF A FUNCTION IS EQUAL TO AREA UNDER THE CURVE
C        WE CAN ALSO USE THE PROGRAM TO CALCULATE AREA UNDER A CURVE
C
           F(X)=3.12*X**3+1.54*X**2-6.23
C
          WRITE(*,*)'LIMITS OF INTEGRATION(A,B)'
          READ(*,*)A,B
          WRITE(*,*)'NUMBER OF STRIPES'
          READ(*,*)NS
C       STRIP SIZE
          H=(B-A)/NS
          AREA=F(A)+F(B)
          DO 100 X=A+H,B-H,H
          AREA=AREA+2.0*F(X)
100    CONTINUE
          AREA=AREA*H/2.0
          WRITE(*,*)'AREA UNDER THE CURVE=',AREA
          STOP
          END

#OUTPUT
LIMIT OF INTEGRATION (A, B)
0 6
NUMBER OF STRIPS
6
AREA UNDER THE CURVE = 159.00000

No comments

Comment on Ishwaranand or Happy Day
Not, Add any types of links