Re: [petsc-users] Increasing norm with finer mesh

2018-10-16 Thread Weizhuo Wang
unless the solution can be represented > exactly by your FE space (eg, u(x,y) = x + y). > > On Mon, Oct 8, 2018 at 9:33 PM Matthew Knepley wrote: > >> On Mon, Oct 8, 2018 at 9:28 PM Weizhuo Wang >> wrote: >> >>> The code is attached in case anyone wants to t

Re: [petsc-users] Increasing norm with finer mesh

2018-10-16 Thread Weizhuo Wang
I just tried both, neither of them make a difference. I got exactly the same curve with either combination. Thanks! Wang weizhuo On Tue, Oct 16, 2018 at 8:06 PM Matthew Knepley wrote: > On Tue, Oct 16, 2018 at 7:26 PM Weizhuo Wang > wrote: > >> Hello again! >> >> A

Re: [petsc-users] Increasing norm with finer mesh

2018-10-22 Thread Weizhuo Wang
Amazing, right preconditioning fixes the problem. Thanks a lot! On Tue, Oct 16, 2018 at 8:31 PM Dave May wrote: > > > On Wed, 17 Oct 2018 at 03:15, Weizhuo Wang wrote: > >> I just tried both, neither of them make a difference. I got exactly the >> same curve

Re: [petsc-users] Increasing norm with finer mesh

2018-10-08 Thread Weizhuo Wang
The code is attached in case anyone wants to take a look, I will try the high frequency scenario later. On Mon, Oct 8, 2018 at 7:58 PM Mark Adams wrote: > > > On Mon, Oct 8, 2018 at 6:58 PM Weizhuo Wang wrote: > >> The first plot is the norm with the flag -pc_type lu with re

Re: [petsc-users] Increasing norm with finer mesh

2018-10-02 Thread Weizhuo Wang
the name of the example code from ex12.c to ex12c.c Thanks for all your reply! Weizhuo Smith, Barry F. >Please send your version of the example that computes the mean norm of > the grid; I suspect we are talking apples and oranges > >Barry > > > > > On Oct 1, 201

Re: [petsc-users] Increasing norm with finer mesh

2018-10-02 Thread Weizhuo Wang
I didn't specify a tolerance, it was using the default tolerance. Doesn't the asymptoting norm implies finer grid won't help to get finer solution? Mark Adams 于2018年10月2日周二 下午4:11写道: > > > On Tue, Oct 2, 2018 at 5:04 PM Weizhuo Wang wrote: > >> Yes I was using one norm in

Re: [petsc-users] Increasing norm with finer mesh

2018-10-02 Thread Weizhuo Wang
= PetscPrintf(PETSC_COMM_WORLD,"Norm of error %g iterations %D\n",(double)norm/(m*n),its); CHKERRQ(ierr); I made a plot to show the increase: [image: Norm comparison.png] Mark Adams 于2018年10月2日周二 下午2:27写道: > > > On Tue, Oct 2, 2018 at 2:24 PM Weizhuo Wang wrote: &g

Re: [petsc-users] Increasing norm with finer mesh

2018-10-01 Thread Weizhuo Wang
I also tried to divide the norm by m*n , which is the number of grids, the trend of norm still increases. Thanks! Weizhuo Matthew Knepley 于2018年10月1日周一 下午7:45写道: > On Mon, Oct 1, 2018 at 6:31 PM Weizhuo Wang wrote: > >> Hi! >> >> I'm recently trying out the example co

[petsc-users] Increasing norm with finer mesh

2018-10-01 Thread Weizhuo Wang
Hi! I'm recently trying out the example code provided with the KSP solver (ex12.c). I noticed that the mean norm of the grid increases as I use finer meshes. For example, the mean norm is 5.72e-8 at m=10 n=10. However at m=100, n=100, mean norm increases to 9.55e-6. This seems counter intuitive,