Hacker Newsnew | past | comments | ask | show | jobs | submit | nhatcher's commentslogin

This is amazing! Nicely done!

I did something similar, mostly 2D here:

https://www.nhatcher.com/three-body-periodic/

(Mine is just unfinished)


Thank you! Your 2D version is great, I love seeing how different people approach this stuff. As for integrators, I currently only have Velocity Verlet and RK4 (can change in the advanced settings). I started with just Verlet, but to get some of the presets to behave properly I ended up needing RK4 as well. I’ve been thinking about adding adaptive methods next, but I'll take a look at the methods you've got listed too. Everything is still running in plain JS for now. I started moving some of the work into web workers but haven’t finished that part yet.

Symplectic integrators are the approach I used for some old galaxy simulations. Page 5 on the attached paper was my main reference, eq 22 https://arxiv.org/pdf/cond-mat/0110585 I believe this is used in several academic codes for long term N-body calculations.

I would be very curious to compare notes on the integrators you used. How good do they perform in general?

In the avobed shared you can go to the settings a pick an integrator. I did the integrators in wasm although I suspect js is just as fast.

Color me impressed! I love the ammount of settings you can play with. I still need to understand what happens whe yu add more bodies though.


what the heck? are those three orbits genuinely symmetrical in 2D or did I misinterpret

I'm not sure which ones are you talking about specifically. But there are some with some heavy symmettrical patterns indeed. To my eyes some are mesmerizing to watch.

The orbits are computed in real time, so yeah what you are seeing (modulo errors in my code is genuine)

There are some caveats though. Some orbits are periodic only in a rotating frame of reference.

EDIT: you can share the URL and I can see which orbits you are talking about

Like: https://www.nhatcher.com/three-body-periodic/?class=bhh_sate...


Off topic, but the 500 page from prusa3d is quite good:

https://www.prusa3d.com/

https://imgur.com/a/OW5KL8r


Nice! This is my implementation:

https://github.com/ironcalc/IronCalc/blob/main/base/src/func...

although at this moment would only pass some "smoke" tests

RowZero is great!


I started with basic Newton-Raphson solver too but found cases where it diverges but Excel somehow doesn't, so concluded that Excel has some kind of extra logic to handle more cases, so I also bolted on more fallback logic.

Hi! Currently I am implementing those on IronCalc[1]!

They are really complex:

https://www.oasis-open.org/2021/06/16/opendocument-v1-3-oasi...

Is the odf counterpart, full on details. The libreoffice implementation:

https://github.com/LibreOffice/core/blob/9667d5e9ebe4a68a772...

I should be done within the week.

[1]: https://github.com/ironcalc/IronCalc


I have the same question in my mind. Also thrilled though. I think there is a genuine fascination in HN and in general with Grothendieck [1], [2].

[1]: https://en.wikipedia.org/wiki/Alexander_Grothendieck [2]: https://hn.algolia.com/?q=Grothendieck


Interesting, yeah. I guess he was the mathematical equivalent of the "rogue" archetype. Brilliant, did things in his own way, total lack of respect for authority, shrouded in mystery. I can definitely see the appeal =)


Related from yesterday:

Bluetui – A TUI for managing Bluetooth on Linux

https://news.ycombinator.com/item?id=45817114 https://github.com/pythops/bluetui


Hmm, that sounds bad. Were you running the debug build? Like just running 'cargo run'?


First in debug, then I built in release to see if that changed something, but it didn't.

I see that there are some related discussions on the github: https://github.com/ratatui/ratatui/discussions/1927. Not sure if there is a solution though.


Thanks! I will definitely have a look at this. I really want to like Ratatui but I do wonder how much bloat there is


(shameless plug) I don't know if anyone would be interested in taking this but I have what I think is a really nice project. Integrating this;

https://github.com/ironcalc/TironCalc

Into the main repo :

https://github.com/ironcalc/ironcalc

Now, I'm not 100% convinced ratatui is the way to go after seeing what the folks of Microsoft did with edit.

Anyhow, I think TironCalc is a great open source project to work with Rust and Ratatui.


If you are interested in this subject I always recommend Anna Frebel's book: "Searching for the Oldest Stars". Can't believe is over a decade old now, time flies. Still one of the most beautiful book on popular science out there. It is amazing to see how we can actually be pretty sure we are seeing second generation stars. And more in general the theory of stellar evolution in really interesting


Wrong thread? You are looking for who wants to be hired:

https://news.ycombinator.com/item?id=45800464


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: