Genetic Algorithm - Variable Tolerance
조회 수: 4 (최근 30일)
이전 댓글 표시
Hello,
I was wondering if it is possible to define the precision of my optimization variables when using genetic algorithms. At the moment I get results with a lot more decimal places than I actually need.
Thanks.
댓글 수: 0
채택된 답변
Alan Weiss
2013년 7월 25일
You can certainly set the TolFun tolerance to something larger than the default, perhaps 1e-4. But that would not necessarily get you different precision, it just allows the algorithm to stop earlier.
By default, ga uses double-precision floating point numbers. You are free to use any data type you like, but then you have to write your own creation, mutation, and crossover functions. See the genetic algorithm options.
Alan Weiss
MATLAB mathematical toolbox documentation
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Genetic Algorithm에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!