commit 5d09dcba1bf156aec229062d2a36eb54a47455d6 Author: ketrptr Date: Mon Dec 9 10:40:54 2024 +0100 new file: README.md new file: testing/test.py diff --git a/README.md b/README.md new file mode 100644 index 0000000..cd7c583 --- /dev/null +++ b/README.md @@ -0,0 +1,27 @@ +# Authors + +- Juergen Buechel +- Carla Strassburger +- Jan Wild +- Simon Schurti + +# License + + MIT + +# Purpose + +Time management optimisation tool. + +# Procedure + +## User input + +- Ask user for subjects and study priority as well as available time to study per day. (days/hours) +- optional deadline for subjects + +## Processing + +- Use cake cutting algorithm to calculate timetable based on subject priorites and available time. + +- output in ical format diff --git a/testing/test.py b/testing/test.py new file mode 100644 index 0000000..8c0c0ff --- /dev/null +++ b/testing/test.py @@ -0,0 +1,24 @@ +components = { + "U1": ("0Ohm", "10V", "IU1"), + "R1": ("1e3Ohm", "UR1", "IR1"), + "R2": ("5e3Ohm", "UR2", "IR2"), +} +nodes = {"n1", "n2"} +connections = { + "U1": ["n1"], + "n1": ["R1", "R2"], + "R1": ["n2"], + "R2": ["n2"], + "n2": ["U1"], +} +nodeCoeffs = {} +for n in nodes: + nodeCoeffs[n] = [ + f"-{components[k][2]}" if n in v else f"{components[x][2]}" + for k, v in connections.items() + for x in v + if k == n or n in v + ] + + +print(nodeCoeffs)