Polarization switching in ferroelectric thin film induced by a single-period terahertz pulse