mirror of
https://github.com/Sosokker/Calculator-for-Matrix-and-Algebra.git
synced 2025-12-18 12:44:05 +01:00
update readme, main.py
This commit is contained in:
parent
8eccc253d1
commit
419234ec62
@ -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]])
|
||||
````
|
||||
|
||||
- <span style="color:yellow">**inverse**[<span style="color:lightblue">expression</span>]</span>
|
||||
@ -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.
|
||||
|
||||
|
||||
7
main.py
7
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), "")
|
||||
|
||||
Loading…
Reference in New Issue
Block a user