Re: [petsc-dev] VecNest

2022-07-12 Thread Matthew Knepley
On Tue, Jul 12, 2022 at 8:25 AM Pierre Jolivet wrote: > > > On 12 Jul 2022, at 2:50 PM, Matthew Knepley wrote: > > On Tue, Jul 12, 2022 at 7:41 AM Matthew Knepley wrote: > >> On Tue, Jul 12, 2022 at 7:39 AM Pierre Jolivet wrote: >> >>> >>> >>> On 12 Jul 2022, at 2:32 PM, Matthew Knepley wrote

Re: [petsc-dev] VecNest

2022-07-12 Thread Pierre Jolivet
> On 12 Jul 2022, at 2:50 PM, Matthew Knepley wrote: > > On Tue, Jul 12, 2022 at 7:41 AM Matthew Knepley > wrote: > On Tue, Jul 12, 2022 at 7:39 AM Pierre Jolivet > wrote: > > >> On 12 Jul 2022, at 2:32 PM, Matthew Knepley >

Re: [petsc-dev] VecNest

2022-07-12 Thread Matthew Knepley
On Tue, Jul 12, 2022 at 7:41 AM Matthew Knepley wrote: > On Tue, Jul 12, 2022 at 7:39 AM Pierre Jolivet wrote: > >> >> >> On 12 Jul 2022, at 2:32 PM, Matthew Knepley wrote: >> >> On Mon, Jul 11, 2022 at 1:17 PM Pierre Jolivet wrote: >> >>> Hello, >>> Could anyone help me understand what is goi

Re: [petsc-dev] VecNest

2022-07-12 Thread Matthew Knepley
On Tue, Jul 12, 2022 at 7:39 AM Pierre Jolivet wrote: > > > On 12 Jul 2022, at 2:32 PM, Matthew Knepley wrote: > > On Mon, Jul 11, 2022 at 1:17 PM Pierre Jolivet wrote: > >> Hello, >> Could anyone help me understand what is going on in the following >> example, please? >> I have a VecNest. >> I

Re: [petsc-dev] VecNest

2022-07-12 Thread Pierre Jolivet
> On 12 Jul 2022, at 2:32 PM, Matthew Knepley wrote: > > On Mon, Jul 11, 2022 at 1:17 PM Pierre Jolivet > wrote: > Hello, > Could anyone help me understand what is going on in the following example, > please? > I have a VecNest. > I either: a) initialize all values to

Re: [petsc-dev] VecNest

2022-07-12 Thread Matthew Knepley
On Mon, Jul 11, 2022 at 1:17 PM Pierre Jolivet wrote: > Hello, > Could anyone help me understand what is going on in the following example, > please? > I have a VecNest. > I either: a) initialize all values to 0.0, then set a specific part of the > vector to nonzero or b) initialize a part of the

Re: [petsc-dev] VecNest

2022-07-12 Thread Pierre Jolivet
> On 12 Jul 2022, at 2:13 PM, Pierre Jolivet wrote: > > > >> On 12 Jul 2022, at 2:04 PM, Mark Adams > > wrote: >> >> It looks like the RHS is zero in the 2nd case (0 KSP unpreconditioned resid >> norm 0.e+00), but the true residual is the same. >> >> It

Re: [petsc-dev] VecNest

2022-07-12 Thread Pierre Jolivet
> On 12 Jul 2022, at 2:04 PM, Mark Adams wrote: > > It looks like the RHS is zero in the 2nd case (0 KSP unpreconditioned resid > norm 0.e+00), but the true residual is the same. > > It looks like you added "nest_subvec" to our example. It’s a new (dumb) example (ex). > You

Re: [petsc-dev] VecNest

2022-07-12 Thread Mark Adams
It looks like the RHS is zero in the 2nd case (0 KSP unpreconditioned resid norm 0.e+00), but the true residual is the same. It looks like you added "nest_subvec" to our example. You can start by looking at the vectors with -vec_view (there is code that you can view vectors explicitly

[petsc-dev] VecNest

2022-07-11 Thread Pierre Jolivet
Hello, Could anyone help me understand what is going on in the following example, please? I have a VecNest. I either: a) initialize all values to 0.0, then set a specific part of the vector to nonzero or b) initialize a part of the vector to 0.0 and set the other part to nonzero. I don’t see why