(a) Construct a signal plus noise random sequence using 10 samples of

Where N[n] is generated using randn in MATLAB and
Design a discrete-time matched filter for the cosine signal. Filter the signal plus noise sequence with the matched filter. At what sample value does the filter output peak. (b) Construct a signal plus noise random sequence using 10 samples of the following 
Where
is generated using randn in MATLAB
Design a discrete-time matched filter for the cosine signal. Filter the signal plus noise sequence with the matched filter. At what sample value does the filter output peak.