Formatting Linear equation

54 Views Asked by At

How do I craft a linear equation so that it is in the form of $ax + bx + c = 0$ where $a^2 + b^2 = 1$ if I have two points? I know how to get it into the form $ax + bx + c = 0$ but I can't figure out the algorithm for satisfying the second condition.

2

There are 2 best solutions below

0
On

Starting from a linear equation $jx+k=0$, dividing by k we get $\frac{j}k\,x+1=mx+1=0$. Now we have to solve the system formed by the equations $a+b=m$ and $a^2+b^2=1$. This leads to $a^2 -am+m^2/2-1/2=0$. The equation has real solutions for $2-m^2>=0$, i.e., m ranging between $-\sqrt{2}$ and $\sqrt{2}$. In this case, $a=m/2\pm\sqrt{2-m^2}/2$ and $b=m/2\mp\sqrt{2-m^2}/2$.

0
On

I'm assuming you meant $ax + by + c = 0$ so that this equation is that of a line.

If you have $ax + by + c = 0$, then calculate $m = \sqrt{a^2 + b^2}$. Then dividing by $m$, $\frac{a}{m}x + \frac{b}{m}y + \frac{c}{m} = 0$ satisfies the condition.