Robustness-Aware Genetic Algorithm for Batch Crystallization with an LSTM Digital Twin
Source abstract
Abstract
Batch crystallization processes are prone to batch-to-batch inconsistencies arising from operational uncertainties and equipment-induced noise. This study presents a Robustness-Aware Genetic Algorithm (RAGA) integrated with a Long Short-Term Memory (LSTM) digital twin for the design of robust crystallization procedures. The RAGA employs a hierarchical fitness function that strictly enforces a target median crystal size D50 as the primary constraint while maximizing process yield as a secondary objective. Robustness is incorporated directly into the optimization by requiring candidate trajectories to satisfy the D50 specification across five independent stochastic realizations with perturbed operating conditions. A candidate is promoted in the evolutionary search only if all five evaluations produce a predicted D50 within ±2 µm of the target. The framework was applied to seeded cooling crystallization of creatine monohydrate across three target crystal sizes of 115, 125, and 135 µm. Robustness of optimal crystallization procedures was independently verified through 100-run Monte Carlo simulations under ±10% parameter perturbations with success defined as D50 within ±5 µm of target. Experimental validation at laboratory scale confirmed that optimized procedures translate to practice, with two of three target sizes achieved within the ±5 µm specification and the third deviating due to the combined effect of LSTM prediction uncertainty and thermal lag. Despite having no embedded mechanistic knowledge, the optimizer successfully converged on physically coherent crystallization strategies. Its variations in seed loading, batch time, and cooling trajectory parameters remained entirely consistent with established principles of supersaturation management. The results demonstrate that embedding robustness directly within the evolutionary optimization loop enables consistent crystal size control using data-driven models.
Source: crossref · Quality: baseline
Research context
OpenAlex topics: Crystallization and Solubility Studies · Process Optimization and Integration · Enzyme Structure and Function
SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.
Affiliations
Krka, 8501 Novo Mesto, Slovenia
Faculty of Chemical Engineering and Technology, University of Zagreb, 10000 Zagreb, Croatia
Funding
the European Union—NextGenerationEU through the Recovery and Resilience Facility
References (43)
Show source-provided references
1. Artificial Neural Network Models for Solution Concentration Measurement during Cooling Crystallization of Ceritinib10.31803/tg-20230626220812 ↗
2. Zokić, I., and Kardum, J.P. (2023). Crystallization Behavior of Ceritinib: Characterization and Optimization Strategies. ChemEngineering, 7.10.3390/chemengineering7050084 ↗
3. Zokić, I., Kardum, J.P., Crnac, L., Sabol, M., Vuić, J., and Travančić, V. (2024). Modification of Ceritinib Crystal Morphology via Spherical Crystallization. Crystals, 14.10.3390/cryst14110975 ↗
4. Evaluation of controlled cooling for seeded batch crystallization incorporating dissolution10.1016/j.ces.2012.01.057 ↗
5. In situ measurement of solution concentration during the batch cooling crystallization of L-glutamic acid using ATR-FTIR spectroscopy coupled with chemometrics10.1021/cg7010265 ↗
6. Pharmaceutical crystallization10.1021/cg101556s ↗
7. Advances and new directions in crystallization control10.1146/annurev-chembioeng-062011-081043 ↗
8. Temperature setpoint-ramp control structure for batch reactors10.1016/j.ces.2019.07.042 ↗
9. Process development in the QbD paradigm: Implementing design of experiments (DoE) in anti-solvent crystallization for production of pharmaceuticals10.1016/j.jcrysgro.2021.126263 ↗
10. Quality by design (QbD)-based crystallization process development for the polymorphic drug tolbutamide10.1021/cg2003029 ↗
11. Application of Model-Free and Model-Based Quality-by-Control (QbC) for the Efficient Design of Pharmaceutical Crystallization Processes10.1021/acs.cgd.0c00295 ↗
12. Data-driven, using design of dynamic experiments, versus model-driven optimization of batch crystallization processes10.1016/j.jprocont.2012.08.011 ↗
13. Designing the design of experiments (DOE)—An investigation on the influence of different factorial designs on the characterization of complex systems10.1016/j.enbuild.2021.111298 ↗
14. Nanev, C.N. (2025). Theoretical Analysis of the Factors Determining the Crystal Size Distribution (CSD) During Crystallization in Solution: Rates of Crystal Growth. Crystals, 15.10.3390/cryst15070653 ↗
15. Population Balance Model Development Verification and Validation of Cooling Crystallization of Carbamazepine10.1021/acs.cgd.0c00434 ↗
16. Crystal Population Balance Formulation and Solution Methods: A Review10.1021/acs.cgd.7b00645 ↗
17. Comparison of discretization methods to solve a population balance model of activated sludge flocculation including aggregation and breakage10.1080/13873950600723376 ↗
18. Optimization of key energy and performance metrics for drug product manufacturing10.1016/j.ijpharm.2022.122487 ↗
19. Dong, Y., Xuanyuan, S., Xie, C., Sun, Y., Zhou, X., and Wang, Y. (2025). Neural Network-Based Kinetic Model for Antisolvent Crystallization of Benzophenone: Construction, Validation, and Mechanistic Interpretation. Crystals, 15.10.3390/cryst15050464 ↗
20. A method for the rapid creation of AI driven crystallization process controllers10.1016/j.compchemeng.2024.108680 ↗
21. A Recurrent Neural Networks-Based Approach for Modeling and Control of a Crystallization Process10.1016/B978-0-323-95879-0.50238-1 ↗
22. Vrban, I., Bolf, N., and Sacher, J.B. (2025). Data-Driven Prediction of Crystal Size Metrics Using LSTM Networks and In Situ Microscopy in Seeded Cooling Crystallization. Processes, 13.10.3390/pr13061860 ↗
23. Staudemeyer, R.C., and Morris, E.R. (2019). Understanding LSTM—A tutorial into Long Short-Term Memory Recurrent Neural Networks. arXiv.
24. Machine learning meets process control: Unveiling the potential of LSTMc10.1002/aic.18356 ↗
25. Model-based optimization of particle size distribution in batch-cooling crystallization of paracetamol10.1021/cg034179b ↗
26. First-principles and direct design approaches for the control of pharmaceutical crystallization10.1016/j.jprocont.2004.08.003 ↗
27. Real-Time Optimization and Genetic Algorithm for Enhanced Process Control of Coupling Cooling and Antisolvent Crystallization10.1021/acs.iecr.4c04048 ↗
28. Liu, M., Yan, P., Liu, P., Qiao, J., and Yang, Z. (2022). An Improved Particle-Swarm-Optimization Algorithm for a Prediction Model of Steel Slab Temperature. Appl. Sci., 12.10.3390/app122211550 ↗
29. Multi-objective optimization of seeded batch crystallization processes10.1016/j.ces.2006.03.055 ↗
30. Optimization of Batch Cooling Crystallization of Sodium Phosphite Through Genetic Algorithm10.1002/ceat.202200220 ↗
31. Model Predictive Control of an Integrated Continuous Pharmaceutical Manufacturing Pilot Plant10.1021/acs.oprd.7b00058 ↗
32. A robust deep reinforcement learning approach for the control of crystallization processes10.1016/j.compchemeng.2025.109114 ↗
33. Uncertainty analysis of seed recipe for optimal control of crystal size distribution in batch cooling crystallization10.1016/j.cherd.2024.03.012 ↗
34. Miettinen, K. (1998). Nonlinear Multiobjective Optimization, Springer.10.1007/978-1-4615-5563-6 ↗
35. Solution thermodynamics of creatine monohydrate in binary (water + ethanol) solvent systems at T= (278.15 to 328.15) K10.1016/j.jct.2015.09.011 ↗
36. Analysis of the efficacy, safety, and regulatory status of novel forms of creatine10.1007/s00726-011-0874-6 ↗
37. Mentges, J., Bischoff, D., Walla, B., and Weuster-Botz, D. (2024). In Situ Microscopy with Real-Time Image Analysis Enables Online Monitoring of Technical Protein Crystallization Kinetics in Stirred Crystallizers. Crystals, 14.10.3390/cryst14121009 ↗
38. Sacher, J.B., Bolf, N., and Sejdić, M. (2024). Batch Cooling Crystallization of a Model System Using Direct Nucleation Control and High-Performance In Situ Microscopy. Crystals, 14.10.3390/cryst14121079 ↗
39. Paszke, A., Gross, S., Massa, F., Lerer, A., Bradbury, J., Chanan, G., Killeen, T., Lin, Z., Gimelshein, N., and Antiga, L. (2019). PyTorch: An Imperative Style, High-Performance Deep Learning Library. arXiv.
40. Gad, A.F. (2021). PyGAD: An Intuitive Genetic Algorithm Python Library. arXiv.
41. Array programming with NumPy10.1038/s41586-020-2649-2 ↗
42. McKinney, W. (July, January 28). Data Structures for Statistical Computing in Python. Proceedings of the 9th Python in Science Conference (SciPy 2010), Austin, TX, USA.10.25080/Majora-92bf1922-00a ↗
43. Assessment of Overall Heat Transfer Coefficient Models to Predict the Performance of Laboratory-Scale Jacketed Batch Reactors10.1021/acs.oprd.5b00378 ↗