factor 3m^3+8mn+3m^2+8n