[Getdp] How to define Robin boundary conditions

Thomas Ward tomwardathome at googlemail.com
Mon Oct 19 07:58:29 CEST 2009


OK cracked it, thanks for the pointer to the example in the Wiki Lars,
As a resault of this I have a simple exmpale whihc may be appropriate for
the Wiki.
It is a steady state lapace equation on a cube with natural Neumann
conditons on bottom and on two sides, inhomegeneous Neumann on the two
remaining sides and a Robin type condtion on the top.


I have some hints for other beginners like me,

1. in Fomulation:
Dof{u} is equivalent to test function, {u} is equivalent to trial function.

2.
the "Support" of the BasisFunction should be the whole domain, including
boundaries, its obvious really but it took me  long time to work it out.
I originally had the support based on a Physical Volume from the .geo file
but getdp gave zero solution. When I added the bounding surfaces of the
volume to the "Support" getdp worked.

3.
To define a neumann condition in the formulation use something like
      Galerkin { [ f_neumann_left[] , {phi} ] ; In left ; Jacobian Sur ;
Integration Int ; }

and for a Robin type condition use
      Galerkin { [ f_robin_top[]*Dof{phi} , {phi} ] ; In top ; Jacobian Sur
; Integration Int ; }

f_neumann_left[] and f_robin_top[] may be as simple as a constant.

Note that there was a typo in the previous post for the robin BC.



On Fri, Oct 16, 2009 at 8:25 AM, Thomas Ward
<tomwardathome at googlemail.com>wrote:

> many thanks Lars,
> yes it is normal to the boundary
> your example helped a lot, especially since you had shown the problem
> equation alongside the getdp code, it helped me to decipher the getdp
> syntax.
>
> so I think I need
>
>
> Formulation {
>   { Name f1 ; Type FemEquation ;
>     Quantity {
>       { Name phi ; Type Local ; NameOfSpace fs1 ; }
>     }
>     Equation {
>       Galerkin { [ Dof{d phi} , {d phi} ] ; In Omega ; Jacobian Vol ;
> Integration Int ; }
>       Galerkin { [ k*Dof{d phi} , {phi} ] ; In Top ; Jacobian Vol ;
> Integration Int ; }
>     }
>   }
> }
>
> regards
>
> Tom
>
>
>
> On Fri, Oct 16, 2009 at 7:27 AM, Lars Rindorf <Lars.Rindorf at teknologisk.dk
> > wrote:
>
>>  Hi Tom
>>
>>
>>
>>
>>
>> Is the spatial derivative normal or perpendicular to the 3D cube boundary?
>> If it is perpendicular, you can see the scatpar example. That is similar.
>>
>>
>>
>> Kr, Lars
>>
>>
>>
>> *Fra:* getdp-bounces at ace20.montefiore.ulg.ac.be [mailto:
>> getdp-bounces at ace20.montefiore.ulg.ac.be] *På vegne af *Thomas Ward
>> *Sendt:* 16. oktober 2009 08:20
>> *Til:* getdp at geuz.org
>> *Emne:* Re: [Getdp] How to define Robin boundary conditions
>>
>>
>>
>> oops that should have read ".... thanks to Christophe ..... "!
>>
>>  On Thu, Oct 15, 2009 at 5:01 PM, Thomas Ward <
>> tomwardathome at googlemail.com> wrote:
>>
>>
>> Probably a simple question but I can't find the answer in the examples of
>> the wiki or searching the list.
>>
>> I am trying to define a Robin type boundary condition for the Laplace
>> equation on a cube
>>
>> dphi/dz+constant*phi=0 on one face
>>
>> I think the weak form of this is
>> integral_over_face(test_function * trial_function*constant) =0
>>
>> can someone point me to an example of how to write this in the .pro file?
>> thanks
>>
>> and thanks to Christian for his public spiritedness over many years by the
>> look of the archives.
>>
>> Tom Ward
>>
>>
>>
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.geuz.org/pipermail/getdp/attachments/20091019/c7ed8a3e/attachment.html>


More information about the getdp mailing list