Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Converting "Newton's law of universal gravitation" Theory Model #2436

Closed
balacij opened this issue May 12, 2021 · 3 comments · Fixed by #2532
Closed

Converting "Newton's law of universal gravitation" Theory Model #2436

balacij opened this issue May 12, 2021 · 3 comments · Fixed by #2532
Assignees

Comments

@balacij
Copy link
Collaborator

balacij commented May 12, 2021

Related to #2371

While converting the following TheoryModel into "not an OthModel":

newtonLUG :: TheoryModel
newtonLUG = tmNoRefs (OthModel newtonLUGRC)
[qw force, qw gravitationalConst, qw mass_1, qw mass_2,
qw dispNorm, qw dVect, qw distMass] ([] :: [ConceptChunk])
[] [newtonLUGRel] [] "UniversalGravLaw" newtonLUGNotes
newtonLUGRC :: RelationConcept
newtonLUGRC = makeRC "newtonLUGRC"
(nounPhraseSP "Newton's law of universal gravitation") EmptyS newtonLUGRel
newtonLUGRel :: Relation
newtonLUGRel = sy force $=
sy gravitationalConst * (sy mass_1 * sy mass_2 /
(sy dispNorm $^ 2)) * sy dVect $=
sy gravitationalConst * (sy mass_1 * sy mass_2 /
(sy dispNorm $^ 2)) * (sy distMass / sy dispNorm)

and in the context of #2426 (comment) , it seems inappropriate to naively convert the following TheoryModel into an EquationalModel because it contains 2 expressions for which it can use to calculate the force. However, if I'm not mistaken, if we want an EquationalModel to mean "something is calculated by this 1 formula", then I think we need to create a new kind of ModelKind to accommodate this.

Assuming I'm correct, would we potentially want some sort of "AnyEquationModel" (weird name, but we can probably figure something out that's better) that contains a list of QDefinitions, for which any can be used to calculate the thing in question?

EDIT: Alternatively, we could even just make "EquationalModels" just allow for this list of QDefinitions describe above, and create a smart constructor for all the existing models that currently have just 1 single related QDefinition.

@balacij
Copy link
Collaborator Author

balacij commented May 12, 2021

I believe this is also related to discussion on #1601 (which we may want to visit for other things as well related to ModelKinds in general)

@JacquesCarette
Copy link
Owner

I agree with the reasoning.

We could indeed use an NEList of expressions (for the right hand sides) in EquationalModels to collapse the two together. But, let's not do that now. Using something from a list requires a choice, but in the 1 case, there is none - and from a design perspective, that's quite different.

I'm thinking EquationalRealm. We use Realm in a paper to mean a theory with multiple interfaces. Let's start with that?

@balacij
Copy link
Collaborator Author

balacij commented May 12, 2021

That sounds good to me. I'll try to get that going in a new issue/ticket.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants