Given known and and unknown line equation and maximising area of triangle condition. 
Q) If from a point $P\equiv(4,4)$ perpendiculars to the straight lines
  $-3x+4y+5=0$ and $y=mx+7$ meet at $Q$ and $R$ and area of triangle
  $PQR$ is maximum then $m=__ $ ?

First I drew the known line $-3x+4y+5=0$ and the unknown line $y=mx+7$ then I fixed the perpendicular distance from $P(4,4)$ as a fixed value $b$ .
I also know that area of a triangle $\dfrac{1}2 \times base \times height$ so to maximise this area we need $base=height$
I took $base$ as my assumed constant $b$ 
Then I found out $b=9/5$
Then I substituted in distance formula and I have no idea how to proceed further 
$\frac{9}{5}=\frac{-4m+4+c}{\sqrt{m^{2}+1}}$
 A: Dropping the perpendicular from $P$ onto the given line $g: \>-3x+4y+5=0$ gives the point $Q$. We can consider $PQ$ as base of our triangle and then have to make the corresponding height as large as possible. All lines $h_m:\>y=mx+7$, $m\in{\mathbb R}$, pass through the point $Z=(0,7)$. Since $\angle(PRZ)={\pi\over2}$ the point $R$ has to lie on the Thales circle over the segment $PZ$. The center of this circle is the point $M=\bigl(2,{11\over2}\bigr)$, and its radius computes to ${5\over2}$. The optimal point $R$ is then found as follows: Draw a parallel $g'$ to $g$ through the point $M$ and intersect it with the circle. Take the better of the two points so obtained; it is the left one. Looking at the symmetries of the figure one realizes that $R=(0,4)$. This means that there is a largest triangle $PQR$ satisfying $\angle(PRZ)={\pi\over2}$, but strictly speaking $h_*:=R\vee Z$ does not belong the given family of lines $(h_m)_{m\in{\mathbb R}}$, since $h_*$ is vertical.

A: First, I found the equation of lines which form the triangle. 


*

*$y-4=\frac{-1}{m}(x-4)$ which is the line perpendicular to $y=mx+7$ and passing through $P(4,4)$

*$y-4=\frac{4}{3}(x-4)$ represents the line perpendicular to $3x+4y+5=0$ and passing through $P(4,4)$
Next, I need information about vertices of the triangle. One of the vertex can be obtained by solving $y-4=\frac{-1}{m}(x-4)$ and $y=mx+7$ which is
$$h=\frac{4-3m}{1+m^2}$$
and $$k=\frac{4m-3m^2}{1+m^2}+7$$
Now, area of triangle is given by $\frac{1}{2}ab\sin\theta$. It easy to observe that one of the side is fixed. (The side formed by given point and fixed line). Let that side be $a$. Now, all that remains is to maximize $b\sin\theta$ which represents the altitude of the triangle. 
To get altitude of the triangle, I need to find the perpendicular distance from $(h,k)$ to side $a$. 
Side $a$ is given by the line $y-4=\frac{4}{3}(x-4)$ which can be written as $$3y-4x+4=0$$
the perpendicular distance formula, $$d(m)=\frac{3k-4h+4}{\sqrt{4^2+3^2}}$$
The graph of $d(m)$ looks like this:


So, when the lines are perpendicular, you get maximum area of triangle.
  That is, $m=\frac{4}{3}$

A: First of all your sentence:"I also know that area of a triangle 12base×height so to maximise this area we need base=height" is so wrong cause this triangle is under some constraints and maybe this is not possible. Second, this problem is easy but you have to write it with this hints:
Choose PQ as triangle base and find corresponding height. To find that first write equation of line PR (as a function of m) then find coordinate of point R, now find distance of R from line PQ. So you have a scaler function of m that want to be maximized. Go ahead.
