]> gitweb.factorcode.org Git - factor.git/blob - extra/math/vectors/homogeneous/homogeneous-tests.factor
142f80e23ef02bcb0e9c42be62655cffa3a1dae1
[factor.git] / extra / math / vectors / homogeneous / homogeneous-tests.factor
1 ! (c)2009 Joe Groff bsd license
2 USING: math.vectors.homogeneous tools.test ;
3 IN: math.vectors.homogeneous.tests
4
5 { { 1.0 2.0 1.0 } } [ { 1.0 0.0 1.0 } { 0.0 2.0 1.0 } h+ ] unit-test
6 { { 1.0 -2.0 1.0 } } [ { 1.0 0.0 1.0 } { 0.0 2.0 1.0 } h- ] unit-test
7 { { 2.0 2.0 2.0 } } [ { 1.0 0.0 1.0 } { 0.0 2.0 2.0 } h+ ] unit-test
8 { { 1.0 2.0 2.0 } } [ { 1.0 0.0 2.0 } { 0.0 2.0 2.0 } h+ ] unit-test
9
10 { { 2.0 4.0 2.0 } } [ 2.0 { 1.0 2.0 2.0 } n*h ] unit-test
11 { { 2.0 4.0 2.0 } } [ { 1.0 2.0 2.0 } 2.0 h*n ] unit-test
12
13 { { 0.5 1.5 } } [ { 1.0 3.0 2.0 } h>v ] unit-test
14 { { 0.5 1.5 1.0 } } [ { 0.5 1.5 } v>h ] unit-test
15 { { 0.5 1.5 1.0 } } [ { 0.5 1.5 } v>h ] unit-test