BELFEM
0.9.0
Berkeley Lab Finite Element Framework
Toggle main menu visibility
Loading...
Searching...
No Matches
op_AR_VectorElementwiseMultiplication.hpp
Go to the documentation of this file.
1
/*
2
* BELFEM -- The Berkeley Lab Finite Element Framework
3
* Copyright (c) 2026, The Regents of the University of California,
4
* through Lawrence Berkeley National Laboratory (subject to receipt of any required
5
* approvals from the U.S. Dept. of Energy). All rights reserved.
6
*
7
* Developers: Christian Messe, Gregory Giard
8
*
9
* See the top-level LICENSE file for the complete license and disclaimer.
10
*/
11
12
#ifndef BELFEM_OP_AR_VECTORELEMENTWISEMULTIPLICATION_HPP
13
#define BELFEM_OP_AR_VECTORELEMENTWISEMULTIPLICATION_HPP
14
15
#include "
cl_AR_Vector.hpp
"
16
17
namespace
belfem
18
{
19
//------------------------------------------------------------------------------
20
template
<
typename
T >
21
auto
22
operator%
(
23
const
Vector<T>
& aA,
24
const
Vector<T>
& aB )
25
->
decltype
( aA.vector_data() % aB.vector_data())
26
{
27
return
aA.vector_data() % aB.vector_data();
28
}
29
30
//--------------------------------------------------------------------------------
31
32
template
<
typename
T >
33
auto
34
operator%
(
const
arma::Mat<T> & aA,
const
arma::Mat<T> & aB )
35
->
decltype
( aA.data() % aB.data())
36
{
37
return
aA.data() % aB.data();
38
}
39
40
//--------------------------------------------------------------------------------
41
42
template
<
typename
T,
typename
ET >
43
auto
44
operator%
(
const
Vector<T>
& aA,
const
ET & aB )
45
->
decltype
( aA.vector_data() % aB )
46
{
47
return
aA.vector_data() % aB;
48
}
49
50
//--------------------------------------------------------------------------------
51
52
template
<
typename
ET,
typename
T >
53
auto
54
operator%
(
const
ET & aA,
const
Vector<T>
& aB )
55
->
decltype
( aA % aB.vector_data())
56
{
57
return
aA % aB.vector_data();
58
}
59
60
//--------------------------------------------------------------------------------
61
62
}
63
#endif
//BELFEM_OP_AR_VECTORELEMENTWISEMULTIPLICATION_HPP
cl_AR_Vector.hpp
belfem::Vector
Column vector.
Definition
cl_BZ_Vector.hpp:41
belfem
USER GUIDES:
Definition
cl_Capacitor.cpp:16
belfem::operator%
auto operator%(const Vector< T > &aA, const Vector< T > &aB) -> decltype(aA.vector_data() % aB.vector_data())
Definition
op_AR_VectorElementwiseMultiplication.hpp:22
src
linalg
armadillo
op_AR_VectorElementwiseMultiplication.hpp
Generated by
1.18.0