Mathematical models of imbibition under different boundary conditions were built with piston-like displacement assumption. Effect of gravity and capillary pressure on imbibition under OEO (single boundary) and TEO-OW (mixed boundary) boundary conditions are studied. It shows that oil is produced only by counter-current imbibition under OEO boundary conditions. Gravity inhibits imbibition as the open face is at the lower end face of core and gravity promotes imbibition as the open face is at the upper end face of core. Oil is produced by combination of co-and counter-current imbibition under TEO-OW boundary condition. Gravity inhibits counter-current imbibition and promotes co-current imbibition under TEO-OW boundary condition. Gravity is dominant driving force as the inverse Bond number is smaller and capillary pressure is dominant driving force as inverse Bond number is greater. In addition, effect of gravity and capillary pressure on imbibition under OEO and TEO-OW boundary conditions are studied. It shows that oil production by gravity under OEO boundary condition is greater than that under TEO-OW boundary condition with same inverse Bond number. The rate of oil production under OEO boundary condition is faster than that under TEO-OW boundary condition as inverse Bond number is smaller and opposite phenomena is observed as inverse Bond number is greater.