TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

HTML5 Gravity/Galaxy Simulator

122 pointsby mcdevhammerover 10 years ago

6 comments

jpcoover 10 years ago
This is cool, and I&#x27;m a sucker for gravity&#x2F;space simulators (as my hours logged on Celestia would prove), but it should be noted that in terms of &quot;galaxy&quot; it&#x27;s inaccurate. Specifically, this inaccuracy (the galaxy rotation problem) is the driving force behind the hypothesis of dark matter [0].<p>I don&#x27;t mean to be pedantic or anything. I just think it&#x27;s interesting.<p>[0] <a href="http://abyss.uoregon.edu/~js/cosmo/lectures/lec17.html" rel="nofollow">http:&#x2F;&#x2F;abyss.uoregon.edu&#x2F;~js&#x2F;cosmo&#x2F;lectures&#x2F;lec17.html</a>
评论 #8287910 未加载
评论 #8288309 未加载
评论 #8286038 未加载
mcdevhammerover 10 years ago
I also wrote a 3D version in C++ using OpenGL <a href="https://github.com/claassen/GalaxySim3D" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;claassen&#x2F;GalaxySim3D</a>
ellysetaylor21over 10 years ago
I am not familiar with this but it seems like a playing tool for kids, can I have some tutorial to learn how this will make?
lemmingapexover 10 years ago
Well done. Here&#x27;s my HTML5 Version: <a href="https://news.ycombinator.com/item?id=8288434" rel="nofollow">https:&#x2F;&#x2F;news.ycombinator.com&#x2F;item?id=8288434</a>
hliyanover 10 years ago
What emerges from the random field looks remarkably like the large scale structure of the known universe.
conistonwaterover 10 years ago
I can&#x27;t help but notice there is a magical &quot;Theta&quot; parameter, with the description &quot;Higher = faster, less accurate&quot;. I think here it&#x27;s a threshold for ignoring children nodes&#x27; internal structure in an octree.<p>As a matter of good software engineering (and numerical analysis, and mathematics, too), your software shouldn&#x27;t have magical parameters with mysterious consequences for the correctness of your software. (I know correctness is maybe not the point <i>here</i>, but still...) Also, note that there is no way for a user to check how accurate the simulation is for a given &quot;Theta&quot; parameter. The name is completely non-descriptive as well.<p>There are mathematically sound ways to determine the accuracy of the simulation. If they are expensive, tell that to the user explicitly, but default to the correct implementation, not the fast one.<p>Note that while the user has no clue what &quot;Theta&quot; is, the user might instead be able intuitively specify that they want the simulation to be accurate &quot;to X digits for the first Y seconds of the simulation&quot;. I think that would be a better software design. As it is, &quot;Theta&quot; is an exposed quirk of the implementation.
评论 #8288013 未加载
评论 #8286776 未加载
评论 #8286733 未加载