Engineering/Matlab
Matlab 내장합수: ceil
spiraea
2016. 5. 24. 13:26
우선 matlab에서 help ceil 을 통해 ceil이 어던 함수인지 살펴보았습니다.
>> help ceil ceil Round towards plus infinity. ceil(X) rounds the elements of X to the nearest integers towards infinity. |
간단히 말하자면, 올림을 해주는 함수입니다.
ceil(5.3) = 6
ceil(2.9) = 6
ceil(-5.2) = -5
ceil(-0.7) = 0
간혹 유용하게 쓰일 일이 있을 것 같네요.