Exemplo n.º 1
0
class TestMatrizMetodoDeGaussJordan(unittest.TestCase):


    def setUp(self):
        self.gj = GaussJordan(ordem=3)
        self.gj.termo_independente(b1=1, b2=2, b3=3)
        self.gj.set_matriz(a11= 3, a12=2, a13= 4, 
                           a21= 1, a22=1, a23= 2,
                           a31= 4, a32=3, a33=-2)

    def test_decompor_matriz_por_gauss_jordan(self):
        self.gj.calcular() |should| equal_to([-3.0, 5.0, 0.00])
Exemplo n.º 2
0
 def setUp(self):
     self.gj = GaussJordan(ordem=3)
     self.gj.termo_independente(b1=1, b2=2, b3=3)
     self.gj.set_matriz(a11= 3, a12=2, a13= 4, 
                        a21= 1, a22=1, a23= 2,
                        a31= 4, a32=3, a33=-2)