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

Learn moreOpportunities for recent engineering grads.

Apply Today**New to MATLAB?**

Asked by Kyle Taliaferro
on 27 Feb 2013

I have a constant of 350 and a time of 60 second. I need the constant to decrease by 10 every second for 10 second and then stay the same after the ten seconds. So the constant would be 350 at start and then become 250 after the ten seconds and remain at 250 for the remaining 50 seconds. How can i achieve this? This constant should be decreasing at a liner rate.

*No products are associated with this question.*

Answer by Teja Muppirala
on 27 Feb 2013

Accepted answer

Here are two ways to do it:

1. [Ramp] --> [Saturation] -->

2. Use the Signal Builder block (works for more complicated piecewise linear signals)

## 0 Comments