Let's rearrange and factorise the inequality
#(q+4)^2>10q+31#
#q^2+8q+16>10q+31#
#q^2+8q+16-10q-31>0#
#q^2-2q-15>0#
#(q+3)(q-5)>0#
Let #f(q)=(q+3)(q-5)#
We can build the sign chart
#color(white)(aaaa)##q##color(white)(aaaa)##-oo##color(white)(aaaa)##-3##color(white)(aaaa)##5##color(white)(aaaa)##+oo#
#color(white)(aaaa)##q+3##color(white)(aaaaa)##-##color(white)(aaaa)##+##color(white)(aaaa)##+#
#color(white)(aaaa)##q-5##color(white)(aaaaa)##-##color(white)(aaaa)##-##color(white)(aaaa)##+#
#color(white)(aaaa)##f(q)##color(white)(aaaaaa)##+##color(white)(aaaa)##-##color(white)(aaaa)##+#
Therefore,
#f(q)>0# when #q in (-oo, -3) uu (5, +oo)#
graph{(x+4)^2-10x-31 [-27.53, 23.8, -17.2, 8.47]}