Aiming at the characteristic of the strong coupling between ammonia nitrogen and nitrate nitrogen,and the conventional PID control method is difficult to achieve satisfactory control performance,this paper employed a PID neural network approach to achieve decoupling control for ammonia nitrogen and nitrate nitrogen,where regarded dissolved oxygen concentration and internal circulation flow as the control inputs.PID neural network connection weights were easy to fall into local optimum.In order to solve this problem,proposed the immune algorithm to optimize the connection weights of PID neural network.Simulation results show that the proposed method has a better decoupling capabilities and control quality for biological wastewater treatment system.