A mathematical model of free surface is presented for the study of the nitrogen injection of the gas cap for maintain of pressure, we used one model dispersion a flow in well zone. Nitrogen injected into the cap has a density greater than the original gas which has rushed to the gas-oil contact goc. Since the goc on the border there is a lot of nitrogen gas, it will spread and disperse into the oil. In the goc around a well about to be invaded by gas coning phenomena occur; therefore the model to interpret the output of the well must include the phenomenon of free surface. This paper proposes a method to measure the degree of contamination of the oil zone. This compositional data based on a production well before being invaded in producing interval by the gas cap. The most contaminated area of oil is close to the goc, as nitrogen is expected to exit the current production from the well just before being overcome by gas.