An inversion method to analyze the rupture processes of earthquakes using near-field seismograms