Numerical simulation of flowfields in a plug nozzle with reacting flow