Community
cancel
Showing results for 
Search instead for 
Did you mean: 
jbertels01
Beginner
337 Views

Pardiso produces the wrong output

Hi there,
Ich have a problem with the sparse solver Pardiso. I don't know whether I don't understand the parameters of Pardiso or whether it is not working with my system. My problem ist that Pardiso produces the wrong output for my input. I also tried the example program pardiso_sym_f90.f90and I thinkI did not work. Maybe it worked but I don't understand the output.It produced

The solution of the system is

x( 1 ) = -4.186020128680939E-002

x( 2 ) = -3.413124159279098E-003

x( 3 ) = 0.117250376805018

x( 4 ) = -0.112639579923180

x( 5 ) = 2.417224446137141E-002

x( 6 ) = -0.107633340356223

x( 7 ) = 0.198719673273585

x( 8 ) = 0.190382963551205
Is this the right solution?
I also tried to call Pardiso myself in the file test.f90.
There I get the following output:

The array ia:

1 2 3 4 5 6

The array a:

(1.000000,0.0000000E+00) (1.000000,0.0000000E+00) (1.000000,0.0000000E+00)

(1.000000,0.0000000E+00) (1.000000,0.0000000E+00)

The array ja:

1 2 3 4 5

The array x:

(0.0000000E+00,1.875000)

(0.0000000E+00,0.0000000E+00)

(0.0000000E+00,1.875000)

(0.0000000E+00,0.0000000E+00)

(0.0000000E+00,0.0000000E+00)

If I got the ja, ia and a arrays right, I don't understad the output.
I'm using Visual Studio 2008and the MKL 10.3 under Windows XP Professional SP2 .

0 Kudos
4 Replies
mecej4
Black Belt
337 Views

My remarks apply only to the example program pardiso_sym_f90.f90. The solution that it gives for x agrees with what I get from Matlab.

Why do you think that there is something is wrong? The matrix A is present in the source code, with the upper triangular part neatly formatted. Compute the product A.x and see if it produces a vector whose elements are all = 1.

What do you mean by "it did not work"?
337 Views

Hi,
Just compare your example with pardiso_unsym_complex_f: I've replaced your complex type to complex*16 and set each complex element as pair of numbers (like (1.0d0, 2.0d0)) - after your updated example work correctly.
With best regards,
Alexander Kalinkin
jbertels01
Beginner
337 Views

Hi,
OK pardiso_sym_f90.f90 works correct (of course). I made a mistake in testing it.
When I changed the type complexin test.f90 into complex*16 it gave me the right output. But how can I use single precision? In my application I only need single precision. Why is it not working with the type complex resp. where is my mistake?

best regards
Julian Bertels

337 Views

Hi,
To use pardiso with single precision please change value of iparm(28) to 1.
With best regards,
Alexander Kalinkin
Reply