[petsc-users] petsc-3.5 quadruple precision mixed with double

Satish Balay balay at mcs.anl.gov
Wed Jun 28 20:05:56 CDT 2017


Also you should use petsc-3.7 - the current release.

Satish

On Thu, 29 Jun 2017, Jed Brown wrote:

> Hao Zhang <hbcbh1999 at gmail.com> writes:
> 
> > hi, all:
> >
> > I'm developing a CFD project, which all the matrix solver is PETSc based.
> > It works fine with double precision until I need some more, like quadruple
> > precision.
> 
> What sort of CFD problem do you need quad precision for?
> 
> > Ax = b is the system
> > input are double precision
> >
> > shall I use PetscScalar instead of double?
> 
> Yes.
> 
> > Or is there a better way to pass double type to PETSc solver?
> 
> No, use PetscScalar in your code.
> 
> > Or shall I convert double type to quadruple type before passing into the
> > solver?
> 
> That tends to be uglier and slower.  It also loses accuracy in the
> input, which is important for extremely ill-conditioned problems.
> 
> > I'm using PETSc 3.5.4. GCC 5.2.0 comiple with float128. I think there
> > should be no compiling error.
> > I can provide more code part if necessary. Thanks!
> >
> > -- 
> > Hao
> 



More information about the petsc-users mailing list