A procedure for deriving thermodynamic properties of gases from speed of sound is presented. It is based on numerical integration of ordinary differential equations (ODEs) (rather than partial differential equations-PDEs) connecting speed of sound with other thermodynamic properties in the T -p domain. The procedure enables more powerful methods of higher-order approximation to ODEs to be used (e.g., Runge-Kutta) and requires only Dirichlet initial conditions. It was tested on gaseous argon in the temperature range from 250 to 450 K and in the pressure range from 0.2 to 12 MPa, and also on gaseous methane in the temperature range from 275 to 375 K and in the pressure range from 0.4 to 10 MPa. The density and isobaric heat capacity of argon were derived with absolute average deviations of 0.007% and 0.03%, respectively. The density and isobaric heat capacity of methane were derived with absolute average deviations of 0.006% and 0.09%, respectively.