Clear Filters
Clear Filters

Best Fitness function of GA - Maximisation problem

2 views (last 30 days)
I have solved my function for maximixsation using the negative sign of the function since ga solves only for minimisation.
When I chose to find the best fitness value for the same maximisation my ga solver shows the best fitness and mean fitness value in the plot.
Here my best fitness value is smaller than the mean fitness value, which is not acceptable.
So help me to interpret the solution. Thanks.

Answers (1)

Star Strider
Star Strider on 3 Nov 2020
The ga function is minimising the fitness value, as it should. The values it chose for your parameters will maximise your function. That you chose to negate your function in order to select for a parameter set to maximise it does not make any difference to ga. It has no idea what you want to do, nor does it care. (My apologies for the anthropomorphism.)

Products


Release

R2014b

Community Treasure Hunt

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

Start Hunting!