A method of producing a liquid nitrogen stream, a gaseous nitrogen stream, a gaseous stream which is rich in helium and a denitrided stream of hydrocarbons from a feed stream which contains hydrocarbons, nitrogen and helium, the method comprising the following steps:
- expanding the feed stream in order to form an expanded feed stream;
- dividing the expanded feed stream into a first introduction stream and a second introduction stream;
- cooling the first introduction stream within an upstream heat exchanger by heat exchange with a gaseous refrigerant stream which is obtained by dynamic expansion in a cooling cycle in order to obtain a first cooled introduction stream;
- forming a second cooled introduction stream by cooling, using a first downstream heat exchanger, the second introduction stream;
- introducing the first cooled introduction stream and the second cooled introduction stream into a fractionating column which comprises a plurality of theoretical fractionating stages;
- tapping at least one reboiling stream and circulating the reboiling stream in the first downstream heat exchanger in order to cool the second introduction stream;
- tapping, at a bottom of the fractionating column, a bottom stream which forms the denitrided stream of hydrocarbons;
- tapping, at a head of the fractionating column, a head stream which is rich in nitrogen;
- reheating the head stream by at least one second downstream heat exchanger in order to form a reheated stream which is rich in nitrogen;
- tapping and expanding a first portion of the reheated stream in order to form the gaseous nitrogen stream;
- compressing a second portion of the reheated stream in order to form a compressed, recycled nitrogen stream, and cooling the compressed, recycled nitrogen stream by circulation through the first downstream heat exchanger and/or each second downstream heat exchanger;
- liquefying and partially expanding the recycled nitrogen stream in order to form an expanded nitrogen rich stream;
- introducing at least a portion obtained from the expanded nitrogen rich stream into a first separation container;
- recovering the gaseous head stream from the first separation container in order to form the helium rich stream;
- recovering the liquid stream from the bottom of the first separation container and separating the recovered liquid stream into a liquid nitrogen stream and a first reflux stream;
- introducing, as reflux, the first reflux stream into the head of the fractionating column;
- introducing the nitrogen rich expanded stream upstream of the second downstream heat exchanger into a second separation container positioned upstream of the first separation container and upstream of the second downstream heat exchanger;
- introducing the head stream from the second separation container successively into the second heat exchanger and into the first separation container,
- wherein the introducing of the head stream from the second separation container into the first separation container is performed without the head stream being expanded in any expansion device;
- and
- introducing, as reflux, at least a portion of the bottom stream of the second separation container into the head of the fractionating column.