Problem related to fminbnd

3 views (last 30 days)
Prajakta Ghatage
Prajakta Ghatage on 23 Feb 2020
Commented: Matt J on 23 Feb 2020
I am finding the minimum value of Lr in the non-linear function. but whatever value of constants I change there is no effect on the minimum value. Also the minimum value I am getting is not correct.
fun=@(Lr)(((Vin*Cr*Lm)/(((((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)+((ilm*ilm*Lm*Cc)/(((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)))*(((1-D)*Ts)-((ilm*Lm)/(((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)))))+((Lr*(((((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)+((ilm*ilm*Lm*Cc)/(((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)))*(((1-D)*Ts)-((ilm*Lm)/(((Z*Cc)+((A+(B*Cr))*((B*Cr)+C)*Lr))/Cc)))))/(Lm*Vin))+((C*Lr)/Vin));
[Lr,fval] = fmincon(fun,0,10e-6)
where all other variables are constants and their resp. values are given

Accepted Answer

Matt J
Matt J on 23 Feb 2020
Edited: Matt J on 23 Feb 2020
You could plot the function to see how its shape varies with the parameters and to confirm whether fminbnd is giving the correct result.
  12 Comments
Prajakta Ghatage
Prajakta Ghatage on 23 Feb 2020
Thank you so much.
Matt J
Matt J on 23 Feb 2020
You are quite welcome, but please Accept-click the answer to indicate that your question was addressed.

Sign in to comment.

More Answers (0)

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!