#include <vector>
template <typename number> class Vector;
-
+template <int dim> class Point;
// general template; specialized for rank==1; the general template is in
// tensor.h
* which acts as a tensor of rank one but has more functionality.
*/
template <int dim>
-class Tensor<1,dim> {
+class Tensor<1,dim>
+{
public:
/**
* Provide a way to get the
void unroll (Vector<double> &result) const;
protected:
- /**
- * Store the values in a simple array.
- * For @p{dim==0} store one element, because
- * otherways the compiler would choke.
- * We catch this case in the constructor
- * to disallow the creation of such
- * an object.
- */
- double values[(dim!=0) ? (dim) : 1];
-
/**
* Help function for unroll.
*/
// the function unroll_loops a friend,
// but that seems to be impossible as well.
template<int otherrank, int otherdim> friend class Tensor;
+
+ private:
+ /**
+ * Store the values in a simple array.
+ * For @p{dim==0} store one element, because
+ * otherways the compiler would choke.
+ * We catch this case in the constructor
+ * to disallow the creation of such
+ * an object.
+ */
+ double values[(dim!=0) ? (dim) : 1];
+
+ /**
+ * Point is allowed access to
+ * the coordinates. This is
+ * supposed to improve speed.
+ */
+ friend class Point<dim>;
};
/**
@echo =====optimized===== $<
@$(CXX) $(flags) -c $< -o $@
-all: full_matrix.check solver.check mgbase.check mg.check
+
+# mgbase.check mg.check are removed until the sutructure of the
+# multigrid classes will be fixed.
+all: full_matrix.check solver.check
exe: $(all:.check=.testcase) benchmark
run: $(all:.check=.output)