  We study the time evolution of two protoplanets still embedded in a
protoplanetary disk. The results of two different numerical approaches are
presented and compared. In the first approach, the motion of the disk material
is computed with viscous hydrodynamical simulations, and the planetary motion
is determined by N-body calculations including exactly the gravitational forces
exerted by the disk material. In the second approach, only the N-body
integration is performed but with additional dissipative forces included such
as to mimic the effect of the disk torques acting on the disk. This type of
modeling is much faster than the full hydrodynamical simulations, and gives
comparative results provided that parameters are adjusted properly.
  Resonant capture of the planets is seen in both approaches, where the order
of the resonance depends on the properties of the disk and the planets.
Resonant capture leads to a rise in the eccentricity and to an alignment of the
spatial orientation of orbits. The numerical results are compared with the
observed planetary systems in mean motion resonance (Gl 867, HD 82943, and 55
Cnc). We find that the forcing together of two planets by their parent disk
produces resonant configurations similar to those observed, but that
eccentricity damping greater than that obtained in our hydrodynamic simulations
is required to match the GJ 876 observations.
