[petsc-users] Can't figure out why I get inf solutions.

HeeHo Park heeho.park at gmail.com
Mon Nov 12 17:27:27 CST 2018


Since I can't send binary files, I hardcoded the values on main.py. You
only need main.py file to run the code.

Thanks,

On Mon, Nov 12, 2018 at 5:17 PM HeeHo Park <heeho.park at gmail.com> wrote:

> Hi PETSc,
>
> These Python looks complicated but it really isn't. please run main.py
>
> I am writing up a script that would read petsc binary files extracted from
> one of PFLOTRAN newton iteration step and solve with petsc4py to
> investigate linear solvers.
>
> But I am having trouble solving a matrix that converges PFLOTRAN, let
> alone running a trimmed size (15x15) matrix of A. You'll see in the
> script.
>
> I don't think there is any problem with loading sparse.csr_matrix onto
> PETSc and same with array as I tested with very simple matrix which it
> solves.
>
> Can you figure out why I'm getting inf solutions?
>
> If I use the sparse matrix package to solve it, it solves it very quickly.
>
> x = sla.spsolve(A,b)
>
> Thanks,
>
> --
> HeeHo Daniel Park
>


-- 
HeeHo Daniel Park
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20181112/0824f34a/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: main.py
Type: text/x-python
Size: 7070 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20181112/0824f34a/attachment.py>


More information about the petsc-users mailing list