Effects of porosity on seismic velocities, elastic moduli and Poisson's ratios of solid materials and rocks