- I would like to point out the fact that the derivative block has its limitation. Please refer to the documentation page here.
- Note from the documentation that, all it does is calculate change in input over change in time. You can do that using a combination of Memory and Clock blocks. Screenshot and code below.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/175369/image.jpeg)