i have an sliding mode cotroller for robot arm. it workes fine with ramp and sine wave input but cause more rms error when i give step input for theta. what could be the reason?
Since you didn't provide sufficient info about your model and the controller, the natural explanation for this is that the sliding mode control system requires persistent excitation through the system input.
I don't see any 'error' problem with the results. Those are transient nature of the output responses. Try plotting both the step error response and the ramp error response under the same scale, and you should be able to learn something.
As mentioned previously, there seemed to be no problem with your results. Please specify the exact parts of your project which you had difficulty in. If you want to compute the error as suggested, then here is the algorithm: