<div dir="ltr">Can you explain what I may have to do for the nonlinear solver?<div><br></div><div>My work is not about conducting simulation so I want to avoid programming.</div><div>I am trying to keep this work small, and it is just related to a posteriori error estimation. </div><div><br></div><div>Hyungeun</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">2021년 6월 26일 (토) 오후 7:35, Dedner, Andreas <<a href="mailto:A.S.Dedner@warwick.ac.uk">A.S.Dedner@warwick.ac.uk</a>>님이 작성:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
I didn't say that - I am just saying that you will need to put some work into the nonlinear solver since the problem is not differentiable. But others here are more experts on this.
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Andreas</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
PS: always 'reply to all' to keep things on the list<br>
</div>
<div id="gmail-m_8828034923456041appendonsend"></div>
<hr style="display:inline-block;width:98%">
<div id="gmail-m_8828034923456041divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Hyun-Geun Shin <<a href="mailto:shgmath@gmail.com" target="_blank">shgmath@gmail.com</a>><br>
<b>Sent:</b> 26 June 2021 18:07<br>
<b>To:</b> Dedner, Andreas <<a href="mailto:A.S.Dedner@warwick.ac.uk" target="_blank">A.S.Dedner@warwick.ac.uk</a>><br>
<b>Subject:</b> Re: [Dune] A question about solving my problem</font>
<div> </div>
</div>
<div>
<div dir="ltr">Hello
<div><br>
</div>
<div>I tried the case of g(u) = |grad(u)| using FreeFem.</div>
<div>FreeFem produces a lot of errors I cannot understand. </div>
<div>Then, I tried g(u) = a+ |grad(u)|, and FreeFem runs with not small a. a is a constant.</div>
<div>If a is small, FreeFem does not have any errors but it seems not running after several iterations.</div>
<div><br>
</div>
<div>The developer said that FreeFem does not support DG formulations enough.</div>
<div>He also said that he is not an expert in DG, so I guess he implemented DG in FreeFem without a deep consideration. </div>
<div>I tried g(u) = |grad(u)| with classical FEM, and it runs. </div>
<div>Again, the case of g(u) = u^2 with DG formulations does not work. </div>
<div><br>
</div>
<div>As you said, I cannot try g(u) = |grad(u)| using DUNE. Am I correct?</div>
<div><br>
</div>
<div>Best regards</div>
<div><br>
</div>
<div>Hyungeun</div>
<div><br>
</div>
<div><br>
</div>
</div>
<br>
<div>
<div dir="ltr">2021년 6월 26일 (토) 오후 6:53, Dedner, Andreas <<a href="mailto:A.S.Dedner@warwick.ac.uk" target="_blank">A.S.Dedner@warwick.ac.uk</a>>님이 작성:<br>
</div>
<blockquote style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Hi.<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
As Christian said this doesn't look like a too difficult example (except the corner case g(u)=|grad(u)| which will cause problems with the non linear solver).<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
So, I am wondering which problems you encountered with FreeFem since I would except any standard PDE software package should at least manage the case g(u)=u^2. Are there any additional details about your problem that caused the problems? Is it the a-posteriori
adaptivity that made things difficult or the DG formulation of the problem?</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Perhaps have a look at<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<a href="https://dune-project.org/sphinx/content/sphinx/dune-fem/discontinuousgalerkin_nb.html" target="_blank">https://dune-project.org/sphinx/content/sphinx/dune-fem/discontinuousgalerkin_nb.html</a></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
That's DG for Laplace but adding nonlinearities should be in general straightforward like in</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<a href="https://dune-project.org/sphinx/content/sphinx/dune-fem/dune-fempy_nb.html" target="_blank">https://dune-project.org/sphinx/content/sphinx/dune-fem/dune-fempy_nb.html</a></div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Best</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
Andreas<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)">
<br>
</div>
<div id="gmail-m_8828034923456041x_gmail-m_8164000427951501840appendonsend"></div>
<hr style="display:inline-block;width:98%">
<div id="gmail-m_8828034923456041x_gmail-m_8164000427951501840divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" color="#000000" style="font-size:11pt"><b>From:</b> Dune <<a href="mailto:dune-bounces@lists.dune-project.org" target="_blank">dune-bounces@lists.dune-project.org</a>>
on behalf of Christian Engwer <<a href="mailto:christian.engwer@uni-muenster.de" target="_blank">christian.engwer@uni-muenster.de</a>><br>
<b>Sent:</b> 26 June 2021 14:39<br>
<b>To:</b> Hyun-Geun Shin <<a href="mailto:shgmath@gmail.com" target="_blank">shgmath@gmail.com</a>><br>
<b>Cc:</b> <a href="mailto:dune@lists.dune-project.org" target="_blank">dune@lists.dune-project.org</a> <<a href="mailto:dune@lists.dune-project.org" target="_blank">dune@lists.dune-project.org</a>><br>
<b>Subject:</b> Re: [Dune] A question about solving my problem</font>
<div> </div>
</div>
<div><font size="2"><span style="font-size:11pt">
<div>Dear Hyun-Geun,<br>
<br>
> My problem is to solve a PDE like -div(g(u) * grad(u)) = f, discretized by<br>
> discontinuous Galerkin methods. Here, u is the solution, g(u) is a nonlinear<br>
> function, and f is a load function. So, g(u) can be “abs(grad(u))” or u^2.<br>
<br>
So basically you are trying to solve a non-linear diffusion<br>
problem. This is perfectly possible.<br>
<br>
Although it is not part of the usual examples the modifications<br>
regarding the typical poisson problem are not too big. You should be<br>
able to implement this relatively easily with a discretization module<br>
like dune-pdelab, which I'm using, but also dune-fem should provide<br>
the necessary flexibility. The third option would be to do thinkgs a<br>
bit more by hand and use the functions spaces from dune-functions.<br>
<br>
Regarding the non-linear solver, a standard Newton method, together<br>
with a Jacobian computed by numerical differentiation should work in<br>
most cases. Still, depending on the type on non-linearity, you might<br>
encounter convergecne issues (which you can still ignore if you don't<br>
care about efficiency).<br>
<br>
Ciao<br>
Christian<br>
<br>
_______________________________________________<br>
Dune mailing list<br>
<a href="mailto:Dune@lists.dune-project.org" target="_blank">Dune@lists.dune-project.org</a><br>
<a href="https://lists.dune-project.org/mailman/listinfo/dune" target="_blank">https://lists.dune-project.org/mailman/listinfo/dune</a></div>
</span></font></div>
</div>
</blockquote>
</div>
</div>
</div>
</blockquote></div>