A new calculation method is presented that allows the use of the acoustic characteristics of a given singularity as a boundary condition for a non-linear one-dimensional flow calculation. The method is based, on the one hand, on the non-linear decomposition of the pressure perturbation into forward and backward components; and, on the other hand, on the possibility of representing a certain singularity by means of its reflection and transmission coefficients. The response of the singularity to the incident pressure components is calculated in the frequency domain and imposed as a boundary condition for the time domain calculation in the rest of the duct, the procedure being iterative. In this way, the calculation takes into account both the acoustic behaviour of the singularity and its interaction with the acoustic source and the rest of the system considered. The method is applied to the computation of the flow in the exhaust pipe of a four cylinder spark-ignition engine when a complex commercial silencer is used, and the results show good agreement with experimental measurements, both for in-duct pressure and for radiated noise.