The given expression can be written as :

In the numerator x can be taken as a common factor to give x(x+3x)
In denominator the first factors are x in both the parenthesis .We then find two numbers which when multiplied will give us 1 and the same numbers on addition should give us -2.The numbers are -1 and -1 .These are written next to x in both the parenthesis .The factors of denominator are (x-1)(x-1) .This can not be simplified further.