Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
A_02 GUASS SEIDEL METHOD
PROGRAM GUASS_SEIDEL_METHOD IMPLICIT NONE REAL::MAT(4,3),X,Y,Z INTEGER::I,N X=1.5 Y=1.5 Z=-0.5 DATA MAT / 8.0,-3.0,2.0,11.0 , & 2.0,-8.0,-1.0,-3.0, & 2.0,-4.0,-10.0,10.0 / PRINT*,'INPUT THE VALUE OF N:' READ*,N DO I=1,N X=(MAT(4,1)+(-1.0*MAT(2,1)*Y)+(-1.0*MAT(3,1)*Z))/MAT(1,1) Y=(-1.0*MAT(4,2)+(MAT(1,2)*X)+(MAT(3,2)*Z))/(-1.0*MAT(2,2)) Z=(-1.0*MAT(4,3)+(MAT(1,3)*X)+(MAT(2,3)*Y))/(-1.0*MAT(3,3)) PRINT*,X,Y,Z END DO PRINT*,'THE MATRIX IS:' PRINT*,MAT PRINT*, ' THE SOLUTIONS IS:' PRINT*,X,Y,Z STOP END PROGRAM GUASS_SEIDEL_METHOD
run
|
edit
|
history
|
help
0
Factorial problem
euler-cromer
A program to calculate potential energy.
Example 45 175 page
222
Fyyh
A_01 BISECTION METHOD
Gauss forward elimination
euler-cromer
A_01 FALSE_POSITION_METHOD