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

WIP making ODEs work in Julia #3931

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

WIP making ODEs work in Julia #3931

wants to merge 1 commit into from

Conversation

B-rando1
Copy link
Collaborator

@B-rando1 B-rando1 commented Aug 21, 2024

Unfortunately we can't quite finish getting ODEs in Julia, but this should guide the way when we're ready.

The reason we can't finish is because the ODE library uses structs, and the Julia renderer doesn't support structs yet.

Other changes:

  • I changed how Julia imports libraries, as that was previously incorrect. I will create a separate PR for this.
  • I changed how Julia represents empty lists. Previously any empty list was simply []; now it is Type[] - e.g. an empty list of doubles is Float64[]. The reason for this is because Julia assigns [] the type Array{Any}, which causes problems when you need it to be type Array{Float}, for example. I will also create a separate PR for this.
  • I created the populateSolList' function, which acts like the populateSolList but without accessing a field. I think that once we have structs in Julia, we won't need this function.
  • I removed the [] case from applyWithNamedArgs, as it was causing problems.

I commented most of the things that need to be changed once we have structs. You can also refer to my test case here to compare.

@JacquesCarette @smiths @balacij feel free to give any feedback or ask any questions you have.

Contributes to #3918

@JacquesCarette
Copy link
Owner

Why did you change Bundled to Unbundled in one example? Also, if you could rebase, so that it's easier to see what's new in just this PR?

@B-rando1
Copy link
Collaborator Author

I changed the example to Unbundled since Julia can't support Bundled until we add Structs. Basically I just needed a way to see/show what code it was outputting for one of the ODE examples. Since adding Structs to Julia should unblock both ODEs and Bundled, we can probably put it back to Bundled by the time this PR is finished.

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 this pull request may close these issues.

2 participants