Two phase modal analysis of nonlinear sloshing in a rectangular container