Search for a command to run...
This thesis focuses on developing advanced optimization and control methods for phosphorus removal in wastewater treatment plants (WWTPs).The goal is to comply with regulatory effluent standards while minimizing operational costs.To achieve this, a deep reinforcement learning (DRL) framework was employed, leveraging its capability to learn optimal policies through iterative interactions with simulated environments.The research first addressed the lack of accurate simulation models for the phosphorus removal process.Using historical data from the Agtrup WWTP in Kolding, Denmark, six deep learning models were evaluated for one-step prediction accuracy, achieving an accuracy of 97%.However, challenges emerged in multi-step simulations due to compounding errors, necessitating two improvement phases.The Long Short-Term Memory (LSTM) model was enhanced in the first phase with iterative correction techniques and a novel loss function.This reduced simulation errors by up to 98% in Dynamic Time Warping, resulting in a more reliable simulator for long-term forecasting.The second phase integrated exogenous state variables into the simulation, further improving mean squared error by 55% and Dynamic Time Warping by 34% compared to the baseline model.With the simulator established, the Soft Actor-Critic (SAC) algorithm was employed to optimize phosphorus removal strategies.Accounting for time delays, three scenarios-No Delay (ND), Constant Delays (CD), and Random Delays (RD)-were evaluated.The SAC-RD agent achieved significant improvements, including a 36% reduction in phosphorus emissions, a 55% increase in total reward, a 77% reduction in phosphate concentration deviation, and a 9% decrease in total costs compared to the traditional Proportional-Integral-Derivative (PID) controller.This thesis demonstrates that combining deep reinforcement learning with deep learning-based simulators, trained exclusively on historical time series data, can surpass traditional wastewater treatment plant optimization and control methods.The proposed approach can reduce phosphorus emissions, operational costs, and metal salt usage while ensuring regulatory compliance.Furthermore, this scalable framework offers potential applications in optimizing other industrial processes reliant on time series data.iii ResumDenne afhandling fokuserer p udvikling af avancerede optimerings-og kontrolmetoder til fjernelse af fosfor i spildevandsrensningsanlaeg (WWTP'er).Mlet er at overholde lovgivningsmaessige krav til udledninger og samtidig minimere driftsomkostninger.For at opn dette blev en deep reinforcement learning (DRL) anvendt, som udnytter dens evne til at laere optimale strategier gennem iterative interaktioner med simulerede miljer.Forskningen tog frst fat p manglen p praecise simuleringsmodeller til fosforfjernelse.Ved hjaelp af historiske data fra Agtrup WWTP i Kolding, Danmark, blev seks dybe laeringsmodeller evalueret for deres praecision i t-trins forudsigelser, og opnede en praecision p 97%.Dog opstod udfordringer i multi-trins simuleringer p grund af akkumulerede fejl, hvilket gjorde det ndvendigt med to forbedringsfaser.I den frste fase blev Long Short-Term Memory (LSTM)-modellen forbedret med iterative korrektionsteknikker og en ny tabsfunktion.Dette reducerede simuleringsfejl med op til 98% i Dynamic Time Warping, hvilket resulterede i en mere plidelig simulator til langsigtede forudsigelser.Den anden fase integrerede eksogene variabler i simuleringen, hvilket yderligere forbedrede middelkvadratfejlen med 55% og Dynamic Time Warping med 34% sammenlignet med basis-modellen.Med simulatoren p plads blev Soft Actor-Critic (SAC)-algoritmen anvendt til at optimere strategier for fosforfjernelse.Tre scenarier, der tog hjde