PROGRAM pardisotest
integer*8, dimension(64) :: pt
integer :: maxfct=1
integer :: mnum =1
integer :: mtype = -2
integer :: phase
integer :: n=8
REAL,dimension(18) :: a
integer,dimension(9):: ia
integer,dimension(18) :: ja
integer, dimension(8) :: perm
integer :: nrhs =1
integer, dimension(64) :: iparm
integer :: msglvl = 1
REAL, dimension(8) :: b
REAL, dimension(8) :: x
integer :: error = 0
ia = (/ 1, 5, 8, 10, 12, 15, 17, 18, 19 /)
ja = (/ 1, 3, 6, 7,
& 2, 3, 5,
& 3, 8,
& 4, 7,
& 5, 6, 7,
& 6, 8,
& 7,
& 8 /)
a = (/ 7.d0, 1.d0, 2.d0, 7.d0,
& -4.d0, 8.d0, 2.d0,
& 1.d0, 5.d0,
& 7.d0, 9.d0,
& 5.d0, 1.d0, 5.d0,
& -1.d0, 5.d0,
& 11.d0,
& 5.d0 /)
b=(/17.d0, 6.d0, 6.d0, 16.d0 ,11.d0, 4.d0, 11.d0, 5.d0/)
DO i = 1, 64
pt(i)=0
iparm(i) = 0
END DO
DO i = 1, 8
x(i) = 0
END DO
phase = 13
CALL pardiso (pt, maxfct, mnum, mtype, phase, n, a, ia, ja,
& perm, nrhs, iparm, msglvl, b, x, error)
WRITE(*,*) 'The solution of the system is '
DO i = 1, n
WRITE(*,*) ' x(',i,') = ', x(i)
END DO
read*
END PROGRAM pardisotest
li913 发表于 2019-8-6 10:18
include 'mkl_pardiso.f90'
QQ图片20190806211541.png (168.03 KB, 下载次数: 201)
QQ截图20190807100346.png (59.96 KB, 下载次数: 247)
欢迎光临 Fortran Coder (http://bbs.fcode.cn/) | Powered by Discuz! X3.2 |