Generated from /asc/home/flashdocs/FLASH3_33/source/Grid/Grid_computeVarNorm.F90 with ROBODoc v4.99.8 on Wed Oct 20 17:16:49 2010

**NAME**

Grid_computeVarNorm

**SYNOPSIS**

call Grid_computeVarNorm(integer(in) :: level, integer(in) :: normType, integer(in) :: ivar, real(out) :: norm, integer(in) :: leafOnly)

**DESCRIPTION**

Computes the L1 or L2 norm of the variable specified by ivar. This can be done per-level, or on leaf or all nodes. For multigrid, the L2 norm is used for convergence, but the L1 norm is incredibly useful for debugging purposes.

**ARGUMENTS**

level - If the norm is restricted to a given level; 0 is all normType - p in the Lp norm where choices of p are 1 or 2 ivar - the grid variable being normed; -1 for work norm - the variable with which to return the norm leafOnly - if this isn't 0, compute the norm only on leaf nodes

**RESULT**

The norm of ivar is in norm.

**EXAMPLE**

gr_restrictTree() do i = 1, lrefine_max call Grid_computeVarNorm(i, 1, pdens, norm(i), 0) enddo do i = 1, lrefine_max if (norm(0) - norm(i) > 0.0000001) then driver_abortFlash("restriction is highly nonconservatory!") endif enddo

High-Energy Density Physics

Thermonuclear-Powered Supernovae

Fluid-Structure Interaction

Implicit Solvers

Code Requests

Download

Contributed code

Flash Test downloads

Visualization downloads

Documentation and User Support

Publications

FLASH internal

The Flash Center for Computational Science is based at the University of Chicago and is supported by U.S. DOE and NSF.