I have just done it. Thank you.
rogram inverse
real(8), dimension(:,:), allocatable :: a, ID
real(8), dimension(:), allocatable :: b, x, y
real(8) :: s1, su, sm
integer :: i, j, k, n
print *, 'dimensió'
read *, n
allocate (a(n,n))
allocate (ID(n,n))
allocate (b(n))
allocate (x(n))
allocate...
I knew that. In fact, I was trying to use Jacobi algorithm by dividing the identity matrix in subarrays composed by its columns like that:
program inverse
real(8), dimension(:,:), allocatable :: a, ID
real(8), dimension(:), allocatable :: b, x, y
real(8) :: s1, su, sm
integer :: i, j, k, n...
I am trying to set a program in fortran 95 for calculating inverses of matrices by using the jacobi algorithm. I have compiled it successfully, but I execute it, it is only able to calculate correctly the first column of the new matrix. The code is:
Program algo
implicit none
real(8)...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.