In the given right triangle of the figure
we have that
sin(O)=1/d ----> by the opposite side divided by the hypotenuse in a right triangle
solve for d
d=1/sin(O)
d=4,124,966.13 AU -----> two decimal places
the expression to calculate d for any star is equal to