  The origin of the so called 'detached shells' around AGB stars is not fully
understood, but two common hypotheses state that these shells form either
through the interaction of distinct wind phases or an eruptive mass loss
associated with a He-shell flash. We present a model of the formation of
detached shells around thermal pulse asymptotic giant branch (TP-AGB) stars,
based on detailed modelling of mass loss and stellar evolution, leading to a
combination of eruptive mass loss and wind interaction.
  The purpose of this paper is first of all to connect stellar evolution with
wind and mass loss evolution and demonstrate its consistency with observations,
but also to show how thin detached shells around TP-AGB stars can be formed.
Previous attempts to link mass loss evolution with the formation of detached
shells were based on approximate prescriptions for the mass loss and have not
included detailed modelling of the wind formation as we do here. (abridged)
