filter

Module

Description

$Id$

Filters for smoothing, removing trends (like spurious build-up of horizontal momentum) and similar.

Quick access

Variables:

rmwig_1d, smooth_4th

Routines:

rmwig(), rmwig_xyaverage()

Needed modules

Variables

  • filter/rmwig_1d [private]
  • filter/smooth_4th [private]

Subroutines and functions

subroutine  filter/rmwig(f, df, ivar1, ivar2, awigg[, explog])

Remove small scale oscillations (`wiggles’) from a component of f, normally from lnrho. Sometimes necessary since Nyquist oscillations in lnrho do not affect the equation of motion at all (dlnrho=0); thus, in order to keep lnrho smooth one needs to smooth lnrho in sporadic time intervals.

Since this is a global operation, we need to do a full loop through

imn here (including communication and boundary conditions[?]) and collect the result in df, from where it is applied to f after the loop.

This version removes in the three directions consecutively (damping

each Nyquist frequency fully). This implies three instances of communication, but that seems to be the way to do it.

Note: Wolfgang believes that the necessity for using rmwig on lnrho

is no longer given, because upwinding solves the problem.

30-Aug-02/wolf: coded 28-jul-03/axel: moved to own module, allowed range ivar1-ivar2

Parameters:
  • f (,,*,*) [real,contiguous]

  • df (mx,my,mz,mvar) [real]

  • ivar1 [integer]

  • ivar2 [integer]

  • awigg [real]

  • explog [logical]

Use :

boundcond (boundconds_x(), boundconds_y(), boundconds_z())

Called from:

helper_loop(), reload(), gen_output(), timeloop(), start

Call to:

boundconds_x(), boundconds_y(), boundconds_z(), initiate_isendrcv_bdry(), finalize_isendrcv_bdry(), der6()

subroutine  filter/rmwig_xyaverage(f, ivar)

Removes wiggles from the xyaverage of variable ivar. This routine works currently only on one processor, which may not be too bad an approximation even several procs.

28-Sep-02/axel: coded

Parameters:
  • f (,,*,*) [real,contiguous]

  • ivar [integer]

Called from:

helper_loop(), reload(), gen_output(), timeloop()