test/dictionary/testCalc: Added examples of lists and fields

// List of vectors example
listU           ((1.1 2.1 1.1) (2.1 3.2 4.1) (4.3 5.3 0));
magU1           #calc "mag($<List<vector>>listU[1])";

// Field of vectors and scalars example
magUs           #calc "mag($<Field<vector>>listU)";
magSqrU1        #calc "sqr($<Field<scalar>>magUs[1])";
This commit is contained in:
Henry Weller
2023-07-17 20:30:22 +01:00
parent 11fa5d1d15
commit 1f6ceeb3d6

View File

@ -67,4 +67,13 @@ Us #calc
os << Us;
#};
// List of vectors example
listU ((1.1 2.1 1.1) (2.1 3.2 4.1) (4.3 5.3 0));
magU1 #calc "mag($<List<vector>>listU[1])";
// Field of vectors and scalars example
#calcInclude "Field.H"
magUs #calc "mag($<Field<vector>>listU)";
magSqrU1 #calc "sqr($<Field<scalar>>magUs[1])";
// ************************************************************************* //