variavel0=A.D. BUENO - andre@lmpt.ufsc.br UFSC F.S. MAGNANI - magnani@demec.ufpe.br UFPE P.C. PHILIPPI - philippi@lmpt.ufsc.br UFSC Abstract. For the simulation of two-phase flow inside reconstructed three-dimensional structure, it is necessary to identify the regions occupied by each fluid, i.e., to locate the wetting and non-wetting phases. The problem is complicated by the difficulty in determining the equilibrium interfaces, considering the dynamic instabilities due to the competitions between the inertial, superficial tensions and viscous forces. In this work, important alterations in the computational algorithm developed by Magnani et. al. [2000] [Magnani, F. S., Philippi, P. C., Liang, Z. Fernandes, C. P., 2000., Modelling Two-Phase Equilibrium in Three-Dimensional Porous Microstructures. "Int. J. Multiphase Flow"], are presented, which make possible its application for new geometries for deepening of through tests and the validations, for different reservoir rock founds in Brazil. These rocks being of strategical importance for the oil industry. A module for the determination of the relative permeability has been added using the new algorithms. The new algorithm is validate against experimental data of mercury intrusion, and new results are presented for the simulation of imbibition, drainage, hysteresis and relative permeability. Keywords. equilibrium configuration, hysteresis, relative permeability, petroleum reservoir-rocks.