demisjohn / pyFIMM

Python Interface to PhotonDesign's FimmWave/FimmProp software.
15 stars 4 forks source link

Resolve variables #85

Open demisjohn opened 8 years ago

demisjohn commented 8 years ago

Need a function to check variables (only if a variables node is set for the project).

A workaround to check a variable's value is as follows (From Vincent Brulis): The way I handled it was to create a temporary variables node on the same level, create a variable, set it to the expression that was found and extract the value of the variable.

demisjohn commented 8 years ago

Probably would modify fimm.Exec() so by default it resolves variables (if returned value is not numeric), but provide an argument eg. resolve_vars=False to prevent this if needed. Would only resolve if variable node is set in the project. (fimm.Exec wouldn't have access to that info tho... hmmm)