# Composite numbers and perfect squares

Suppose $a$ is a positive integer $(2a+1)$ and $(3a+1)$ are perfect squares. Prove that $(5a+3)$ is a composite number. I really do not know the relationship between perfect squares and composite numbers.

$2a+1=m^2$ and $3a+1=n^2$ for some positive integers $m,n$. Then $3m^2-2n^2=1$. Also $5a+3=(2a+1)+(3a+1)+1=m^2+n^2+1=m^2+n^2+(3m^2-2n^2)=4m^2-n^2$. This is a difference of two squares, hence a product. I leave it to you to show that neither factor is 1, and hence $5a+3$ is composite.