Dear All,
I got some strange solutions when using SuperLU for a complex reactive
transport simulation. Before the timestep 28, everything works fine, for
both sequential version and parallel version. Starting from timestep 29,
the timestep cannot increase for SuperLU solver, for both sequentia
Danyang:
>
>
> To my surprising, solutions from SuperLU at timestep 29 seems not correct
> for the first 4 Newton iterations, but the solutions from iteration solver
> and MUMPS are correct.
>
> Please find all the matrices, rhs and solutions at timestep 29 via the
> link below. The data is a bit
Hi Hong,
The binary format of matrix, rhs and solution can be downloaded via the
link below.
https://www.dropbox.com/s/cl3gfi0s0kjlktf/matrix_and_rhs_bin.tar.gz?dl=0
Thanks,
Danyang
On 15-12-03 10:50 AM, Hong wrote:
Danyang:
To my surprising, solutions from SuperLU at timestep 29 se
Danyang:
Using petsc/src/ksp/ksp/examples/tutorials/ex10.c,
I tested a_flow_check_168.bin
mpiexec -n 4 ./ex10 -f0
/Users/Hong/Downloads/matrix_and_rhs_bin/a_flow_check_168.bin -rhs
/Users/Hong/Downloads/matrix_and_rhs_bin/x_flow_check_168.bin -pc_type lu
-pc_factor_mat_solver_package superlu_dist
Danyang :
Further testing a_flow_check_168.bin,
./ex10 -f0 /Users/Hong/Downloads/matrix_and_rhs_bin/a_flow_check_168.bin
-rhs /Users/Hong/Downloads/matrix_and_rhs_bin/x_flow_check_168.bin -pc_type
lu -pc_factor_mat_solver_package superlu -ksp_monitor_true_residual
-mat_superlu_conditionnumber
Rec
Hi Hong,
I just checked using ex10 for these matrices and rhs, they all work
fine. I found something is wrong in my code when using direct solver.
The second parameter mat in PCFactorGetMatrix(PC pc,Mat *mat) is not
initialized in my code for SUPERLU or MUMPS.
I will fix this bug, rerun the
Hi Hong,
I did more test today and finally found that the solution accuracy
depends on the initial (first) matrix quality. I modified the ex52f.F to
do the test. There are 6 matrices and right-hand-side vectors. All these
matrices and rhs are from my reactive transport simulation. Results will
Danyang :
Adding '-mat_superlu_dist_fact SamePattern' fixed the problem. Below is how
I figured it out.
1. Reading ex52f.F, I see '-superlu_default' =
'-pc_factor_mat_solver_package superlu_dist', the later enables runtime
options for other packages. I use superlu_dist-4.2 and superlu-4.1 for the
Hello Hong,
Thanks for the quick reply and the option "-mat_superlu_dist_fact
SamePattern" works like a charm, if I use this option from the command
line.
How can I add this option as the default. I tried using
PetscOptionsInsertString("-mat_superlu_dist_fact SamePattern",ierr) in
my code b
Danyang:
Add 'call MatSetFromOptions(A,ierr)' to your code.
Attached below is ex52f.F modified from your ex52f.F to be compatible with
petsc-dev.
Hong
Hello Hong,
>
> Thanks for the quick reply and the option "-mat_superlu_dist_fact
> SamePattern" works like a charm, if I use this option from the
Thank. The inserted options works now. I didn't put
PetscOptionsInsertString in the right place before.
Danyang
On 15-12-07 12:01 PM, Hong wrote:
Danyang:
Add 'call MatSetFromOptions(A,ierr)' to your code.
Attached below is ex52f.F modified from your ex52f.F to be compatible
with petsc-dev.
Hi Hong,
Thank you very much for keeping tracking down the problem. I apologize for
slow response... some administrative duties consumed most of my cycles for
a few days.
SamePattern can be used for a sequence of linear systems with the same
sparsity pattern. Then the sparsity ordering is done onl
Hi Hong,
Sorry to bother you again. The modified code works much better than
before using both superlu or mumps. However, it still encounters
failure. The case is similar with the previous one, ill-conditioned
matrices.
The code crashed after a long time simulation if I use superlu_dist, but
Danyang :
Your matrices are ill-conditioned, numerically singular with
Recip. condition number = 6.000846e-16
Recip. condition number = 2.256434e-27
Recip. condition number = 1.256452e-18
i.e., condition numbers = O(1.e16 - 1.e27), there is no accuracy in
computed solution.
I checked your matrix
Hi Hong,
Thanks for checking this. A mechanical model was added at the time when
the solver failed, causing some problem. We need to improve this part in
the code.
Thanks again and best wishes,
Danyang
On 15-12-08 08:10 PM, Hong wrote:
Danyang :
Your matrices are ill-conditioned, numerical
15 matches
Mail list logo