필터 지우기
필터 지우기

Write a Matlab program by using a while loop that finds the smallest positive number 2^m such that 1+x>1 in the machine.

조회 수: 1 (최근 30일)
m must be a negative integer. Technically from the way that my professor phrased it, shouldn't m be -infinity?
  댓글 수: 2
James Tursa
James Tursa 2018년 8월 14일
편집: James Tursa 2018년 8월 14일
"... shouldn't m be -infinity?"
2^(-infinity) = 0, and 1+0 is not greater than 1. So, no, the way the professor phrased it, -infinity is not the answer.
Do as the professor instructed and write some code with a while loop to figure out the answer.

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

답변 (1개)

Vishal Chaudhary
Vishal Chaudhary 2018년 8월 17일
편집: Vishal Chaudhary 2018년 8월 17일
Precision differs in MATLAB and theoretical calculation. So when you write while loop you will know the difference.

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by