I’m working with DifferentialEquations.jl and I have a state vector in 6-dimensional phase space. I would like to work with units and static vectors but my issue is that the momentum part of the phase space vector has a different unit than the position part. How can I get the functionality of StaticVectors.jl and Unitful.jl when I need two different units in my vector?
Luapulu
1
Luapulu
2
I found ArrayPartition from RecursiveArrayTools.jl, which might solve my problem.
Edit: Jup, this does it.
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Unitful + DiffEq + different physical quantities + derivatives? | 1 | 398 | June 9, 2021 | |
| DifferentialEquations.jl and systems with heterogenous units | 17 | 2392 | July 16, 2020 | |
| Issue with StaticArrays and PDMP | 16 | 957 | June 1, 2019 | |
| State and Parameter vectors for SciML applications | 5 | 770 | August 28, 2023 | |
| VectorOfArrays: iterating over pairs; type qualifier when containing specific SVector | 6 | 654 | June 19, 2022 |