aboutsummaryrefslogtreecommitdiffstats
path: root/test/matrix_test.cpp
blob: a6974c7ffd8a9344ac6cb60137c5e1ad623c3ee4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#include "Math/matrix.hpp"

#include <iostream>

int main()
{
	yage::Matrix<4, 4, int> m1, m2;

	yage::Vector<2, int> v1, v2;

	yage::Vector2d v3;

	m1[0][1]=1;
	m2[1][1]=2;

	v1[0]=2;
	v1[1]=3;
	v2[0]=5;
	v2[1]=2;

	v2 += v1+v1;

	v3.x() = 2;
	v3.y() = 1;

	yage::matrix::multiply(m1, m2);

	std::cout<<m2<<'\n';
	std::cout<<v3<<'\n';

	return 0;
}