MATLAB Answers

## how find ramp response

Asked by manoj saini

### manoj saini (view profile)

on 15 Feb 2013

what is method to find out ramp response of a transfer system.......... there is any command like step or impulse?

## 2 Answers

### Teja Muppirala (view profile)

Answer by Teja Muppirala

### Teja Muppirala (view profile)

on 15 Feb 2013

You could get the ramp response by dividing your transfer function by s, and then taking the step response.

For example:

```s = tf('s');
G = 1/(s+1);
```
```figure
subplot(311), impulse(G);   % Impulse reponse
subplot(312), step(G);      % Step Response
subplot(313), step(G / s);  % Ramp response
```

Azzi Abdelmalek

### Azzi Abdelmalek (view profile)

on 15 Feb 2013

% or more general:

```out=impulse(G*U)  % G your transfer function
% U the Laplace transform of your input signal
```

### Azzi Abdelmalek (view profile)

Answer by Azzi Abdelmalek

### Azzi Abdelmalek (view profile)

on 15 Feb 2013
Edited by Azzi Abdelmalek

### Azzi Abdelmalek (view profile)

on 15 Feb 2013

You can use lsim function for any input

```t=0:0.1:10
alpha=2
ramp=alpha*t         % Your input signal
model=tf(1,[1 20 3]);    % Your transfer function
[y,t]=lsim(model,ramp,t)
plot(t,y)
```

#### Join the 15-year community celebration.

Play games and win prizes!

Learn more

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

### Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

### MATLAB Academy

New to MATLAB?

Learn MATLAB today!