필터 지우기
필터 지우기

why fmincon returns different results every time

조회 수: 3 (최근 30일)
xueqi
xueqi 2012년 9월 10일
Hi fellows,
I am using fmincon to do the optimization problem. But every time I run it it gives me different result. Is there anyone who know what the reason could be?
Cheers

채택된 답변

Sean de Wolski
Sean de Wolski 2012년 9월 10일
  • Do you have a rand() in there that makes your function non-deterministic?
  • Is your function non-deterministic in some other way?
  • Are you using the same starting point, x0?
  • Are you modifying the options at all?
The more details you can provide us with the better.
  댓글 수: 1
SHWETA GUPTA
SHWETA GUPTA 2013년 2월 28일
I don't have rand() in my code, starting point is same every time I run the code but still it gives me different result. Please help.

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

추가 답변 (1개)

xueqi
xueqi 2012년 9월 11일
Yeah I did have a rand()...This explains!

카테고리

Help CenterFile Exchange에서 Solver Outputs and Iterative Display에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by