# Conversion from au to mas

I am trying to verify whether the third column is correct. The second column is radius of orbit with period corresponding to Gaia DR2 observing window duration.

d_pc         OrbG2  Orb_mas
99.32459277  1.905  0.356777803
431.7789292  2.689  6.227724
7751.937984  5.74   0.74046
35.25471532  1.583  0.835263191
346.2603878  2.631  7.598328


What is wrong with this conversion, please?

I obtained this instead of the third column:

0      19.179401
1       6.227679
2       0.740455
3      44.901469
4       7.598273

• You have to be a bit more verbose in what you do. Just writing a formula without explanation doesn't cut it. What are the columns and your units in your table, and are they what you think they are? Jul 8, 2022 at 7:53

Your conversion is correct, and Python agrees with you:

import numpy as np
from astropy import units as u
d = np.array([99.32459277,
431.7789292,
7751.937984,
35.25471532,
346.2603878]) * u.pc
D = np.array([1.905,
2.689,
5.74,
1.583,
2.631]) * u.AU
for t in theta:
print('{:9.6f}'.format(t.to(u.mas)))


which outputs

19.179540 mas
6.227724 mas
0.740460 mas
44.901795 mas
7.598328 mas


You should probably check what the third column actually represents.

• Thank you so much Jul 8, 2022 at 11:26
• @Anna-Kat You're welcome! If you don't yet know astropy (in particular its use of units), I highly recommend starting to use it. It's a fantastic tool, under continuous development, and well documented :)
– pela
Jul 8, 2022 at 12:04