Hello everybody ! I'm trying to solve an optimization problem about space trajectory optimization. I have a problem concerning "x" output value of the function ga. I have 4 variables and I must minimize a defined function. The code is correct but I observed a strange thing. If I print variables value inside the code, generation after generation, and then I compare them with optimal solution after the convergence they not are the same.
The first variable is different while three other ones are coincident. Why? How can I resolve this problem? Thank you so much.

답변 (1개)

Star Strider
Star Strider 2018년 10월 2일

0 개 추천

Although not mentioned in the documentation, there have been discussions here about the method the ga function uses to determine the ‘fittest’ individual. That is not always the fittest individual in the final generation, since the ga algorithm retains the fittest individual and uses it for the optimal result.
I invite MathWorks staff (who know those details) to add their comments.

카테고리

제품

릴리스

R2018a

질문:

2018년 10월 2일

답변:

2018년 10월 2일

Community Treasure Hunt

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

Start Hunting!

Translated by