[petsc-users] snes options for rough solution

Matthew Knepley knepley at gmail.com
Tue Dec 13 00:28:39 CST 2016


On Tue, Dec 13, 2016 at 12:12 AM, Praveen C <cpraveen at gmail.com> wrote:

> On Tue, Dec 13, 2016 at 2:50 AM, Matthew Knepley <knepley at gmail.com>
> wrote:
>
>> On Mon, Dec 12, 2016 at 2:29 AM, Praveen C <cpraveen at gmail.com> wrote:
>>
>>> Hello Matt
>>>
>>> I have attached the detailed output.
>>>
>>> Fenics automatically computes Jacobian, so I think Jacobian should be
>>> correct. I am not able to run the Fenics code without giving the Jacobian.
>>> I am currently writing a C code where I can test this.
>>>
>>> This equation is bit weird. Its like this
>>>
>>> u_t = ( K u_x)_x
>>>
>>> K = u / sqrt(u_x^2 + eps^2)
>>>
>>
>> I do not understand how to show parabolicity in this case. However, I
>> have a more fundamental misunderstanding. In your code, I see
>>
>>   R0 = idt*(u-uold)*v*dx + K0*ux*vx*dx
>>
>> for the residual, which looks like
>>
>> R0 = u_t + K u_x
>>
>> to me. Where is the extra derivative you show above?
>>
>>
> Hello Matt
>
> vx is derivative of test function. So the last term is a second order
> differential operator. The PDE in full looks like this
>
> u_t = u_x^2/sqrt(u_x^2 + eps^2) + eps^2 * u * u_xx / (u_x^2 + eps^2)^1.5
>
> With u > 0, the last term is parabolic. But numerically, I solve it in
> divergence form.
>

Alright, the Jacobian looks good and you just have a hard nonlinear problem.

Okay, so this problem is singularly perturbed, in that as eps->0, its loses
parabolicity (I think) because the
u_xx term vanishes? The reason I am so mystified by this is that I did not
think that derivatives were supposed
to grow with parabolic evolution, but clearly that is happening here.

You can certainly use adaptive time stepping with TS, but you could also
try using grid sequencing, since for a big
enough H it appears you converge fast.

  Thanks,

     Matt

Best
> praveen
>



-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20161213/ae01f8df/attachment.html>


More information about the petsc-users mailing list