- #1

- 41

- 2

Thanks in advance!

- B
- Thread starter jimbo007
- Start date

- #1

- 41

- 2

Thanks in advance!

- #2

tony873004

Science Advisor

Gold Member

- 1,751

- 143

Here's my attempt at an animation. You can pause and scroll down through the list to view their state vectors.

- #3

- 3,564

- 1,345

Here is one of the papers from which some of the orbital parameters given were obtained, it has a more complete table of parameters.

Thanks in advance!

http://iopscience.iop.org/article/1...68AD8BD224A45B380D7.c2.iopscience.cld.iop.org

(if you click on the entry in the Ref column, it will open a box with a link to the reference.)

- #4

- 41

- 2

Thanks Janus that table is looking better. Looks like it provides t_0 instead of M_0, don't suppose you know how to convert from t_0 to M_0 (the mean anomaly at epoch)?

Is there any more data that exists for additional stars? 6 is a very good start, would be nice to have a few more if possible. I have seen some animations which include more stars but not sure if their data is hidden from public access or not.

- #5

tony873004

Science Advisor

Gold Member

- 1,751

- 143

http://orbitsimulator.com/formulas/OrbitalElements.html

Since my simulation is a web page, you can view the source and get all the cartesians in one glance. Search the code for "objMass[1] ="

There's probably more recent data. The Wikipedia link doesn't give enough data to make what I made. Over the weekend I'll see if I can find more complete and current data.

edit: I just saw the table in Janus' reply. Let me know if you need help making cartesians out of that.

- #6

- 41

- 2

Sounds great if you could find more complete and current data.There's probably more recent data. The Wikipedia link doesn't give enough data to make what I made. Over the weekend I'll see if I can find more complete and current data.

Yes it does look like I need help converting to Cartesian coordinates. My main trouble is with the mean anomaly which isn't provided in the table.

We have [itex]a\text{, } e\text{, } \omega\text{, } \Omega\text{, } i [/itex] but no [itex]M_{0} = M(t_{0}) [/itex]. They have provided [itex] t_{0} [/itex] but not sure if one can convert that to [itex] M_{0} [/itex] with the other data provided

- #7

tony873004

Science Advisor

Gold Member

- 1,751

- 143

M0 = 360 - (360 * (t0 - D) / T)

D is the date of your animation.

T is the period of the object's orbit.

Make sure that T, t0 and D are all in the same units.

Edit: missed a parenthesis. fixed now.

D is the date of your animation.

T is the period of the object's orbit.

Make sure that T, t0 and D are all in the same units.

Edit: missed a parenthesis. fixed now.

Last edited:

- #8

- 41

- 2

That's beautiful thanks tony873004. If I understand correctly, using the information below for the S1 star

we have that

[tex]

M_{0} = 360 - \frac{360}{T} (t_{0}-P)

[/tex]

using [itex]D=P[/itex]

which means

[tex]M_{0} \approx 360 - \frac{360}{94.1}(2002.6 - 2016.25)[/tex]

Does that sound reasonable?

we have that

[tex]

M_{0} = 360 - \frac{360}{T} (t_{0}-P)

[/tex]

using [itex]D=P[/itex]

which means

[tex]M_{0} \approx 360 - \frac{360}{94.1}(2002.6 - 2016.25)[/tex]

Does that sound reasonable?

Last edited by a moderator:

- #9

tony873004

Science Advisor

Gold Member

- 1,751

- 143

It looks good. A little background...

The 6 main orbital elements describe the size, shape, and orientation of the orbit, as well as the object's position on that orbit at a particular time.

Sometimes mean anomaly is used for position. Sometimes time since (or to) periapsis passage is used.

So for example, imagine an orbit with a period of 60 minutes. If t0 is 15 minutes, that means that 1/4 of an orbit ago it was at periapsis.

So 15/60 or 1/4 of an orbit, which is 360 degrees is 90 degrees.

360-90 = 270. So the M is 270 degrees.

Notice I considered D to be 0 for simplicity. If D is after t0, you get a negative number, which is fine. You'll get an angle greater than 360, so you have to subtract off 360 to get back in the 0-360 range.

Note that they give semi-major axis in milli arcseconds. This needs to be converted to a distance in order for the conversions from orbital elements to cartesian coordinates to make sense. We need to know the distance from the Earth to the black hole to make the conversion.

from the paper

