Let the point P be (h,k)
Draw PL′ parallel to MO and PL parallel to NO
In △PLMcosω=LMPL
OM=OL+LMOM=h+kcosω
So, the coordinates of M are (h+kcosω,0)
In △PL′Ncosω=L′NPL′
⇒L′N=PL′cosω=hcosωON=OL′+L′NON=k+hcosω
So, the coordinates of N are (0,k+hcosω)
Slope of MN =k+hcosω−00−h+kcosω=−k+hcosωh+kcosω
MN is parallel to y=mx
⇒−k+hcosωh+kcosω=mk+hcosω=−mh−mkcosωk+mkcosω+hcosω+mh=0k(1+mcosω)+h(m+cosω)=0
Replacing h by x and y by k
y(1+mcosω)+x(m+cosω)=0
is the required locus of P.