]> gitweb.michael.orlitzky.com - octave.git/blobdiff - tests/poisson_matrix_tests.m
Move all of the tests into a subdirectory.
[octave.git] / tests / poisson_matrix_tests.m
diff --git a/tests/poisson_matrix_tests.m b/tests/poisson_matrix_tests.m
new file mode 100644 (file)
index 0000000..4b50b2e
--- /dev/null
@@ -0,0 +1,9 @@
+expected_A = [-1, 0, 0, 0, 0; ...
+              -16, 32,  -16,  0,  0; ...
+             0,   -16, 32,  -16, 0; ...
+             0,   0,   -16, 32, -16; ...
+             0,   0,   0,   0,  -1];
+
+unit_test_equals("Homework #1 problem #1 Poisson matrix is correct", ...
+                true, ...
+                expected_A == poisson_matrix(4, 0, 1));