1%%%%%%%%%%%%%%%%%%%
2% XLiFE++ is an extended library of finite elements written in C++
3%     Copyright (C) 2014  Lunéville, Eric; Kielbasiewicz, Nicolas; Lafranche, Yvon; Nguyen, Manh-Ha; Chambeyron, Colin
4%
5%     This program is free software: you can redistribute it and/or modify
6%     it under the terms of the GNU General Public License as published by
7%     the Free Software Foundation, either version 3 of the License, or
8%     (at your option) any later version.
9%     This program is distributed in the hope that it will be useful,
10%     but WITHOUT ANY WARRANTY; without even the implied warranty of
11%     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12%     GNU General Public License for more details.
13%     You should have received a copy of the GNU General Public License
14%     along with this program.  If not, see <http://www.gnu.org/licenses/>.
15%%%%%%%%%%%%%%%%%%%
16
17\section{The {\classtitle KernelOperatorOnTermVector} class}
18To deal with integral representation, say for instance
19$$v(x) = \int_{\Gamma}K(x,y)\,\varphi(y)$$
20where $\varphi$ will be represented by a {\class TermVector} object F, the user can define the linear form
21$$\int_{\Gamma}K(x,y)\,u(y)$$
22and then call the {\var integralRepresentation} function to link its {\class TermVector} object F to the linear form. To make the user life easier, \xlifepp provides a small class {\class KernelOperatorOnTermVector} that relates a {\class OperatorOnKernel} and a {\class TermVector}. So, writing {\cmd intg(gamma, K*F)} will be interpreted as the linear form acting to the {\class TermVector} F by handling in the back a {\class KernelOperatorOnTermVector}:\\
23\vspace{.1cm}
24\begin{lstlisting}[]{}
25class KernelOperatorOnTermvector
26{
27 protected:
28 OperatorOnKernel opker_; //Kernel operator
29 AlgebraicOperator aop_;  //operation (*,|,%,^) between kernel and TermVector
30 const TermVector*  tv_;  //TermVector involved
31 public:
32 bool termAtLeft;         //if true : opker aop tv else :  tv aop opker
33}
34\end{lstlisting}
35\vspace{.2cm}
36The class provides one basic constructor and some accessors:
37\vspace{.1cm}
38\begin{lstlisting}[]{}
39KernelOperatorOnTermvector(const OperatorOnKernel&, AlgebraicOperator,
40                           const TermVector&, bool atleft);
41AlgebraicOperator algop();
42AlgebraicOperator& algop();
43const OperatorOnKernel& opker() const;
44const TermVector*  termVector();
45ValueType valueType() const;;
46bool xnormalRequired() const;
47bool ynormalRequired() const;
48\end{lstlisting}
49\vspace{.2cm}
50Besides, extern functions to the class manage the various operation involving kernel and TermVector:
51\vspace{.1cm}
52\begin{lstlisting}[]{}
53KernelOperatorOnTermvector operator*(const TermVector&, const Kernel&);
54KernelOperatorOnTermvector operator|(const TermVector&, const Kernel&);
55KernelOperatorOnTermvector operator^(const TermVector&, const Kernel&);
56KernelOperatorOnTermvector operator%(const TermVector&, const Kernel&);
57KernelOperatorOnTermvector operator*(const Kernel&, const TermVector&);
58...
59KernelOperatorOnTermvector operator*(const TermVector&, const OperatorOnKernel&);
60...
61KernelOperatorOnTermvector operator*(const OperatorOnKernel&, const TermVector&);
62...
63OperatorOnUnknown toOperatorOnUnknown(const KernelOperatorOnTermvector&);
64\end{lstlisting}
65\vspace{.2cm}
66Finally, to build integral involving {\class KernelOperatorOnTermvector} some pseudo-constructors are provided
67\vspace{.1cm}
68\begin{lstlisting}[]{}
69std::pair<LinearForm,const TermVector*>
70intg(const GeomDomain&, const KernelOperatorOnTermvector&,const IntegrationMethod&);
71std::pair<LinearForm,const TermVector*>
72intg(const GeomDomain&, const KernelOperatorOnTermvector&,const IntegrationMethods&);
73std::pair<LinearForm,const TermVector*>
74intg(const GeomDomain&, const KernelOperatorOnTermvector&,QuadRule = _defaultRule, number_t =0);
75\end{lstlisting}
76\vspace{.2cm}
77
78\displayInfos{library=term, header=KernelOperatorOnTermVector.hpp, implementation=KernelOperatorOnTermVector.cpp,
79test=test\_operator.cpp, header dep={OperatorOnKernel.hpp, TermVector.hpp, config.h, utils.h}}
80
81