Transient stability analysis of power systems using Liapunov's second method