Hello, Mhmh96!
$\displaystyle \text{Factor: }\;x^2 + x + 6y^2 + 3y + 5xy$
We have: .$\displaystyle (x^2 + 5xy + 6y^2) + (x + 3y)$
. . . . . . $\displaystyle =\;(x+3y)(x + 2y) + (x+3y)$
. . . . . . $\displaystyle =\;(x+3y)(x + 2y+1)$
$\displaystyle \text{Factor: }\; x^2 + (a + \tfrac{1}{a})xy + y^2$
$\displaystyle x^2 + (a + \tfrac{1}{a})xy + y^2$
. . $\displaystyle =\; x^2 + axy + \tfrac{1}{a}xy + y^2$
. . $\displaystyle =\;x(x + ay) + \tfrac{1}{a}y(x + ay) $
. . $\displaystyle =\;(x+ay)(x + \tfrac{1}{a}y) $