Skip to main content
10 events
when toggle format what by license comment
Feb 6, 2021 at 22:38 comment added Alex Trounev @testing09 Ah, sorry! See update 1 to my answer.
Feb 6, 2021 at 22:37 history edited Alex Trounev CC BY-SA 4.0
added 2758 characters in body
Feb 6, 2021 at 17:25 comment added testing09 Oh I understand- my original problem was trying to get the integration to stop when that condition was met. This way the plots don't break. If the condition is met, plots 1 and 2 don't work. e.g. for a value of a[0]=3 au, the first 2 plots break. Hence, why I was trying to use WhenEvent to stop the integration from proceeding once the condition is met
Feb 6, 2021 at 17:05 comment added Alex Trounev @testing09 integration is stopped a t=9 Gyr as it given in ParametricNDSolveValue[].
Feb 6, 2021 at 17:03 comment added testing09 I have a question about your solution- I understand that you have specified the stop condition in the Plot function. Does Mathematica automatically know that it should stop plotting when this expression goes to zero? The reason I ask is that I am trying to extract the time at which the integration is stopped. Sorry for so many questions but I'm trying to get better at Mathematica :) –
Feb 6, 2021 at 16:55 comment added Alex Trounev @testing09 We can also use scaling Plot[Evaluate[ Table[RDsolR[Rast][[1]] /. t -> ts Myr, {Rast, 0.001, 0.01, 0.001}]], {ts, 0, 9*Gyr/Myr}, FrameLabel -> {"Time, Myr", "Semi-major Axis"}, Frame -> True]
Feb 6, 2021 at 15:43 comment added Alex Trounev @testing09 Actually in your code Time is in second, not in Myr. But if you wish to plot Time, Gyr or Time, Myr with FrameLabel option we can scaled Plot output.
Feb 6, 2021 at 14:20 vote accept testing09
Feb 6, 2021 at 14:19 comment added testing09 @AlexTrounev- thank you so much! One last question- you've removed the explicit time dependence from the expression. How do I now scale the x axis so it's in Myr?
Feb 4, 2021 at 9:55 history answered Alex Trounev CC BY-SA 4.0