Variables and domains
Let’s make it simple
A variable will be referenced by a key, its name.
A domain will be associated to it.
Beware: each value can appear only once.
A dictionary and sets will do :
>>🥛<<
This clickable logo indicates that a workshop is available at Caseine
A dictionary and sets will do :
variables = {"x1": {1, 2, 3},
"x2": {1, 2, 3}}
and that’s enough.
🚀 Possible improvements
- Creating a variable object
- Effective domain representation (e.g., bitset)
- Introducing variable views (e.g., $y = a.x + b$)
- Other types of variable (e.g., Boolean, set, graph)