This homework should give you some appreciation of the power of simulation. It is based on the Streeter-Phelps equations that are developed in conjuction with Exercise 5.2 in the book. The Streeter-Phelps equations are in the book. The idea is that microorganisms destroy the pollutants but consume oxygen in doing so. The driving force for more oxygen from air to replenish the dissolved oxygen is the difference between the actual concentration and the concentration if saturated with oxygen.
Temperature has an effect on the rate coefficient and on the saturation concentration.
These are merely expressions for illustration. They are NOT real. Assume that there is a creek running past your factory. Someone has proposed that since you own all the land around the creek, perhaps you can use it for waste treatment. If you do not deplete the dissolved oxygen, the fish will not die and your creek will be considered healthy.