Electron transport in realistic physical and chemical systems often involves the nontrivial exchange of energy with a large environment, requiring the definition and treatment of open quantum systems. Because the time evolution of an open quantum system employs a nonunitary operator, the simulation of open quantum systems presents a challenge for universal quantum computers constructed from only unitary operators or gates. Here, we present a general algorithm for implementing the action of any nonunitary operator on an arbitrary state on a quantum device. We show that any quantum operator can be exactly decomposed as a linear combination of at most four unitary operators. We demonstrate this method on a two-level system in both zero and finite temperature amplitude damping channels. The results are in agreement with classical calculations, showing promise in simulating nonunitary operations on intermediate-term and future quantum devices.