Skip to content

V0.2.2

2024-09-02#

I basiically went all-in on RON files to manage entities spawned in. Feels good so far. I looked up crates that might help manage the huge orders of magnitude of the phyiscal characteristics of the planets, but it wasn't compiling on Windoes without extra steps for some dependency and I didn't feel like going down that rabbit hole tonight. Let's tough it out and see what happens. We don't really need all that much precision... f64 should be plenty. I do worry about things like multiplying masses (E24 for the Sun) against the gravitational constant (E-22 or something). This is where Python fell short.

I'm leaning hard on LLMs (Claude Sonnet 3.5, ChatGPT 4o) to make scaffolding here. It is very helpful, but LLMs aren't consistent in style and such, so there is some cleanup to do. Very helpful as a "sketch" -- especially if it compiles.

Aaaaand it bit me. I'm going to keep this setup but with totally fake values to get the main bits up and running. I should probably use nyx for high fidelity simulations. I don't need high fidelity simulations to get the point across. I do need it if I want to make any scientific judgements.

Come on, Phil, don't overthink it!

2024-09-03#

For some reason the timestamps are printing in UTC no matter what time scale is native to the Epoch I'm making. This could be a bug somewhere in lofitime because of chrono, or it could be a hifitime issue. I'll make a new baby crate to explore this and eliminate variables from my code.

FOUND IT. The Epoch's display formatter overwrites the timescale to UTC in hifitime 3.9.0. Thankfully this is fixed in 4.0.0-alpha.

It wasn't an easy upgrade. The new hifitime version broke lofitime, and I ended up basically rewriting it. As usual, it feels better after the second time around. On one hand, a waste of 3 hours dicking around with the UI; on the other hand, a useful exercise in writing traits, crates, and general rust.

2024-09-05#

I talked to Chris R about lofitime as an official crate and he was supportive. I'll remove lofitime from this repo and give it one of its own. I'll probably give it a lame name too so other people know what it is.

--> philiplinden/time-traveler

2024-09-07#

I deleted lofitime since it's now a separate crate. It only drove the UI anyway. This means I don't need the workspace setup either. I'm gutting a bunch of dependencies that I wasn't using. Does that make this... take 3?

2024-09-08#

Focus. Not a lot of time left before we need a demo. 1. Spool up a simple demo of gravity at work. An example from particular will do just fine. Two or three bodies, that's it. No controls necessary. 2. Get a shader running that shows the potentials. This will be the basis for our shader that shows dilation at any point on the grid.

That should be one day of work, I think. Breathe. Let's go.

I kit-bashed some examples from particular and avian to finally show n-body physics the way God intended. Until it explodes. Progress, I guess.

I'll set up something simple that looks like Earth, Moon, and a few satellites.

Getting something that looks like actual orbits is pretty hard, turns out. Not sure why it's so hard but I spent a few hours here and got nowhere.

I want to use the fundamentals here as the basis for some demos at conferences coming up, but as it stands I'm no farther along than I was in February.

I want to show: 1. Objects subjected to gravity. 2. Clocks on those objects showing their proper time. 3. The tick rate of the clocks warped by local gravity. (As a bonus, speed).

This should convey that the system is dynamic and it's hard to draw boundaries around where one time scale starts and another stops.

Another thing I want to show is: 1. Two clocks with nanosecond precision. 2. The wi-wi algorithm measuring distance and delta t by comparing clock signals.

It might be easier to validate my calculations if I use real units, but then I'd want to use nyx instead of particular. Not a terrible idea... Maybe I should make this a workspace after all and spin off a bunch of experimental crates until I converge on something.

I'll merge what I have into main and then pick off a new branch to experiment with nyx.

Maybe instead of spending so much time on the orbits, I should spend more time on... you know... figuring out the time dilation.

2024-09-15#

Reference frames matter. A lot. I need to spend some time thinking about the problem of motion and time from the perspective of "how do we convert between reference frames".

  • https://orbital-mechanics.space/intro/reference-frames.html
  • https://naif.jpl.nasa.gov/pub/naif/toolkit_docs/C/req/frames.html
  • https://naif.jpl.nasa.gov/pub/naif/toolkit_docs/Tutorials/pdf/individual_docs/17_frames_and_coordinate_systems.pdf
  • https://nyxspace.com/nyxspace/MathSpec/models/gravity/
  • https://nyxspace.com/nyxspace/showcase/04_lro_od/

In this context, the most important reference frames are 1. Earth-centered Inertial (ECI). 2. Moon-centered Inertial. 3. Object-centered Body-fixed (for a given actor).

I really don't want to have to code up my own reference frame transformations. This seals the deal with using Nyx. I'll apply scale factors to help with visualizations if I need to. I don't think there's a place for Particular anymore. Honestly this might also rule out the necessity for Avian as well. Since Nyx is a real astrodynamics crate, I'm basically locked into 3D as well.

I put settings, constants, etc. in another RON file for safe keeping.