From 1f6ceeb3d69b6d098e2bb1dbb5e8567b0f62a824 Mon Sep 17 00:00:00 2001 From: Henry Weller Date: Mon, 17 Jul 2023 20:30:22 +0100 Subject: [PATCH] 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($>listU[1])"; // Field of vectors and scalars example magUs #calc "mag($>listU)"; magSqrU1 #calc "sqr($>magUs[1])"; --- test/dictionary/testCalc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/dictionary/testCalc b/test/dictionary/testCalc index 3709da18f0..8f54d65d65 100644 --- a/test/dictionary/testCalc +++ b/test/dictionary/testCalc @@ -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($>listU[1])"; + +// Field of vectors and scalars example +#calcInclude "Field.H" +magUs #calc "mag($>listU)"; +magSqrU1 #calc "sqr($>magUs[1])"; + // ************************************************************************* //