Numerical simulation of pulse propagation in nonlinear 1-D media