How do I find the nature of turning points using this function?

조회 수: 4 (최근 30일)
Nico Degabriele
Nico Degabriele 2022년 5월 24일
댓글: Nico Degabriele 2022년 5월 24일
Hi all. I was asked to create a function which uses the turning points of a differentiable function in order to find the first derivative which is not equal to zero after which it finds the nature of the turning points given. The code for the function requires a while loop or a for loop. How can this be done please? Thanks in advance

답변 (1개)

Walter Roberson
Walter Roberson 2022년 5월 24일
values that are exactly the same are derivative 0. Once you find a value not equal to the first value, then any string of increases is a positive derivative, any string of decreases is a negative derivative, places you change between runs are turning point.
Hint: diff and sign
  댓글 수: 1
Nico Degabriele
Nico Degabriele 2022년 5월 24일
Hi, thanks for your answer. I understood what u wrote however I am still unsure about how to start the code. I am just not sure as to how to use each separate turning point for the loop. How is this to be done please?

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

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by