diff --git a/README.md b/README.md index f89a03a..8de0448 100644 --- a/README.md +++ b/README.md @@ -237,8 +237,8 @@ If enter third, fourth,... degrees equation. Error will occur! ⚠️ - This Command use to find tranpose of matrix. ````css - [1]: det[[1,2],[3,4]] - Determinant: -2 + [1]: tranpose[[1,2],[3,4]] + Tranpose Matrix: Matrix([[1, 3], [2, 4]]) ```` - **inverse**[expression] @@ -248,8 +248,9 @@ If enter third, fourth,... degrees equation. Error will occur! ⚠️ ````css - [1]: det[[1,2],[3,4]] - Determinant: -2 + [1]: inverse[[1,2],[3,4]] + Inverse Matrix: Matrix([[-2.0, 1.0], [1.5, -0.5]]) + NOTE: inverse of matrix 3x3 4x4 ... is not the precise but 2x2 is precise. ```` ⚠️**NOTE**⚠️ Some inverse to nxn matrix when n >= 3 sometimes not that precise. I will try to fix it again. diff --git a/main.py b/main.py index fc84050..96244ec 100644 --- a/main.py +++ b/main.py @@ -215,7 +215,10 @@ while True: except: print(f"Can't evaluate inverse of this matrix") colleted_dict["inverse"] = "" - + try: + write_command(todo, str(m1), colleted_dict) + except: + continue elif "det" in todo.lower(): try: @@ -260,7 +263,7 @@ while True: try: tran = m1.tranpose() print(f"Tranpose Matrix: {tran}") - write_command(todo, str(m1), tran) + write_command(todo, str(m1), str(tran)) except: print(f"Error Occur! Please enter input again!") write_command(todo, str(m1), "")