The scalar potential of the 331 model: theoretical constraints