v0.14.0
Classes | Functions
single.cpp File Reference
#include <iostream>
#include <ostream>

Go to the source code of this file.

Classes

class  Index< i >
 
class  Tensor1_Expr< A, i >
 
class  Tensor1
 

Functions

ostream & operator<< (ostream &s, const Tensor1 &a)
 
int main ()
 

Function Documentation

◆ main()

int main ( )

Definition at line 70 of file single.cpp.

71 {
72  Tensor1 y(0, 1, 2);
73  Tensor1 x(2, 3, 4);
74  const Index<'i'> i;
75 
76  y(i) = x(i);
77 
78  cout << y << endl;
79 }

◆ operator<<()

ostream& operator<< ( ostream &  s,
const Tensor1 a 
)

Definition at line 65 of file single.cpp.

66 {
67  return s << a.data0 << " " << a.data1 << " " << a.data2 << " ";
68 }
Index
Definition: single.cpp:3
a
constexpr double a
Definition: approx_sphere.cpp:30
i
FTensor::Index< 'i', SPACE_DIM > i
Definition: hcurl_divergence_operator_2d.cpp:27
Tensor1
Definition: single.cpp:40