next up previous
Next: Sources and sinks of Up: User specified runtime routines Previous: User specified runtime routines

Active elements

To specify dynamic elastic constants of active entities, the IBIS code must indicate that an entity is active using the -A flag (see the IBIS programming guide). The user is also required to specify the dynamic properites in a FORTRAN subroutine.

This subroutine is called once for each active entity in a given time step. Therefore, if nine active entities are used, then actmov is called nine times before time is advanced. During the nth call to actmov, the data supplied to actmov corresponds to the immersed boundary and link information for the nth active entity. To help the user decide which entity is the current entity, a label for that entity is also provided. This label (an integer larger than zero) is specified in the IBIS program.

The following template MUST be used for this purpose.

c
      subroutine actmov
c
c  this routine performs the active motion on
c  entity n.
c
      include 'parm.inc'
      include 'active.inc'
      include 'domain.inc'
c
c  *** ALL VARIABLES MUST BE DECLARED ***
c
c
      return
      end

All of the data for actmov is provided in the common blocks found in the files active.inc and domain.inc. The structure of the common blocks should not be changed. actmov also uses the include file parm.inc. This file must not be modified.

The data that is supplied to the user in active.inc contains all the data that can be dynamically adjusted, and the data contained in domain.inc contains time and space variables that may be useful for actively changing the immersed boundry points. The contents of active.inc are;

      integer nels, elab
      double precision ibptx(nact),ibpty(nact)
      double precision vibptx(nact),vibpty(nact)
      double precision tethx(nact),tethy(nact)
      double precision stif(nact),restd(nact),tstiff(nact)
      double precision bndstf(nact),resta(nact)
c
      common /active0/ nels, elab
      common /active1/ ibptx,ibpty
      common /active1/ vibptx,vibpty
      common /active1/ tethx,tethy
      common /active1/ stif,restd,tstiff
      common /active1/ bndstf,resta

The variable nact is an upper bound on the number of immersed boundary points in any active entity. This is a parameter in the FORTRAN codes and cannot be modified.

The array valued data contain the same number of data values as the immersed boundary points in the current active entity. The data from active.inc and the global variables that are passed into the subroutine have the following definitions.

      nels    <- number of immersed boundary points in the entity
      elab    <- label of the current active entity (integer > 0)
      ibptx   <- x coordinates of the immersed boundary points
      ibpty   <- y coordinates of the immersed boundary points
      vibptx  <- first velocity coordinate of the immersed boundary points
      vibpty  <- second velocity coordinate of the immersed boundary points
      tethx   <- x coordinates of the tether point for (ibptx,ibpty)
      tethy   <- y coordinates of the tether point for (ibptx,ibpty)
      stif    <- elastic stiffness between current point and next point
      rest    <- elastic rest length between current point and next point
      tstiff  <- tether stiffness of between current point and its tether
      bndstf  <- elastic bending stiffness at the current point
      rest    <- elastic rest angle at the current point

If several active elements are used in a given calculation, the user evaluates the variable elab to decide the how the immersed boundary points and elastic properties are to be adjusted.

The data that is supplied to the user in domain.inc contains computational domain data. This data should not be modified, but treated as parameters for the calculation of the active properities of the immersed boundaries and elastic links. The contents of domain.inc are;

c
c  domain information
c
      double precision xlength,ylength
      double precision xmax,xmin,ymax,ymin
      common/domain/ xmin,xmax,ymin,ymax,xlength,ylength

      integer ibtube,ittube
      double precision ybot,ytop
      common/tube0/ ibtube,ittube
      common/tube1/ ybot,ytop

      integer ntstart, ntmax nt
      double precision h, dlt, dlibp, time
      common/step0/ntstart, ntmax, nt
      common/step1/h, dlt, dlibp, time
The data in domain.inc have the following definitions.
      h       <- fluid grid spacing 
      dlt     <- time step
      dlibp   <- approximate immersed boundary point spacing
      time    <- current time ( dlt*(nt+ntstart) )
      ibtube  <- bottom of a tube, if present (in grid dimensions)
      ittube  <- top of a tube, if present (in grid dimensions)
      ntstart <- integer start time
      ntmax   <- integer maximum time 
      nt      <- current time step
      xlength <- domain length in the x direction
      xmax    <- maximum value of x in the domain
      xmin    <- minimum value of x in the domain
      ylength <- domain length in the y direction
      ybot    <- domain coordinate of the bottom of the tube 
      ymax    <- maximum value of y in the domain
      ymin    <- minimum value of y in the domain
      ytop    <- domain coordinate of the top of the tube

When an entity is actively changed, this information is recorded and used in the numerical simulations from that time forward. For example, if the immersed boundary points are actively moved, then the forces they generate will be computed from their new positions. Similarly, if the elastic link parameters are changed then all future forces will be calculated using those changes. The only exception to this rule is that actively changing vibptx and vibpty has no effect on the calculation. Immersed boundary points or tether points should not be moved outside the boundaries of the domain. If this occurs, the calculation will proceed because the forces are calculated periodically, but the results may be confusing.


next up previous
Next: Sources and sinks of Up: User specified runtime routines Previous: User specified runtime routines
David Eyre
6/19/1998