Question 698546
<pre>
The formula for the perpendicular distance from (x<sub>1</sub>,y<sub>1</sub>)
to the line whose equation is Ax+By+C=0 is

d = {{{abs((Ax[1]+By[1]+C)/sqrt(A^2+B^2))}}}

The line has the equation

{{{x/a}}} + {{{y/b}}} = 1  

[Don't get capital A and B confused with little letters a and b]

Clear of fractions by multiplying by LCD = ab:

     bx + ay = ab

Get 0 on the right

bx + ay - ab = 0

For (x<sub>1</sub>,y<sub>1</sub>) = (0,0)

Substitute in

d = {{{abs((Ax[1]+By[1]+C)/sqrt(A^2+B^2))}}}

with d = p, A = b, B = a, C = -ab, (x<sub>1</sub>,y<sub>1</sub>) = (0,0)

p = {{{abs((b*(0)+a*(0)-ba)/sqrt(b^2+a^2))}}}

p = {{{abs(-ba/sqrt(b^2+a^2))}}}

Square both sides

pē = {{{b^2a^2/(b^2+a^2)}}}

Take the reciprocal of both sides:

{{{1/p^2}}} = {{{(b^2+a^2)/(b^2a^2)}}}

Make two fractions on the right:

{{{1/p^2}}} = {{{b^2/(b^2a^2)+a^2/(b^2a^2)}}}

{{{1/p^2}}} = {{{cross(b^2)/(cross(b^2)a^2)+cross(a^2)/(b^2cross(a^2))}}}

{{{1/p^2}}} = {{{1/a^2+1/b^2}}}

Edwin</pre>