Skip to content

Commit

Permalink
TEST: Lower tolerance on the compute stationary matrices.
Browse files Browse the repository at this point in the history
  • Loading branch information
cc7768 committed Sep 9, 2014
1 parent f580b4c commit 3e6a0ab
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions quantecon/tests/test_lqcontrol.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ def test_mat_sequences(self):

x_seq, u_seq, w_seq = lq_mat.compute_sequence(x0)

assert_allclose(np.sum(u_seq), .95 * np.sum(x0), rtol=1e-4)
assert_allclose(x_seq[:, -1], np.zeros_like(x0), rtol=1e-4)
assert_allclose(np.sum(u_seq), .95 * np.sum(x0), atol=1e-3)
assert_allclose(x_seq[:, -1], np.zeros_like(x0), atol=1e-3)


def test_stationary_mat(self):
Expand All @@ -83,8 +83,8 @@ def test_stationary_mat(self):
val_func_lq = np.dot(x0, P).dot(x0)
val_func_answer = x0[0]**2

assert_allclose(f_answer, F, rtol=1e-4)
assert_allclose(val_func_lq, val_func_answer, rtol=1e-4)
assert_allclose(f_answer, F, atol=1e-3)
assert_allclose(val_func_lq, val_func_answer, atol=1e-3)



Expand Down

0 comments on commit 3e6a0ab

Please sign in to comment.