Coder Social home page Coder Social logo

gr_source flag not working about reboundx HOT 7 CLOSED

dtamayo avatar dtamayo commented on August 28, 2024 1
gr_source flag not working

from reboundx.

Comments (7)

hannorein avatar hannorein commented on August 28, 2024

Good question. I can see that this was removed in e3795b9. That was over 5 years ago and I don't remember why. The only thing that comes to mind is speed. Maybe Dan's memory is better. We need to either correct the documentation or reimplement gr_source.

from reboundx.

dtamayo avatar dtamayo commented on August 28, 2024

from reboundx.

tamidodo avatar tamidodo commented on August 28, 2024

Looking at Apophis close approach structure over 100 year integration - there's a significant shift in target plane location for the various close approaches if I use gr_full vs gr but gr_full takes an unreasonable amount of time to run for the sims I want to do. I'm fairly certain what makes the big difference is the GR from Earth, Moon and Jupiter so I was hoping to just use GR for the Sun and those extra particles instead of for all the planets and 25 other asteroids I've included in the sims.

from reboundx.

dtamayo avatar dtamayo commented on August 28, 2024

Hi Tammy,

I'm afraid that looking at the source code, I don't see an easy way to fix this. gr.c relies on Jacobi coordinates, which simplify the equations of motion (if you're interested see Appendix B of the REBOUNDx paper). These are a combination of all particles' positions and velocities, and use routines to go back and forth with inertial coordinates, which would (at least currently) require us to make reordered copies of the particles array for each gr source we wanted to consider.

I'm somewhat surprised that this matters though. Isn't the size of this acceleration GM_earth/rc^2 smaller than the acceleration Apophis feels from the Earth? For a close encounter distance of the Earth-Moon distance, I think that would be ~10^11 times smaller. If perturbations at that level matter, I would naively think that opens a whole can of worms. Doesn't that mean that one should also include not only the J2 of the Earth, but also J4, J6 (maybe J3)? Perhaps also these terms for the Moon? Could it be that Apophis has several close encounters with Earth over 100 years and its orbit is chaotic, so that any perturbation at all causes a significant shift in the target plane location? One could test that by changing the initial x position by Apophis at the 15th decimal and seeing what happens.

Apologies if the answer is already obvious to you, but if not, it might be worth thinking through whether this is definitely the limiting ingredient, because I think making this work in the code would take a fair bit of effort, unless @hannorein sees a simpler way. I've updated the documentation to not mention gr_source for now.

from reboundx.

hannorein avatar hannorein commented on August 28, 2024

This is a chaotic system, so small difference can grow exponentially fast. But I tend to agree that GR from other bodies should really be a very small effect. Even if you see something change when you turn on/off gr_full, that doesn't mean that GR is important. I think, like Dan suggested, that you need to integrate an ensemble of simulations initialized with small differences that are consistent with the observational constraints. Then you can look for differences in statistical quantities (probability of Apophis colliding with earth, etc). Sorry if this is something you already thought about and we're missing something!

from reboundx.

tamidodo avatar tamidodo commented on August 28, 2024

I think we're on the same page in terms of other factors making a difference in the target plane location - I'd considered the simulation setup that included J2/J4 considerations for the Earth, radiation forces, GR (with the Sun as the only source), and 25 other asteroids included in the sim as the "nominal simulation". I then reran it removing one thing at a time to see how much of an effect on the target plane location for the 2036 encounter there was. I was surprised to find that the difference in target plane location between using gr and gr_full was only an order of magnitude less than the difference between using gr and not including it at all. These differences were also the biggest of all the scenarios I tried by a few orders of magnitude (removing some of the asteroids, removing radiation forces, etc.).

That might not mean that GR for other bodies is important, I just took it to mean that it was more important than some of the other things I'd made sure to include in the sims like J2/J4 for the Earth. If it had made a difference but not as large as other effects had on the sims, I would have been confident that my "nominal" setup was fairly robust for what knowledge we have, just using the Sun as a GR source. My original thinking was that GR for other bodies wouldn't make a huge difference so even though it would be more precise to include it for all bodies, it wasn't that much of a compromise to just consider it for the Sun.

To explore the target plane for the close approach structure, I ran 20 000 sims, each with varied initial position and velocity to make the Apophis particle go through different target plane locations for the 2036 encounter. The statistical quantity I'm looking at is the minimum distance between Apophis and Earth over the 100 year integration, mapped to a given target plane location. I have not run a full simulation exploring the target plane using gr_full so I'm not confident that the structure remains the same and it's just shifted by the difference.

from reboundx.

dtamayo avatar dtamayo commented on August 28, 2024

Hope things were sufficiently resolved. I know that Matt Holman has been working a lot to build an ephemeris quality integrator from REBOUND, and has also been running tests on Apophis to compare with JPL. He's talking about it at the DPS meeting this year--I'm sure he'd be interested in your work! I'll close this for now--feel free to reopen at any point.

from reboundx.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.