If I have $ P(x,y)$, what would be the reflected point with respect to fixed line through origin O?
Does it depend on what line I have, If I have $x$ or $2x$ $3x$, they all pass through origin.
If I have $ P(x,y)$, what would be the reflected point with respect to fixed line through origin O?
Does it depend on what line I have, If I have $x$ or $2x$ $3x$, they all pass through origin.
Let $P(p,q)$ be the point you have and let $y=ax\ (a\not=0)$ be the line we consider.
Then, let $Q(X,Y)$ be the point you want.
First, since the midpoint of the line segment $PQ$ is on the line $y=ax$, we have $$\frac{q+Y}{2}=a\cdot \frac{p+X}{2}.$$ Second, since the line $PQ$ is perpendicular to the line $y=ax$, we have $$-\frac 1a=\frac{Y-q}{X-p}.$$ Solving these gives you $$X=\frac{2aq+(1-a^2)p}{a^2+1},\ \ \ Y=\frac{2ap+(a^2-1)q}{a^2+1}.$$