<p>Both formulae are correct since for very small angles, <span class="math-container">$\tan(p) = p$</span> (approximately, but the approximation is very very good for the tiny angles we are talking about here)</p>
<p>So it is easier and correct to use 1/p.  If a star has a parallax of (say) 0.5 arcseconds, then its distance is 2 parsecs (about 6.5 light years)</p>
<p>Often the parallax is quoted in &quot;milli-arcseconds&quot; or &quot;mas&quot;. If a star has a parallax of 25 mas, its distance is 1000/25 =40 parsecs (about 130 light years)</p>
<p>For very distant stars, you should be aware that the uncertainty is very significant. If the parallax is 0.4mas ± 0.6mas, then the true parallax is between 0 and 1.0 mas (it can't actually be negative), so while the most likely distance is about 1000/0.4 = 2500 parsecs, the distance could be between 1000 and infinity parsecs. Some object actually have negative values quoted for their parallax, this just means that the object is so distant that no significant parallax was detected.</p>

CC BY-SA 4.0
2024-10-09T19:27:01.247Z
2024-10-09T19:27:01.247Z
James K
<p>You could use the first formula, but <span class="math-container">$d \sim 1/p$</span> gives the distance in parsecs only when <span class="math-container">$p$</span> is expressed in arcseconds.</p>
<p>The formula <span class="math-container">$d \sim 1/\tan p$</span> is only correct if <span class="math-container">$p$</span> is converted to radians and you want the distance in astronomical units. That answer can then of course be converted to parsecs by dividing by the number of astronomical units in a parsec.</p>
<p>Arguably, the second method is &quot;more accurate&quot; in the sense that the first uses the approximation that <span class="math-container">$\theta \simeq \tan\theta$</span> when <span class="math-container">$\theta$</span> is expressed in radians and is very much less than 1.</p>
<p>In practice, for even the nearest stars, that approximation causes many orders of magnitude less error than is present in the available parallax measurements. A more significant concern is that <strong>neither formula gives an accurate estimate of the most likely distance unless the uncertainty in the parallax is much less than the parallax itself</strong>. Say by a factor of 10 or more. That is not the case for many, if not most, of the parallaxes in the Hipparcos catalogue.</p>
<p>If a cross-match is available, then you should be using parallaxes for the same stars that are available in the Gaia DR3 catalogue, since these will usually be more accurate. A number of brighter stars were too bright for Gaia though. For those you should be using the revised catalogue of Hipparcos parallaxes prepared by
<a href="https://www.aanda.org/articles/aa/abs/2007/41/aa8357-07/aa8357-07.html" rel="nofollow noreferrer">van Leeuwen (2007)</a>.</p>
<p>To do the job properly, you should be using the Bayesian approach to distance estimation from parallax, proposed by <a href="https://iopscience.iop.org/article/10.3847/1538-3881/abd806" rel="nofollow noreferrer">Bailer Jones et al. (2021)</a> This will also handle the issue of what happens if the parallax is negative or the parallax uncertainty allows a significant probability of a negative parallax.</p>

CC BY-SA 4.0
2024-10-10T06:18:06.980Z
2024-10-10T06:24:24.730Z
2024-10-10T06:24:24.730Z
ProfRob
<p>I'm developing a VR application using the Hipparcos catalogue to get the right ascension and declination to show them.</p>
<p>I need to know the distance between all of these stars from the catalogue, and I'm not sure if I'm doing right. To get the distance I use the field H11 from the catalogue, which description is:</p>
<pre><code>H11         Plx        Parallax           /Trigonometric parallax
</code></pre>
<p>To get the distance, I have found two possible solutions:</p>
<p>One, here &quot;<a href="http://cas.sdss.org/DR6/en/proj/advanced/hr/hipparcos2.asp" rel="nofollow noreferrer">Calculating Distances from Parallax Angles</a>&quot;, where <strong>p</strong> is the parallax and the distance <strong>d</strong> is:</p>
<p><span class="math-container">$$d=\frac{1}{p}$$</span></p>
<p>And another one here &quot;<a href="https://www.celestialprogramming.com/snippets/starxyz.html" rel="nofollow noreferrer">Celestial Programming : Rectangular 3D Position Of A Star</a>&quot;, where the distance is:</p>
<p><span class="math-container">$$d=\frac{1}{tan(p)}$$</span></p>
<p>My question is:</p>
<p>How can I calculate the distance between a star in the Hipparcos catalogue and the Earth?</p>

CC BY-SA 4.0
2024-10-10T17:05:38.280Z
**Comments have been [moved to chat](https://chat.stackexchange.com/rooms/155656/discussion-on-question-by-vansfannel-how-can-i-calculate-the-distance-between-a); please do not continue the discussion here.** Before posting a comment below this one, please review the [purposes of comments](/help/privileges/comment). Comments that do not request clarification or suggest improvements usually belong as an [answer](/help/how-to-answer), on [meta], or in [chat]. Comments continuing discussion may be removed.
Connor Garcia
<observational-astronomy><distances><star-catalogues><parallax><hipparcos>
How can I calculate the distance between a star in the Hipparcos catalogue and the Earth?
VansFannel
# How can I calculate the distance between a star in the Hipparcos catalogue and the Earth?

(Asked by: username_0 on 2024-10-09)

I'm developing a VR application using the Hipparcos catalogue to get the right ascension and declination to show them.

I need to know the distance between all of these stars from the catalogue, and I'm not sure if I'm doing right. To get the distance I use the field H11 from the catalogue, which description is:

```
H11         Plx        Parallax           /Trigonometric parallax

```

To get the distance, I have found two possible solutions:

One, here "[Calculating Distances from Parallax Angles](http://cas.sdss.org/DR6/en/proj/advanced/hr/hipparcos2.asp)", where **p** is the parallax and the distance **d** is:

$$d=\frac{1}{p}$$

And another one here "[Celestial Programming : Rectangular 3D Position Of A Star](https://www.celestialprogramming.com/snippets/starxyz.html)", where the distance is:

$$d=\frac{1}{tan(p)}$$

My question is:

How can I calculate the distance between a star in the Hipparcos catalogue and the Earth?

**Tags:** observational-astronomy, distances, star-catalogues, parallax, hipparcos

> **Comments:**
> **username_1**: **Comments have been [moved to chat](https://chat.stackexchange.com/rooms/155656/discussion-on-question-by-username_0-how-can-i-calculate-the-distance-between-a); please do not continue the discussion here.** Before posting a comment below this one, please review the [purposes of comments](/help/privileges/comment). Comments that do not request clarification or suggest improvements usually belong as an [answer](/help/how-to-answer), on [meta], or in [chat]. Comments continuing discussion may be removed.  

---

## 2 answers

### Answer by username_2 on 2024-10-09. Score: 3 | Accepted answer

Both formulae are correct since for very small angles, $\tan(p) = p$ (approximately, but the approximation is very very good for the tiny angles we are talking about here)

So it is easier and correct to use 1/p. If a star has a parallax of (say) 0.5 arcseconds, then its distance is 2 parsecs (about 6.5 light years)

Often the parallax is quoted in "milli-arcseconds" or "mas". If a star has a parallax of 25 mas, its distance is 1000/25 =40 parsecs (about 130 light years)

For very distant stars, you should be aware that the uncertainty is very significant. If the parallax is 0.4mas ± 0.6mas, then the true parallax is between 0 and 1.0 mas (it can't actually be negative), so while the most likely distance is about 1000/0.4 = 2500 parsecs, the distance could be between 1000 and infinity parsecs. Some object actually have negative values quoted for their parallax, this just means that the object is so distant that no significant parallax was detected.


---

### Answer by username_3 on 2024-10-10. Score: 2

You could use the first formula, but $d \sim 1/p$ gives the distance in parsecs only when $p$ is expressed in arcseconds.

The formula $d \sim 1/\tan p$ is only correct if $p$ is converted to radians and you want the distance in astronomical units. That answer can then of course be converted to parsecs by dividing by the number of astronomical units in a parsec.

Arguably, the second method is "more accurate" in the sense that the first uses the approximation that $\theta \simeq \tan\theta$ when $\theta$ is expressed in radians and is very much less than 1.

In practice, for even the nearest stars, that approximation causes many orders of magnitude less error than is present in the available parallax measurements. A more significant concern is that **neither formula gives an accurate estimate of the most likely distance unless the uncertainty in the parallax is much less than the parallax itself**. Say by a factor of 10 or more. That is not the case for many, if not most, of the parallaxes in the Hipparcos catalogue.

If a cross-match is available, then you should be using parallaxes for the same stars that are available in the Gaia DR3 catalogue, since these will usually be more accurate. A number of brighter stars were too bright for Gaia though. For those you should be using the revised catalogue of Hipparcos parallaxes prepared by
[van Leeuwen (2007)](https://www.aanda.org/articles/aa/abs/2007/41/aa8357-07/aa8357-07.html).

To do the job properly, you should be using the Bayesian approach to distance estimation from parallax, proposed by [Bailer Jones et al. (2021)](https://iopscience.iop.org/article/10.3847/1538-3881/abd806) This will also handle the issue of what happens if the parallax is negative or the parallax uncertainty allows a significant probability of a negative parallax.


---

