Singlet and triplet states in the reactions of nitrenium ions