JacquesCarette / Drasil

Generate all the things (focusing on research software)
https://jacquescarette.github.io/Drasil
BSD 2-Clause "Simplified" License
142 stars 26 forks source link

Local Scope #787

Open smiths opened 6 years ago

smiths commented 6 years ago

In the future, Drasil should support the idea of a local scope for symbols. As pointed out in the case studies repo:

https://github.com/smiths/swhs/issues/35#issuecomment-402745549

there are cases where a local scope would be helpful. The definition of \tau_w could be local to the instance model that defines the governing ODE. However, as currently set-up, we need a separate data definition to include the equations that define the local parameters \tau_w ( and \eta).

JacquesCarette commented 4 years ago

@bmaclach I think Drasil now has some features close to this. Can this be implemented now?

bmaclach commented 4 years ago

@JacquesCarette It does look like data definitions now have a scope field. I don't think it currently does anything, but there's at least something there to build off of.

smiths commented 2 years ago

We discussed this issue in our "cold cases" meeting on Dec 6, 2021. We decided that it is premature to address it now, since we are in the midst of rethinking how we think about Drasil knowledge in terms of theories. Once the new theories "model" is in place we can return to this issue.

balacij commented 1 year ago

If we consider chunks to be theory presentations (theories definitions in CAS 760 or the unified theories we've been discussing recently), then I think almost any theory would be able to define new symbols as constants. I haven't thought about this enough, but I want to get the idea down and shared in case anyone else has thoughts. I'll definitely return to this.