Effect of Viscous and Buoyancy Forces on Nonwetting Phase Trapping in Porous Media