Issue 58 in pencil-code: Damping not applied in ghost cells

2 views
Skip to first unread message

penci...@googlecode.com

unread,
Nov 25, 2010, 11:35:11 AM11/25/10
to pencil-co...@googlegroups.com
Status: New
Owner: Bourdin.KIS
Labels: Type-Review Priority-Medium

New issue 58 by Bourdin.KIS: Damping not applied in ghost cells
http://code.google.com/p/pencil-code/issues/detail?id=58

If you look in hydro.f90/subroutine udamping, you will find, that damping
is only applied to the physical cells, not the ghost cells.

If one has a boundary condition, which tries to have a smooth continuation
in the ghost cells, this means, that after damping (especially if damping
is strong) the continuation in the ghost cells is nomore smooth and strong
gradients can arise at the boundary.

I don't know if this is maybe even an intended feature for some of you, so
I just want to write this down and ask, if someone can review this issue,
please.

Note, that 'udamping' is being called relatively late in subroutine duu_dt
(short before diagnostics), but relatively early in the mn_loop in
equ.f90/subroutine pde.

So, as far as I can judge, the non-smooth boundaries can have undesirable
consequences - see attachment image, which are wiggels I can't remove by
applying more damping, nor with stronger diffusion or hyper3
diffusion/viscosity parameters. - Otherwise, this particular simulation is
in a very good hydrostatic equilibrium state.


penci...@googlecode.com

unread,
Nov 25, 2010, 11:39:17 AM11/25/10
to pencil-co...@googlegroups.com
Updates:
Labels: -Type-Review Type-Defect

Comment #1 on issue 58 by Bourdin.KIS: Damping not applied in ghost cells
http://code.google.com/p/pencil-code/issues/detail?id=58

(No comment was entered for this change.)

Attachments:
persistent-wiggles-lower-boundary.png 6.1 KB

penci...@googlecode.com

unread,
Nov 25, 2010, 3:40:10 PM11/25/10
to pencil-co...@googlegroups.com

Comment #2 on issue 58 by wdobler: Damping not applied in ghost cells
http://code.google.com/p/pencil-code/issues/detail?id=58

Are you sure that applying udamp to the ghost cells would help? I think it
would not make a difference at all.

We
(1) apply the boundary conditions to set the ghost cell values,
(2) then calculate all required derivatives,
(3) and apply velocity damping.

An extra item
(4) apply damping to the ghost cells (or do /anything/ to the ghost cells)
will not have any effects, because before calculating derivatives for the
next time, we apply the boundary conditions again and thus erase any
information that may have been in the ghost cells.

penci...@googlecode.com

unread,
Nov 25, 2010, 4:14:42 PM11/25/10
to pencil-co...@googlegroups.com

Comment #3 on issue 58 by Bourdin.KIS: Damping not applied in ghost cells
http://code.google.com/p/pencil-code/issues/detail?id=58

I'm not sure, in how far the values from the ghost cells are relevant/being
used _after_ the velocity damping and before the next mn_loop. After the
udamping call I just see a lot of relevant code - of which I don't know
large parts. Therefor this request for comments.

True, the derivatives are stored in the df-array before the udamping call.
So you say, I can be sure that even if I would completely destroy the ghost
cells after the damping, it should not have any effect? ...this could be
tested.

Reply all
Reply to author
Forward
0 new messages