Re: [petsc-users] Installing Triangle for PETSc by not using --download

2022-11-04 Thread Satish Balay via petsc-users
On Fri, 4 Nov 2022, Mike Michell wrote: > Thank you very much. It seems that --download-package={downloaded_dir} is > the right way to let PETSc know the source files and let it configures & > installs everything as it wants. > If I try --with-packages-download-dir, PETSc again tries to connect

Re: [petsc-users] Installing Triangle for PETSc by not using --download

2022-11-04 Thread Mike Michell
Thank you very much. It seems that --download-package={downloaded_dir} is the right way to let PETSc know the source files and let it configures & installs everything as it wants. If I try --with-packages-download-dir, PETSc again tries to connect and get the external packages from online, which I

Re: [petsc-users] Installing Triangle for PETSc by not using --download

2022-11-04 Thread Satish Balay via petsc-users
Can you try the --with-packages-download-dir option? It tells you the URL to download - and then PETSc configure does the install. Satish balay@p1 /home/balay/petsc (release =) $ ./configure --with-packages-download-dir=$HOME/tmp --download-triangle Download the following packages to

Re: [petsc-users] PCMGSetResidual and fortran

2022-11-04 Thread Barry Smith
Steven, Could you please send your test code. It is possible there is a bug in our Fortran interface since we do not test it for this functionality. Barry > On Nov 4, 2022, at 10:50 AM, Steven Dargaville > wrote: > > Hi all > > I have a quick question regarding the use of

[petsc-users] Installing Triangle for PETSc by not using --download

2022-11-04 Thread Mike Michell
Hi, I need to install PETSc and its dependencies to a linux system, which does not allow git clone from online. Thus I need to install all the dependencies by having their source files. First I downloaded and installed all the dependencies by relying on PETSc on my local linux (which means I used

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Edoardo alinovi
Yes, I did not set the block size for the vector... Missed it! I think I have nailed the way to handle block matrix/vectors, I am moving now on to solve the next facy error which is a ksp_diverged_its  thanks gents for the support with this block madness :)

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Barry Smith
> On Nov 4, 2022, at 6:55 AM, Edoardo alinovi wrote: > > Thanks Matt, > > I have found out that setValuesblocked will work if I do: > > call MatCreateVecs(A, x, y, ierr) > call setValuesBlocked(x, nblocks, varray, ierr) Ah, likely the block size for the vector was not correct, leading

[petsc-users] PCMGSetResidual and fortran

2022-11-04 Thread Steven Dargaville
Hi all I have a quick question regarding the use of PCMGSetResidual within fortran code. I'm calling PCMGSetResidual from within fortran: call PCMGSetResidual(pc_mg, petsc_level, mg_residual, coarse_matrix ierr) and just for testing purposes I've written a trivial residual evaluation routine:

Re: [petsc-users] locate DMSwarm particles with respect to a background DMDA mesh

2022-11-04 Thread Matthew Knepley
On Fri, Nov 4, 2022 at 7:46 AM Matteo Semplice < matteo.sempl...@uninsubria.it> wrote: > On 04/11/2022 02:43, Matthew Knepley wrote: > > On Thu, Nov 3, 2022 at 8:36 PM Matthew Knepley wrote: > >> On Thu, Oct 27, 2022 at 11:57 AM Semplice Matteo < >> matteo.sempl...@uninsubria.it> wrote: >> >>>

Re: [petsc-users] locate DMSwarm particles with respect to a background DMDA mesh

2022-11-04 Thread Matteo Semplice
On 04/11/2022 02:43, Matthew Knepley wrote: On Thu, Nov 3, 2022 at 8:36 PM Matthew Knepley wrote: On Thu, Oct 27, 2022 at 11:57 AM Semplice Matteo wrote: Dear Petsc developers, I am trying to use a DMSwarm to locate a cloud of points with respect to a

Re: [petsc-users] Report Bug TaoALMM class

2022-11-04 Thread Stephan Köhler
Barry, this is a nonartificial code.  This is a problem in the ALMM subsolver.  I want to solve a problem with a TaoALMM solver what then happens is: TaoSolve(tao)    /* TaoALMM solver */    |    |    |>   This calls the TaoALMM subsolver routine TaoSolve(subsolver)  

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Edoardo alinovi
Thanks Matt, I have found out that setValuesblocked will work if I do: call MatCreateVecs(A, x, y, ierr) call setValuesBlocked(x, nblocks, varray, ierr) However, there is nogetValuesBlocked. Not the end of the world, it is handy to set and get stuff by block and not by single entry :) Cheers

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Matthew Knepley
On Fri, Nov 4, 2022 at 4:32 AM Edoardo alinovi wrote: > It is working like a charm now! > > Is it mandatory to use VecSetValuesBlocked to assemble the rhs? Does the > Vec need to be of any other type than VECMPI? > SetValuesBlocked() is never required. You can always use the normal versions,

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Edoardo alinovi
It is working like a charm now! Is it mandatory to use VecSetValuesBlocked to assemble the rhs? Does the Vec need to be of any other type than VECMPI? I am assembling it like this: brhs(1:3-bdim) = this%Ueqn%bC(iElement,1:3-bdim) brhs(4-bdim) =

Re: [petsc-users] On the usage of MatSetValuesBlocked

2022-11-04 Thread Edoardo alinovi
Barry, Thanks, yes, I should pass 1 and not 3 For some reason I have misunderstood the wording in the documentation and I have interpreted m and n as the number of row and columns of the block to insert, while I need to think of everything as divided by bs... Now I am with you!!! Many thanks