8000 parsecs x 3.08568025E+16 meters / pc * sin(0.412 / 3600) = 493075008240113 meters

As a double-check, we can plug into the period formula (P =2pi sqrt(a^3/(GM)) and convert to years.

To do this, we need to know the mass of the black hole.

The period formula is P = 2pi * sqrt(a^3/(GM))

This gives seconds. Dividing by 3.155 x 10^7 gives years.

2*pi*sqrt((8000*3.08568025E+16*sin(.412/3600))^3 / (6.67e-11*3.61e6*1.99e30))/3.155e7

gives 99.6 years. Using 4 instead of 3.61 gives 94.6 years, which is in rough agreement with the period given for S1 in the data you quoted.

You can copy and paste the above formula into Google,and play with various numbers. It outputs years.

You've now got everything properly converted for use in the calculator: http://orbitsimulator.com/formulas/OrbitalElements.html

I'm looking forward to seeing your animation! Let me know if you need help.

The 6 main orbital elements describe the size, shape, and orientation of the orbit, as well as the object's position on that orbit at a particular time.

Sometimes mean anomaly is used for position. Sometimes time since (or to) periapsis passage is used.

So for example, imagine an orbit with a period of 60 minutes. If t0 is 15 minutes, that means that 1/4 of an orbit ago it was at periapsis.

So 15/60 or 1/4 of an orbit, which is 360 degrees is 90 degrees.

360-90 = 270. So the M is 270 degrees.

Notice I considered D to be 0 for simplicity. If D is after t0, you get a negative number, which is fine. You'll get an angle greater than 360, so you have to subtract off 360 to get back in the 0-360 range.

Note that they give semi-major axis in milli arcseconds. This needs to be converted to a distance in order for the conversions from orbital elements to cartesian coordinates to make sense. We need to know the distance from the Earth to the black hole to make the conversion.

from the paper

So therefore, looking at the semi-major axis for S1 = 0.412 arcsec and converting to meters gives:...If not specified otherwise (§ 3.3), we adopt throughout this paper R0 = 8 kpc for the Galactic center distance...

...The updated estimate of distance to the Galactic center from the S2 orbit fit is R0 = 7.62 ± 0.32 kpc...

8000 parsecs x 3.08568025E+16 meters / pc * sin(0.412 / 3600) = 493075008240113 meters

As a double-check, we can plug into the period formula (P =2pi sqrt(a^3/(GM)) and convert to years.

To do this, we need to know the mass of the black hole.

I think they made a typo in that middle sentence. I think they meant the distance from Earth, not S2. That would put S2 about as far away as Earth....The best-fit central mass9 for an assumed distance of 8 kpc is (4.06 ± 0.38) × 10^6 (solar masses)...

...The updated estimate of distance to the Galactic center from the S2 orbit fit isR0 = 7.62 ± 0.32 kpc, resulting in a central mass value of (3.61 ± 0.32) × 10^6 (solar masses)...

...Measurements of stellar velocities and (partial) orbits have established a compelling case that this dark mass concentration is a massive black hole of about (3[PLAIN]http://cdn.iopscience.com/icons/EJ4/AJ/ucp-icons/ndash.gif4) [Broken] × 10^6 (solar masses)...

The period formula is P = 2pi * sqrt(a^3/(GM))

This gives seconds. Dividing by 3.155 x 10^7 gives years.

2*pi*sqrt((8000*3.08568025E+16*sin(.412/3600))^3 / (6.67e-11*3.61e6*1.99e30))/3.155e7

gives 99.6 years. Using 4 instead of 3.61 gives 94.6 years, which is in rough agreement with the period given for S1 in the data you quoted.

You can copy and paste the above formula into Google,and play with various numbers. It outputs years.

You've now got everything properly converted for use in the calculator: http://orbitsimulator.com/formulas/OrbitalElements.html

I'm looking forward to seeing your animation! Let me know if you need help.

Last edited by a moderator:

- #10

- 41

- 2

What I did was use the above info to calculate the initial position and velocity of the star S1 and then used Euler's method to calculate subsequent positions using 3.6 million solar masses as the mass of the black hole to calculate the new accelerations.

At least a few days from creating the animation but think I am on the right track now, will send a video once I have done something half decent but don't expect to be blown away.

Don't suppose you have found any more star data by chance?

- #11

tony873004

Science Advisor

Gold Member

- 1,751

- 143

My sim has one more object than the ones listed in their table (SO-5). So it doesn't look like there's much more info to be had.

- #12

- 41

- 2

At some point it comes to within 140000000000 metres of the black hole and at that distance the escape velocity is 2.75 times the speed of light which is fairly difficult to achieve. Unfortunately I dont think you have that star in your animation so can't compare with yours.

Since there is a lack of data for stars orbiting black holes and since 5 stars isn't very exciting I was thinking of doctoring up some pretend orbital elements using the Sagittarius black hole as the central body. How easy is it to mock up some orbital elements that would be stable?

- #13

- 3,564

- 1,345

If you are using ~4e6 solar masses for the black hole mass, that puts the event horizon at ~ 1.18e10 m, the minimum distance you gave above is 1.4e11 m or over 10 times the distance. This is well outside event the photon sphere and no where near where the escape velocity is even c. (it would be roughly 32% of c at that distance.)

At some point it comes to within 140000000000 metres of the black hole and at that distance the escape velocity is 2.75 times the speed of light which is fairly difficult to achieve. Unfortunately I dont think you have that star in your animation so can't compare with yours.

Since there is a lack of data for stars orbiting black holes and since 5 stars isn't very exciting I was thinking of doctoring up some pretend orbital elements using the Sagittarius black hole as the central body. How easy is it to mock up some orbital elements that would be stable?

Using the 4e6 solar mass value and the given period of 36 years, I get an semi-major axis of 2.6e14 m or ~1738 AU, which is close to the 1750 AU in the article you first linked to.

With an e of 0.395, this puts the periapis at 1.57e14 m or at over over 13,000 times the event horizon radius and at this distance, the escape velocity will be 0.88% of c.

Even the star listed just below S14 in the original article you linked to, with the same period and a much higher eccentricity of 0.974, only gets to within 6.7e12 m or 568 times further than the event horizon of the BH.

The orbital velocities at closest approaches for these stars would be 2.2e6 m/s and 1.3e7 m/s or 0.73% and 4.3% of c respectively.

- #14

tony873004

Science Advisor

Gold Member

- 1,751

- 143

Like Janus said, a semi-major axis of 1750 with an ecc of 0.395 puts the star's periapsis much higher than 14... (~1 AU) number you mentioned.

An eccentricity of 0.395 on a 1750 AU orbit simply means that at apsis it is 39.5% greater than 1750, and at periapsis it is 39.5% less than 1750. So 1059 AU is the closest it should get.

Can you post your calculations? If you're using the online calculator, can you screenshot it, or give the values in each box?

- #15

- 41

- 2

I was hoping it would be a simple fix of adding .0 to the integer values given in the table for S13 as it is the only star with integer values but doesn't look to be the case unfortunately, especially since all other stars are producing orbits.

I am using [itex]3.61 \times 10^6 M_{\odot} \approx 7.18029 \times 10^{36} \text{kg}[/itex] as the black hole's mass

[tex]

a=0.219 \text{ arcsec} =2.62095696128 \times 10^{14} \text{metres}\\

e=0.395\\

P=36\\

t_{0} = 2006.1\\

M=360-\frac{360}{P} (t_{0} - 2016.25) =1.77150919077 \text{ radians}\\

\omega = 250.0 \text{ deg} = 4.363323 \text{ radians}\\

\Omega = 100.0 \text{ deg} = 1.745329 \text{ radians}\\

i = 11 \text{ deg} = 0.191986 \text{ radians}

[/tex]

Eccentric anomaly:

Solve the following equation for E using Newtons method

[tex]f(E) = E - \mathit{e} \sin E - M = 0[/tex]

gives

[tex]E = 2.1103871826[/tex]

True anomaly:

[tex]

\begin{eqnarray*}

\nu &=& 2 \cdot \text{arctan2} (\sqrt{ 1+\mathit{e} } \sin\left( \frac{E}{2}\right),\sqrt{1-\mathit{e}}\cos\left( \frac{E}{2}\right)) \\

&=&0.714430095777

\end{eqnarray*}

[/tex]

where

[tex]

\text{arctan2}(x,y)=

\left\{\begin{array}{cc}

\arctan \frac{y}{x},&\mbox{ if } x \gt 0\\

\arctan \frac{y}{x}+\pi, &\mbox{ if } y\geq 0, x < 0\\

\arctan \frac{y}{x}-\pi, &\mbox{ if } y < 0, x < 0\\

\frac{\pi}{2}, &\mbox{ if } y > 0, x = 0\\

-\frac{\pi}{2}, &\mbox{ if } y < 0, x = 0\\

\text{undefined}, &\mbox{ if } y= 0, x = 0\\

\end{array}

\right.

[/tex]

Distance to black hole:

[tex]

\begin{eqnarray*}

r_{c} &=& a(1-\mathit{e} \cos E) \\

&=& 3.15286729 \times 10^{14} \text{metres}

\end{eqnarray*}

[/tex]

Calculate x-coordinate and y-coordinate in random frame (dont think z is necessary for this purpose)

[tex]

\begin{eqnarray*}

x_{rand} &=& r_{c} \cos \nu \\

&=& 2.38188643 \times 10^{14}

\end{eqnarray*}

[/tex]

[tex]

\begin{eqnarray*}

y_{rand} &=& r_{c} \sin\nu \\

&=& 2.06571760 \times 10^{14}

\end{eqnarray*}

[/tex]

Transform to a different random frame treating the black hole at the origin.

[tex]

\begin{eqnarray*}

x &=& x_{rand}(\cos(\omega)\cos(\Omega) - \sin(\omega)cos(i)\sin(\Omega)) - y_{rand}(\sin(\omega)\cos(\Omega)+\cos(\omega)\cos(i)\sin(\Omega)) \\

&=&-5.61288464 \times 10^{14}

\end{eqnarray*}

[/tex]

I think I will stop there as there is a million places the calculation went wrong and chances are they happened in one of the above steps

I am using [itex]3.61 \times 10^6 M_{\odot} \approx 7.18029 \times 10^{36} \text{kg}[/itex] as the black hole's mass

[tex]

a=0.219 \text{ arcsec} =2.62095696128 \times 10^{14} \text{metres}\\

e=0.395\\

P=36\\

t_{0} = 2006.1\\

M=360-\frac{360}{P} (t_{0} - 2016.25) =1.77150919077 \text{ radians}\\

\omega = 250.0 \text{ deg} = 4.363323 \text{ radians}\\

\Omega = 100.0 \text{ deg} = 1.745329 \text{ radians}\\

i = 11 \text{ deg} = 0.191986 \text{ radians}

[/tex]

Eccentric anomaly:

Solve the following equation for E using Newtons method

[tex]f(E) = E - \mathit{e} \sin E - M = 0[/tex]

gives

[tex]E = 2.1103871826[/tex]

True anomaly:

[tex]

\begin{eqnarray*}

\nu &=& 2 \cdot \text{arctan2} (\sqrt{ 1+\mathit{e} } \sin\left( \frac{E}{2}\right),\sqrt{1-\mathit{e}}\cos\left( \frac{E}{2}\right)) \\

&=&0.714430095777

\end{eqnarray*}

[/tex]

where

[tex]

\text{arctan2}(x,y)=

\left\{\begin{array}{cc}

\arctan \frac{y}{x},&\mbox{ if } x \gt 0\\

\arctan \frac{y}{x}+\pi, &\mbox{ if } y\geq 0, x < 0\\

\arctan \frac{y}{x}-\pi, &\mbox{ if } y < 0, x < 0\\

\frac{\pi}{2}, &\mbox{ if } y > 0, x = 0\\

-\frac{\pi}{2}, &\mbox{ if } y < 0, x = 0\\

\text{undefined}, &\mbox{ if } y= 0, x = 0\\

\end{array}

\right.

[/tex]

Distance to black hole:

[tex]

\begin{eqnarray*}

r_{c} &=& a(1-\mathit{e} \cos E) \\

&=& 3.15286729 \times 10^{14} \text{metres}

\end{eqnarray*}

[/tex]

Calculate x-coordinate and y-coordinate in random frame (dont think z is necessary for this purpose)

[tex]

\begin{eqnarray*}

x_{rand} &=& r_{c} \cos \nu \\

&=& 2.38188643 \times 10^{14}

\end{eqnarray*}

[/tex]

[tex]

\begin{eqnarray*}

y_{rand} &=& r_{c} \sin\nu \\

&=& 2.06571760 \times 10^{14}

\end{eqnarray*}

[/tex]

Transform to a different random frame treating the black hole at the origin.

[tex]

\begin{eqnarray*}

x &=& x_{rand}(\cos(\omega)\cos(\Omega) - \sin(\omega)cos(i)\sin(\Omega)) - y_{rand}(\sin(\omega)\cos(\Omega)+\cos(\omega)\cos(i)\sin(\Omega)) \\

&=&-5.61288464 \times 10^{14}

\end{eqnarray*}

[/tex]

I think I will stop there as there is a million places the calculation went wrong and chances are they happened in one of the above steps

Last edited:

- #16

- 41

- 2

[tex]

\mathit{a} = 20.5 \text{ mpc} \\

\mathit{e} = 0.496 \\

\mathit{i} = 120.82 \text{ deg} \\

\Omega = 341.61 \text{ deg} \\

\omega = 115.3 \text{ deg} \\

P = 132 \text{ years}

[/tex]

The trouble with this data (besides being different from the values given for S1 in post 8) is we dont have M or t0 so how would one calculate M for this different set of data?

- #17

tony873004

Science Advisor

Gold Member

- 1,751

- 143

On you previous post, I'm not familiar with that method, but even trying to follow it, I get different answers than you, specifically with E and x.

See here. This will let you play with the numbers. Press "Run" under the code.

http://orbitsimulator.com/code/tdunn/code01.html?sag.txt

- #18

- 41

- 2

https://downloads.rene-schwarz.com/...Orbit_Elements_to_Cartesian_State_Vectors.pdf

Thanks for the new calculator I will play with the numbers and try to see whats going on.

For the new data can I just set M=0 for all stars?

- #19

tony873004

Science Advisor

Gold Member

- 1,751

- 143

- #20

tony873004

Science Advisor

Gold Member

- 1,751

- 143

on second thought, that's too much algebra for me tonight to isolate E. from that equation!

- #21

- 3,564

- 1,345

It starts with the motions of the stars(highly sped up of course), and then finishes by tracing out the orbits.

- #22

tony873004

Science Advisor

Gold Member

- 1,751

- 143

I'm surprised you didn't get a flickering strobe effect.

Unless you go full screen, the res is pretty good.

Did you use this one: http://www.grav-sim.com ?

You can download Camtasia to make screen recordings without the camcorder. It's about $200 but they let you use it for free for 30 days.

There's other free ones out there, but I never had much luck with them. I broke down and spent the $200.

- #23

- 3,564

- 1,345

This is the one I have: http://www.orbitsimulator.com/gravity/articles/what.html

I'm surprised you didn't get a flickering strobe effect.

Unless you go full screen, the res is pretty good.

Did you use this one: http://www.grav-sim.com ?

You can download Camtasia to make screen recordings without the camcorder. It's about $200 but they let you use it for free for 30 days.

There's other free ones out there, but I never had much luck with them. I broke down and spent the $200.

I normally don't have much need to capture video from my computer. Most animations I due are generated frame by frame with Pov-Ray, which I can then assemble into a video. I could have done the same with this one, but it would have been a a lot of work and a lot of time rendering enough frames to show several orbits. It was just simpler to use the gravity simulator.

- #24

- 41

- 2

tony873004 I take it the calculation for E is still cactus in your code01.html calculator? I thought my E=2.11 was pretty close

- #25

tony873004

Science Advisor

Gold Member

- 1,751

- 143

I fixed E. Still get a different x than you.tony873004 I take it the calculation for E is still cactus in your code01.html calculator?

http://orbitsimulator.com/code/tdunn/code01.html?sag.txt

That's the one I wrote.This is the one I have: http://www.orbitsimulator.com/gravity/articles/what.html

If you have the latest version you can make it take a series of screen shots which can then be assembled into an animated GIF or perhaps to YouTube to animate. (see post 47: http://www.orbitsimulator.com/cgi-bin/yabb/YaBB.pl?num=1176774875/45#45.)Unfortunately, the Sim has no way to generate videos directly

- Last Post

- Replies
- 2

- Views
- 9K

- Last Post

- Replies
- 3

- Views
- 6K

- Last Post

- Replies
- 1

- Views
- 2K

- Last Post

- Replies
- 3

- Views
- 17K

- Last Post

- Replies
- 4

- Views
- 2K

- Last Post

- Replies
- 2

- Views
- 2K

- Replies
- 0

- Views
- 2K

- Last Post

- Replies
- 18

- Views
- 2K

- Replies
- 4

- Views
- 3K

- Last Post

- Replies
- 15

- Views
- 2K