My real system (buck converter) can only take an input of 0 to 1 (duty ratio) and I need to constrain the system so the controller action keeps within this bounds. How can I do this?
The code for the project is below in three images, it is Steve bruntons genetic algorithm coding. https://youtu.be/S5C_z1nVaSg?t=470
I assume the u variable is the duty ratio but I am not sure.
The last image is the control system attempted to be controlled. The transfer function is an adequate fit for the system.
Thanks in advance, if anymore information is desired please ask away.