Loading [MathJax]/extensions/AMSmath.js
v0.14.0
Main Page
Why MoFEM
Features
Applications
Publications
Installation
Installation with Docker - JupyterHub
Installation with Docker - Advanced
Installation with Spack - Scripts
Installation with Spack - Advanced
Videos
UKACM School 2023
UKACM School 2021
Video guides
Conference talks
Simulation examples
Developer
Architecture
Tutorials
Operators
Frequently Asked Questions
Writing documentation
Coding practice
Search
Source Code
Source files
Source groups
Examples
Jenkins
CDash
Related Pages
Modules
Q&A
Repository
Library
About
Authors
Contact
Legal stuff
Contributing
Vacancies
Third party libraries
Acknowledgments
Bibliography
•
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
src
ftensor
tests
conformance
T2
test_T2_26.cpp
Go to the documentation of this file.
1
#include "../../../src/FTensor.hpp"
2
#include "../test_for_zero.hpp"
3
#include <iostream>
4
using namespace
FTensor
;
5
using namespace
std
;
6
7
void
test_T2_26
(
const
Tensor2<double, 4, 3>
&t2_4,
8
const
Tensor2<double, 3, 4>
&t2_5)
9
{
10
Index<'i', 3>
i
;
11
Index<'j', 4>
j
;
12
Index<'k', 3>
k
;
13
14
Tensor2<double, 3, 3>
t2;
15
t2(
i
,
k
) = t2_5(
i
,
j
) * t2_4(
j
,
k
);
16
17
for
(
int
ii = 0; ii < 3; ++ii)
18
for
(
int
kk = 0; kk < 3; ++kk)
19
{
20
test_for_zero
(
21
t2(ii, kk)
22
- (t2_5(ii, 0) * t2_4(0, kk) + t2_5(ii, 1) * t2_4(1, kk)
23
+ t2_5(ii, 2) * t2_4(2, kk) + t2_5(ii, 3) * t2_4(3, kk)),
24
"T2(i,j)*T2(j,k)("
+ std::to_string(ii) +
","
+ std::to_string(kk)
25
+
")"
);
26
}
27
}
FTensor
JSON compatible output.
Definition:
Christof_constructor.hpp:6
FTensor::Tensor2
Definition:
Tensor2_value.hpp:16
test_T2_26
void test_T2_26(const Tensor2< double, 4, 3 > &t2_4, const Tensor2< double, 3, 4 > &t2_5)
Definition:
test_T2_26.cpp:7
test_for_zero
void test_for_zero(const T &t, const std::string &s)
Definition:
test_for_zero.hpp:7
i
FTensor::Index< 'i', SPACE_DIM > i
Definition:
hcurl_divergence_operator_2d.cpp:27
FTensor::Index< 'i', 3 >
std
Definition:
enable_if.hpp:5
j
FTensor::Index< 'j', 3 > j
Definition:
matrix_function.cpp:19
k
FTensor::Index< 'k', 3 > k
Definition:
matrix_function.cpp:20
Generated by
Doxygen
1.8.17 and hosted at