Theoretical study of sodium nitrite piezoelectricity and elasticity