필터 지우기
필터 지우기

I want to write a small program...

조회 수: 3 (최근 30일)
Maruti Patil
Maruti Patil 2015년 8월 28일
답변: Walter Roberson 2015년 8월 28일
Please help me to write program for following algorithm
The algorithm for a program is as follows
Inputs
a=0; b=5; n=10
f(x)=x^2+54/x
Step 1
x1=a; dx=(b-a)/n; x2=x1+dx; x3=x2+dx;
Step 2
if f(x1)>=f(x2)<=f(x3)
answer is(x1,x3)
else x1=x2; x2=x3, x3=x2+dx;
and go to step 3
Step 3
check if x3<=b
if yes go to step 2
else there is no answer

채택된 답변

Walter Roberson
Walter Roberson 2015년 8월 28일

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Operating on Diagonal Matrices에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by