BELFEM
0.9.0
Berkeley Lab Finite Element Framework
Toggle main menu visibility
Loading...
Searching...
No Matches
fn_kelvin_christoffel.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_FN_KELVIN_CHRISTOFFEL_HPP
13
#define BELFEM_FN_KELVIN_CHRISTOFFEL_HPP
14
15
16
#include "
cl_Vector.hpp
"
17
#include "
cl_Matrix.hpp
"
18
#include "
cl_Tensor.hpp
"
19
#include "
fn_TR_kelvin_christoffel.hpp
"
20
21
namespace
belfem
22
{
23
//----------------------------------------------------------------------------
24
25
template
<
typename
T >
26
inline
void
27
kelvin_christoffel
(
const
Tensor< T >
& aA,
const
Vector< T >
& aB,
Matrix< T >
& aC )
28
{
29
BELFEM_ASSERT
( aA.
is_3333
(),
30
"operating tensor must be 3x3x3x3"
);
31
32
BELFEM_ASSERT
( aB.
length
() == 3,
33
"argument vector must be allocated as 3x1"
);
34
35
BELFEM_ASSERT
( aC.
n_rows
() == 3
36
&& aC.
n_cols
() == 3,
37
"target matrix must be allocated as 3x3"
);
38
39
// canonical mixed signature ( tensor data pointer, vector/matrix
40
// refs ) — the only form both backends provide; under Blaze the
41
// matrices are padded, so raw matrix pointers must not be used
42
tensor::kelvin_christoffel
( aA.
data
(), aB, aC );
43
}
44
45
//----------------------------------------------------------------------------
46
}
47
#endif
//BELFEM_FN_KELVIN_CHRISTOFFEL_HPP
BELFEM_ASSERT
#define BELFEM_ASSERT(aCheck,...)
Definition
assert.hpp:244
cl_Matrix.hpp
cl_Tensor.hpp
cl_Vector.hpp
belfem::Matrix
Dense column-major matrix.
Definition
cl_BZ_Matrix.hpp:28
belfem::Matrix::n_rows
size_t n_rows() const
Definition
cl_AR_Matrix.hpp:205
belfem::Matrix::n_cols
size_t n_cols() const
Definition
cl_AR_Matrix.hpp:213
belfem::Tensor
Third- or fourth-order tensor container; the constitutive helpers (contraction, rotation,...
Definition
cl_Tensor.hpp:43
belfem::Tensor::data
T * data()
expose the underlying raw pointer
Definition
cl_Tensor.hpp:211
belfem::Tensor::is_3333
bool is_3333() const
returns true if this is a 3x3x3x3 tensor
Definition
cl_Tensor.hpp:319
belfem::Vector
Column vector.
Definition
cl_BZ_Vector.hpp:41
belfem::Vector::length
size_t length() const
get the length of the vector
Definition
cl_AR_Vector.hpp:257
fn_TR_kelvin_christoffel.hpp
belfem::tensor::kelvin_christoffel
void kelvin_christoffel(const T *A, const T *B, T *C)
C_ik = A_ijkl * B_j * B_l.
Definition
fn_TR_kelvin_christoffel_arma.hpp:29
belfem
USER GUIDES:
Definition
cl_Capacitor.cpp:16
belfem::kelvin_christoffel
void kelvin_christoffel(const Tensor< T > &aA, const Vector< T > &aB, Matrix< T > &aC)
Definition
fn_kelvin_christoffel.hpp:27
src
math
tensor
fn_kelvin_christoffel.hpp
Generated by
1.18.0