You are doing everything wrong! First, rather than type the question, you posted a difficult to read image. Second the image is on its side. Third you show absolutely NO attempt to do this problem your self!
I think the function is
\(\displaystyle f(x)= -\frac{6}{7}x- 6\) if \(\displaystyle -7 \le x\le 0\)
\(\displaystyle f(x)= -\frac{6}{7}x+ 6\) if \(\displaystyle 0< x\le 7\)
\(\displaystyle f(x)= 0\) otherwise.
Now, do you know what a "Heaviside function" IS?
The basic Heaviside function, H(x), is 0 for x less than 0, 1 for x greater than or equal to 1.
We can also use H(x- a) which, since x- a= 0 when x= a, is 0 if x is less than a, 1 if x is greater than or equal to a.
And, of course, f(x)H(x- a) is 0 for all x less than a, and equal to f(x) for all greater than or equal to a.
f(x)+ (g(x)- f(x))H(x-a) is equal to f(x) for all x less than a, and equal to f(x)+ (g(x)- f(x))= g(x) for all x greater than or equal to a.