Local minimum and global minimum of a function

조회 수: 12 (최근 30일)
Anjali
Anjali 2015년 5월 13일
댓글: Walter Roberson 2015년 5월 13일
Hi!
I need to obtain the first local minimum as well as the global minimum of this function for t>0.
CV_inf = @(T) T.*(4/(n+1)) - (1/2*pi)*integral(psitildasq,(-T),(T),'Arrayvalued',true);
where
psitildasq = @(t) (1/n^2)*sum((cos(x.*t))).^2 + (1/n^2)*sum((sin(x.*t))).^2;
n is the size of vector x.
Beacause fmnbnd and fminsearch may give local minimum of a function, are there other functions that I can use? If so is there an option I could specify to obtain the first local minimum?
Thanks.
  댓글 수: 1
Walter Roberson
Walter Roberson 2015년 5월 13일
Consider moving the n out of psitildasq to speed the integration up. It is acting as a constant multiplier of 1/n^2 on the integral.
Question: do you intend 1/2*pi to be pi/2 or to be 1/(2*pi) ?

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

채택된 답변

Walter Roberson
Walter Roberson 2015년 5월 13일
patternsearch() from the Global Optimization Toolbox might be appropriate for the global minimum.

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by