norm
Overview
The norm function object normalises an input field with
a chosen norm, and writes a new normalised field.
Usage
Example of function object specification:
norm1
{
// Mandatory entries
type norm;
libs (fieldFunctionObjects);
field <word>;
norm <word>;
// Conditional entries
// When norm = Lp
p <scalar>;
// When norm = composite
divisor <Function1<scalar>>;
// When norm = divisorField
divisorField <word>;
// Inherited entries
...
}
where the entries mean:
| Property | Description | Type | Required | Default |
|---|---|---|---|---|
type | Type name: norm | word | yes | - |
libs | Library name: fieldFunctionObjects | word | yes | - |
field | Name of the operand field | word | yes | - |
norm | Name of normalisation operation | word | yes | - |
p | Norm exponent for the p-norm | scalar | conditional | - |
divisor | Norm divisor for the composite norm | Function1<scalar> | conditional | - |
divisorField | Divisor scalar field for the field norm | word | conditional | - |
Options for the norm entry:
| Property | Description | Expression |
|---|---|---|
L1 | L1/Taxicab norm | |
L2 | L2/Euclidean norm | |
Lp | p norm | |
max | Maximum norm | |
composite | Composite norm with Function1 divisor | |
divisorField | Normalise by field |
The inherited entries are elaborated in:
- functionObject
- fieldExpression
- Function1
Divisor quantity is perturbed by SMALL value to prevent any divisions
by zero irrespective of whether the quantity is close to zero or not.
Operands
| Operand | Type | Location |
|---|---|---|
| Input | {vol,surface,polySurface}<Type>Field | <case>/<time>/ |
| Output file | - | - |
| Output field | {vol,surface,polySurface}<Type>Field | <case>/<time>/ |
where <Type>={Scalar,Vector,SphericalTensor,SymmTensor,Tensor}.
Further information
Tutorial:
Source code:
API:
History: Introduced in version v2206