Given that $H(x)$ is a Heaviside function, how would I graph $H(x)+2H(x-3)-3H(x-5)$

1.1k Views Asked by At

Question

Given that $H(x)$ is a Heaviside function, how would I graph $H(x)+2H(x-3)-3H(x-5)$?

I was thinking about shifting the function, but then realized that there are multiple $H$'s

Or do I need to plot points?

2

There are 2 best solutions below

0
On BEST ANSWER

@JeanMarie provided an excellent comment on how to do it. Also, @JohnJoy provided a very useful interpretation that is worth exploring.

You would just break up the Heaviside function into three distinct pieces and add the results of them over their respective ranges.

The plot should end up being

enter image description here

Here is the same plot using a different tool

enter image description here

2
On

It helps to write the function like this:

$$f(x)=\begin{align}&\;\;\;\;\;\color{#eb6235}{0}\\&+(\color{#8778b3}{1}-\color{#eb6235}{0})H(x-\color{#e19c24}{0})\\&+(\color{#5d9ec7}{3}-\color{#8778b3}{1})H(x-\color{#e19c24}{3})\\&+(\color{#996633}0-\color{#5d9ec7}{3})H(x-\color{#e19c24}{5})\end{align}$$

where the numbers being subtracted from $x$ in the unit step function represent the breakpoints, and the matching constants correspond to the pieces that make up your piecewise function. As an example, note that $\color{#5d9ec7}{3}$ shows up in the $\color{#5d9ec7}{3}-\color{#8778b3}{1}$ and $\color{#996633}0-\color{#5d9ec7}{3}$ factors corresponding to $H(x-\color{#e19c24}{3})$ and $H(x-\color{#e19c24}{5})$, so your function takes the value $\color{#5d9ec7}{3}$ in the interval $[\color{#e19c24}{3},\color{#e19c24}{5})$.

In this form, you can then actually make a direct conversion:

$$f(x)=\begin{cases}\color{#eb6235}0&\text{if }x<\color{#e19c24}0\\\color{#8778b3}1&\text{if }\color{#e19c24}0\le x<\color{#e19c24}3\\\color{#5d9ec7}3&\text{if }\color{#e19c24}3\le x<\color{#e19c24}5\\\color{#996633}0&\text{if }\color{#e19c24}5\le x\end{cases}$$