From: ndjinga Date: Wed, 12 Dec 2007 10:36:29 +0000 (+0000) Subject: Doxygen: added picture of a mesh and corresponding interpolation matrix X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=3aeaae54fb866103f4e34944e6885dff181472bd;p=tools%2Fmedcoupling.git Doxygen: added picture of a mesh and corresponding interpolation matrix --- diff --git a/src/ParaMEDMEM/IntersectionDEC.cxx b/src/ParaMEDMEM/IntersectionDEC.cxx index 00569ecd2..e63900829 100644 --- a/src/ParaMEDMEM/IntersectionDEC.cxx +++ b/src/ParaMEDMEM/IntersectionDEC.cxx @@ -18,10 +18,14 @@ \section overview Overview -The IntersectionDEC enables the \ref conservativeremapping of fields between two parallel codes. This remapping is based on the computation of intersection volumes between elements from code A and elements from code B. The computation is possible for 3D meshes, 2D meshes, and 3D-surface meshes. Dimensions must be similar for code A and code B (for instance, though it could be desirable, it is not yet possible to couple 3D surfaces to 2D surfaces). +The IntersectionDEC enables the \ref conservativeremapping of fields between two parallel codes. This remapping is based on the computation of intersection volumes between elements from code A and elements from code B. The computation is possible for 3D meshes, 2D meshes, and 3D-surface meshes. Dimensions must be similar for code A and code B (for instance, though it could be desirable, it is not yet possible to couple 3D surfaces with 2D surfaces). In the present version, only fields lying on elements are considered. +\image html NonCoincident_small.png "Example showing the transfer from a field based on a quadrangular mesh to a triangular mesh. In a P0-P0 interpolation, to obtain the value on a triangle, the values on quadrangles are weighted by their intersection area and summed." + +\image latex NonCoincident_small.eps "Example showing the transfer from a field based on a quadrangular mesh to a triangular mesh. In a P0-P0 interpolation, to obtain the value on a triangle, the values on quadrangles are weighted by their intersection area and summed." + A typical use of IntersectionDEC encompasses two distinct phases : - A setup phase during which the intersection volumes are computed and the communication structures are setup. This corresponds to calling the IntersectionDEC::synchronize() method. - A use phase during which the remappings are actually performed. This corresponds to the calls to sendData() and recvData() which actually trigger the data exchange. The data exchange are synchronous in the current version of the library so that recvData() and sendData() calls must be synchronized on code A and code B processor groups. @@ -39,12 +43,23 @@ else if (groupB.containsMyRank()) dec.sendData(); ... \endcode - A \ref conservativeremapping of the field from the source mesh to the target mesh is performed by the function synchronise(), which computes the \ref remappingmatrix . + A \ref conservativeremapping of the field from the source mesh to the target mesh is performed by the function synchronise(), which computes the \ref remappingmatrix. Computing the field on the receiving side can be expressed in terms of a matrix-vector product : \f$ \phi_t=W.\phi_s\f$, with \f$ \phi_t \f$ the field on the target side and \f$ \phi_s \f$ the field on the source side. +When remapping a 3D surface to another 3D surface, a projection phase is necessary to match elements from both sides. Care must be taken when defining this projection to obtain a \ref conservative remapping. + +In the P0-P0 case, this matrix is a plain rectangular matrix with coefficients equal to the intersection areas between triangle and quadrangles. For instance, in the above figure, the matrix is : + +\f[ +\begin{tabular}{|cccc|} +0.72 & 0 & 0.2 & 0 \\ +0.46 & 0 & 0.51 & 0.03\\ +0.42 & 0.53 & 0 & 0.05\\ +0 & 0 & 0.92 & 0.05 \\ +\end{tabular} +\f] +*/ -\section surface Special features for 3D surface remapping -When remapping a 3D surface to another 3D surface, a projection phase is necessary to match elements from both sides. Care must be taken when defining this projection to avoid non conservative remappings. * \section intersectiondec_options Options * On top of \ref dec_options, options supported by IntersectionDEC objects are