[cig-commits] [commit] master: Fix a bug in LU decomposition for 3-band matrix (b8f761e)
cig_noreply at geodynamics.org
cig_noreply at geodynamics.org
Wed Jun 4 20:00:32 PDT 2014
Repository : https://github.com/geodynamics/calypso
On branch : master
Link : https://github.com/geodynamics/calypso/compare/d3671756c9a8dc30cd0c89470f2e2f0599bbe718...1d20f55fd74b30f7715f875492f6a7b62f3b6274
>---------------------------------------------------------------
commit b8f761e875d68d247f0dbcd5425c47827c4a4834
Author: Hiroaki Matsui <h_kemono at mac.com>
Date: Wed May 28 10:25:35 2014 -0700
Fix a bug in LU decomposition for 3-band matrix
>---------------------------------------------------------------
b8f761e875d68d247f0dbcd5425c47827c4a4834
src/Fortran_libraries/SOLVER_src/direct_solver/m_ludcmp_3band.f90 | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/src/Fortran_libraries/SOLVER_src/direct_solver/m_ludcmp_3band.f90 b/src/Fortran_libraries/SOLVER_src/direct_solver/m_ludcmp_3band.f90
index 51b92fe..bcaedc2 100644
--- a/src/Fortran_libraries/SOLVER_src/direct_solver/m_ludcmp_3band.f90
+++ b/src/Fortran_libraries/SOLVER_src/direct_solver/m_ludcmp_3band.f90
@@ -126,13 +126,10 @@
!
do j = 1, n
!
- if(j .gt. 2) then
- band_lu(2,j) = band_lu(2,j) - band_lu(4,j-2)*band_lu(1,j)
- end if
-!
if(j .eq. 2) then
band_lu(3,j) = band_lu(3,j) - band_lu(4,j-1)*band_lu(2,j)
- else
+ else if(j .gt. 2) then
+ band_lu(2,j) = band_lu(2,j) - band_lu(4,j-2)*band_lu(1,j)
band_lu(3,j) = band_lu(3,j) - band_lu(5,j-2)*band_lu(1,j) &
& - band_lu(4,j-1)*band_lu(2,j)
end if
More information about the CIG-COMMITS
mailing list