필터 지우기
필터 지우기

i have problem with gatool

조회 수: 1 (최근 30일)
mohammed sportman
mohammed sportman 2012년 12월 17일
답변: Matt J 2017년 10월 12일
hi
function g =myfitness2(X)
LAMDA=X(1)+X(2)*2+X(3)*4+X(4)*8+X(5)*16
TYPE=1;
ITER=1000;
R1=Routing3a(TYPE,LAMDA,ITER);
g=-R1
end
........
result of program it
LAMDA 3
g=33.25
LAMDA 17
g=-100
LAMDA 11
g=-100
i want to get g equal to first 100 or less (99.9 or 99 or 98 )
the problem that the value of g up to 100 and the gatool did not stop when the value of g equal (90.. 91.. 92......99) i want to stop the program by using matlab genetic tool (gatool)
please help me help help help
with my regard
  댓글 수: 1
Walter Roberson
Walter Roberson 2012년 12월 17일
The outputs you show have g going to negative 100, not to positive 100.

댓글을 달려면 로그인하십시오.

답변 (1개)

Matt J
Matt J 2017년 10월 12일
Using the OutputFcns option, you can trigger a stop using your own criteria.

카테고리

Help CenterFile Exchange에서 Genetic Algorithm에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by