diff --git a/src/foam/primitives/VectorN/expandContract/ExpandTensorNI.H b/src/foam/primitives/VectorN/expandContract/ExpandTensorNI.H index 9f9fec5ad..9d89795cc 100644 --- a/src/foam/primitives/VectorN/expandContract/ExpandTensorNI.H +++ b/src/foam/primitives/VectorN/expandContract/ExpandTensorNI.H @@ -358,6 +358,8 @@ inline void sumMagToDiag const TensorN& t ) { + result = VectorN::zero; + for (register int i = 0; i < TensorN::rowLength; i++) { for (register int j = 0; j < TensorN::rowLength; j++)