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

Dispatch on spatial graph? #5

Open
tpoisot opened this issue Jun 21, 2023 · 1 comment
Open

Dispatch on spatial graph? #5

tpoisot opened this issue Jun 21, 2023 · 1 comment

Comments

@tpoisot
Copy link

tpoisot commented Jun 21, 2023

If you move the type of this field

https://github.com/gottacatchenall/EcoDynamics.jl/blob/327b87b4fbf47b1ced4263dcbb90009fa81c4c6a/src/problem.jl#L6

into the type declaration, you can dispatch on whether or not it has a spatial graph.

@gottacatchenall
Copy link
Owner

gottacatchenall commented Jun 21, 2023

yeah that's a vestigal component, I've moved to parameterizing w/ Spatialness, which will also enable dispatch against Model{S<:Spatialness} to replace the ugly ∂u_spatial calls https://github.com/gottacatchenall/EcoDynamics.jl/blob/327b87b4fbf47b1ced4263dcbb90009fa81c4c6a/src/models/lvcompetition.jl#LL31C1-L31C20

but any other feedback on the type system would be useful, i'm still not sure about it

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

No branches or pull requests

2 participants