From 5aa7b3a38a973f58bbd70ae90196769d81d6fc2e Mon Sep 17 00:00:00 2001
From: Oliver Sander <sander@igpm.rwth-aachen.de>
Date: Fri, 3 Aug 2007 13:58:44 +0000
Subject: [PATCH] getResultantForce for a given BoundaryPatch

[[Imported from SVN: r1472]]
---
 src/rodassembler.hh | 15 +++++++++++++--
 1 file changed, 13 insertions(+), 2 deletions(-)

diff --git a/src/rodassembler.hh b/src/rodassembler.hh
index 9d1678f2..785e2bf2 100644
--- a/src/rodassembler.hh
+++ b/src/rodassembler.hh
@@ -5,6 +5,8 @@
 #include <dune/common/fmatrix.hh>
 #include <dune/istl/matrixindexset.hh>
 #include <dune/istl/matrix.hh>
+
+#include "../../common/boundarypatch.hh"
 #include "configuration.hh"
 
 namespace Dune 
@@ -124,8 +126,17 @@ namespace Dune
                                                  double pos) const;
                        
         
-        /** \brief Return resultant force in canonical coordinates */
-        FieldVector<double,3> getResultantForce(const std::vector<Configuration>& sol) const;
+        /** \brief Return resultant force across boundary in canonical coordinates 
+
+        \note Linear run-time in the size of the grid */
+        FieldVector<double,3> getResultantForce(const BoundaryPatch<GridType>& boundary, 
+                                                const std::vector<Configuration>& sol) const;
+
+        /** \brief Return resultant torque across boundary in canonical coordinates 
+
+        \note Linear run-time in the size of the grid */
+        FieldVector<double,3> getResultantTorque(const BoundaryPatch<GridType>& boundary, 
+                                                 const std::vector<Configuration>& sol) const;
 
     protected:
 
-- 
GitLab