Access to time in compiled expressions in Python
Registered by
Garth Wells
It's common that an expression will have a (pseudo) time dependency. This is easy from C++, but from Python requires expensive callbacks to eval. We should add a C++ interface with time to make this easy. This could be done by adding time to the Data object.
Blueprint information
- Status:
- Complete
- Approver:
- None
- Priority:
- Undefined
- Drafter:
- None
- Direction:
- Needs approval
- Assignee:
- None
- Definition:
- Obsolete
- Series goal:
- None
- Implementation:
- Implemented
- Milestone target:
- None
- Started by
- Garth Wells
- Completed by
- Garth Wells
Related branches
Related bugs
Sprints
Whiteboard
Isn't this already supported? For example, the following should work:
f = Expression(
while t < T
f.t = t
...
JH:
I agree with Logg. Do you have a situation that requires a more elaborated handling via the data object?
(?)