  In this paper, we theoretically propose a method to simulate the longitudinal
relaxation of a single qubit by coupling it to an auxiliary qubit. In order to
mimic the finite-temperature relaxation, we utilize the Hamiltonian-ensemble
approach [Kropf, Gneiting, and Buchleitner, Phys. Rev. X 6, 031023 (2016)] and
in each realization the auxiliary qubit possesses a random level spacing. The
longitudinal relaxation arises as a consequence of the ensemble average and the
interaction between the working qubit and the auxiliary qubit. Furthermore, we
apply this approach to investigate the influence of the longitudinal relaxation
and the transverse relaxation on the entanglement dynamics of two qubits. It is
discovered that the sudden death of the entanglement will occur as long as the
longitudinal relaxation is present. The transverse relaxation assists the
longitudinal relaxation and thus accelerates the finite-time disentanglement.
