← Back to team overview

dolfin team mailing list archive

Re: [Question #115533]: 2d dam break problem

 

Question #115533 on DOLFIN changed:
https://answers.launchpad.net/dolfin/+question/115533

    Status: Open => Answered

Anders Logg proposed the following answer:
On Wed, Jun 23, 2010 at 10:14:40AM -0000, Stefan Kurzbach wrote:
> New question #115533 on DOLFIN:
> https://answers.launchpad.net/dolfin/+question/115533
>
> Hello all,
>
> is it possible to simulate an advancing wet/dry element front in a fixed mesh using the existing implementation? An example is the solution of a dam break problem with 2d depth-averaged shallow water equations. Initially the mesh is completely dry. After the dam break, elements are included in the simulation once they become wet.
>
> Has anybody worked on a similar problem?
>
> Best regards
> Stefan

There's no automatic support for that so some manual work would have
to be involved. I suggest using a MeshFunction to mark which cells are
active and assemble only over those (using dx(0) or dx(1) in the form)
and then call A.ident_zeros() to insert 1 on the diagonal for the
inactive dofs so that you can solve the linear system. The inactive
dofs will then always be zero.

--
Anders

-- 
You received this question notification because you are a member of
DOLFIN Team, which is an answer contact for DOLFIN.