I need help for Genetic Algorithm to tune value of the controller parameters and gains

I am using the Robotics Toolbox for matlab with ode15s solver to make a simulation of my controller for a 5DOF manipulator, all thing are work and I have a result, but I want to have a best result by choosing the best values for the controller parameters and gains, for that I'm trying to use the Genetic Algorithm but really I cant understand how to manage them together (ode15s and Genetic Algorithm), so if there is someone who know how to deal with Genetic Algorithm to tune the controller parameters and gains I will be happy to learn from him, where I have many variables need to tune there values.
Notice that the model of the manipulator are generated by using the Robotics Toolbox

 Accepted Answer

Robotics Toolbox seems to be a 3rd party toolbox not shipped/purchased from MathWorks. While the controller is simulated using the ode15 solver, I am assuming that there is a transfer function representation (maybe PIDs for each DOF/motor) whose gains you are trying to tune. Depending on your design specification you are maybe trying to tune the controller for performance wrt to target gain crossover frequency or other tracking requirements. You can do this using GA as long as you define your objective/fitness function to capture your requirements but I will need your code or model to provide recommendations.
As an alternative I would recommend the use of LOOPTUNE if you have Robust Control Toolbox which does this automatically. I would refer you to this webinar which walks you through controller design by tuning several gains for a 4DOF robot arm: http://www.mathworks.com/company/events/webinars/wbnr69934.html
For more flexibility wrt to tuning model parameters I would suggest going through the following product. http://www.mathworks.com/products/sl-design-optimization/index.html
HTH

1 Comment

Thanks for your response.
I'm using the Robotics Toolbox to built the model of the robot and to get all kinematic and dynamics for the robot, this way is more easy than manual calculation, then I use the ode15s to solve the nonlinear differential equations of the robot with my controller.
The links bellow contains my code files and the Robotics Toolbox version which I use. Notice that these codes are without GA.
To run the codes just only run the file AFC_fivelinkmain.m, and all variables which I want to tune them are:
1: k=diag([k1 k2 k3]) is a positive diagonal matrix
2: kp is positive constant
3: r0 is positive constant
4: rv0 is positive constant
Will wait your response and I hope you will help me.
Best regards

Sign in to comment.

More Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!