Compare commits
No commits in common. "33cd450bf89ed01a75941b166c86c897c1607865" and "888049460ecfe0e6b6436801a429c85aaf22b609" have entirely different histories.
33cd450bf8
...
888049460e
1
.gitignore
vendored
1
.gitignore
vendored
@ -1 +0,0 @@
|
|||||||
/matrixmania/dist/
|
|
||||||
@ -61,10 +61,10 @@ def transpose(matrix: list[list[int]]) -> list[list[int]]:
|
|||||||
return ergebnis2
|
return ergebnis2
|
||||||
|
|
||||||
|
|
||||||
def rot_2D(angle: int) -> List[List[float]]:
|
def rot_2D(angle: int) -> List[List[int]]:
|
||||||
"""
|
"""
|
||||||
Rotation matrix
|
Rotation matrix
|
||||||
:param angle: any angle in degrees
|
:param angle: any angle
|
||||||
:return: rotation matrix
|
:return: rotation matrix
|
||||||
"""
|
"""
|
||||||
zahl1 = math.cos(math.radians(angle))
|
zahl1 = math.cos(math.radians(angle))
|
||||||
@ -76,5 +76,5 @@ def rot_2D(angle: int) -> List[List[float]]:
|
|||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
"alles selbst gemacht"
|
#made by chatGBT
|
||||||
print(rot_2D())
|
print(rot_2D())
|
||||||
@ -1,16 +0,0 @@
|
|||||||
## Compute.py
|
|
||||||
### Functions:
|
|
||||||
**matmul(matrix_a, matrix_b):**
|
|
||||||
|
|
||||||
Multipliziert zwei Matrizen miteinander und gibt das Produkt als neue Matrix zurück.
|
|
||||||
Wirft einen ValueError, wenn die Matrizen aufgrund unpassender Dimensionen nicht multiplizierbar sind.
|
|
||||||
|
|
||||||
**transpose(matrix):**
|
|
||||||
|
|
||||||
Gibt die Transponierte einer gegebenen Matrix zurück (Zeilen und Spalten werden vertauscht).
|
|
||||||
Überprüft, ob die Matrix leer oder fehlerhaft aufgebaut ist, und wirft in diesem Fall einen ValueError.
|
|
||||||
|
|
||||||
**rot_2D(angle):**
|
|
||||||
|
|
||||||
Erzeugt eine 2D-Rotationsmatrix für einen gegebenen Winkel (in Grad).
|
|
||||||
Diese Matrix kann verwendet werden, um Punkte in der Ebene um den Ursprung zu rotieren.
|
|
||||||
@ -1 +0,0 @@
|
|||||||
from .compute import matmul, transpose, rot_2D
|
|
||||||
@ -1,17 +0,0 @@
|
|||||||
[project]
|
|
||||||
name = "matrixmania_marcel"
|
|
||||||
version = "0.1.0"
|
|
||||||
description = "MatrixMania: Simple linear algebra functions for teaching (matmul, transpose, rot_2D)."
|
|
||||||
|
|
||||||
authors = [
|
|
||||||
{ name="Dein Name", email="deine.mail@th-nuernberg.de" }
|
|
||||||
]
|
|
||||||
readme = "README.md"
|
|
||||||
license = { text = "MIT" }
|
|
||||||
requires-python = ">=3.7"
|
|
||||||
dependencies = ["tabulate"]
|
|
||||||
[build-system]
|
|
||||||
requires = ["hatchling"]
|
|
||||||
build-backend = "hatchling.build"
|
|
||||||
[tool.hatch.build.targets.wheel]
|
|
||||||
packages = ["matrixmania"]
|
|
||||||
Loading…
x
Reference in New Issue
Block a user