Actual source code: meshMovementImpl.h

  1: /* $Id: meshimpl.h,v 1.12 2000/10/17 13:48:54 knepley Exp $ */
  2: /*
  3:   This file includes the definition of structures used in PETSc for 
  4:   meshes. This should not be included in users' code.
  5: */

  7: #ifndef __MESH_MOVEMENT_IMPL_H

 10:  #include petscsles.h
 11:  #include gvec.h

 13: struct _MeshMoverOps {
 14:       /* Generic Operations */
 15:   int (*setup)(MeshMover),
 16:       (*setfromoptions)(MeshMover),
 17:       (*destroy)(MeshMover),
 18:       /* Mesh-Specific Operations */
 19:       (*movemesh)(MeshMover, double),
 20:       (*updatenodevalues)(MeshMover, Vec, Vec, Vec),
 21:       (*reform)(Mesh, PetscTruth, PointFunction, PetscTruth, Mesh *);
 22: };

 24: struct _MeshMover {
 25:   PETSCHEADER(struct _MeshMoverOps)
 26:   Mesh            mesh;                            /*          The Mesh */
 27:   MeshSolveMethod meshVelocityMethod;              /*          Method used to solve for mesh velocities */
 28:   Grid            meshVelocityGrid;                /*          Representation of the mesh velocity */
 29:   Vec             nodeVelocities;                  /* [dN]:    The velocities of each node */
 30:   Vec             nodeVelocitiesGhost;             /* [dN]:    The velocities of each interior and ghost node (for coarsening) */
 31:   GMat            meshVelocityMat;                 /* [dNxdN]: The matrix which determines the new node velocities */
 32:   GVec            meshVelocityRhs;                 /* [dN]:    The rhs which determines the new node velocities */
 33:   GVec            meshVelocitySol;                 /* [dN]:    The solution which determines the new node velocities */
 34:   SLES            meshVelocitySles;                /*          Solver for the mesh velocity */
 35:   MeshSolveMethod meshAccelerationMethod;          /*          Method used to solve for mesh accelerations */
 36:   Grid            meshAccelerationGrid;            /*          Representation of the mesh acceleration */
 37:   Vec             nodeAccelerations;               /* [dN]:    The accelerations of each node */
 38:   Vec             nodeAccelerationsGhost;          /* [dN]:    The accelerations of each interior and ghost node (for coarsening) */
 39:   GMat            meshAccelerationMat;             /* [dNxdN]: The matrix which determines the new node accelerations */
 40:   GVec            meshAccelerationRhs;             /* [dN]:    The rhs which determines the new node accelerations */
 41:   GVec            meshAccelerationSol;             /* [dN]:    The solution which determines the new node accelerations */
 42:   SLES            meshAccelerationSles;            /*          Solver for the mesh acceleration */
 43:   VecScatter      meshVelocityScatter;             /*          The map from nodeVels/Acc to the ghost vector */
 44:   PetscViewer     movingMeshViewer;                /*          Viewer for visualizing mesh changes */
 45:   char           *movingMeshViewerCaption;         /*          Caption for moving mesh viewer (helps get time step in there) */
 46:   PetscObject     movingMeshCtx;                   /*          User context for mesh movement */
 47: };

 49: #endif /* __MESH_MOVEMENT_IMPL_H */