99 * Copyright 2010 B.D.Dudson, S.Farley, M.V.Umansky, X.Q.Xu
1010 *
1111 * Contact: Ben Dudson, bd512@york.ac.uk
12- *
12+ *
1313 * This file is part of BOUT++.
1414 *
1515 * BOUT++ is free software: you can redistribute it and/or modify
@@ -45,10 +45,10 @@ class Vector2D;
4545 * -------
4646 *
4747 * Vector3D f;
48- *
48+ *
4949 * a.x; // Error! a.x not allocated
5050 *
51- *
51+ *
5252 */
5353class Vector3D : public FieldData {
5454public:
@@ -70,7 +70,7 @@ public:
7070 ~Vector3D () override ;
7171
7272 /* !
73- * The components of the vector. These can be
73+ * The components of the vector. These can be
7474 * either co- or contra-variant, depending on
7575 * the boolean flag "covariant"
7676 */
@@ -92,8 +92,8 @@ public:
9292 bool covariant{true };
9393
9494 /* !
95- * In-place conversion to covariant form.
96- *
95+ * In-place conversion to covariant form.
96+ *
9797 * If already covariant (covariant = true) then does nothing
9898 * If contravariant, multiplies by metric tensor g_{ij}
9999 */
@@ -104,7 +104,7 @@ public:
104104 *
105105 * If already contravariant (covariant = false) then does nothing
106106 * If covariant, multiplies by metric tensor g^{ij}
107- *
107+ *
108108 */
109109 void toContravariant ();
110110
@@ -114,14 +114,14 @@ public:
114114 * The first time this is called, a new Vector3D object is created.
115115 * Subsequent calls return a pointer to this same object
116116 *
117- * For convenience, a standalone function "ddt" exists, so that
117+ * For convenience, a standalone function "ddt" exists, so that
118118 *
119119 * ddt(v) is equivalent to *(v.timeDeriv())
120- *
120+ *
121121 * This does some book-keeping to ensure that the time derivative
122122 * of the components is the same as the components of the time derivative
123123 *
124- * ddt(v).x == ddt(v.x)
124+ * ddt(v).x == ddt(v.x)
125125 */
126126 Vector3D* timeDeriv ();
127127
@@ -172,7 +172,7 @@ public:
172172 CELL_LOC getLocation () const override ;
173173
174174 // FieldData virtual functions
175- bool is3D () const override { return true ; }
175+ FieldType field_type () const override { return FieldType::field3d ; }
176176 int elementSize () const override { return 3 ; }
177177
178178 void applyBoundary (bool init = false ) override ;
@@ -203,7 +203,7 @@ const Vector3D cross(const Vector3D& lhs, const Vector2D& rhs);
203203
204204/* !
205205 * Absolute magnitude (modulus) of a vector |v|
206- *
206+ *
207207 * sqrt( v.x^2 + v.y^2 + v.z^2 )
208208 */
209209const Field3D abs (const Vector3D& v, const std::string& region = " RGN_ALL" );
0 commit comments