# [Tutor] More help

Mark Lawrence breamoreboy at yahoo.co.uk
Sat Oct 13 10:04:53 CEST 2012

On 13/10/2012 05:57, Brett Dailey wrote:
> Here's another project I'm working on.
>
> 1. Create a random "signal" (600 random numbers in the range -50 to +50). Display it as shown below.
> 2. Create a filter variable (integer) which is allowed to go from 0 to infinity. Allow the user to change this
> with the up/down arrow keys. The user should have to release the key and press it again to go up /
> down one level.
> 3. Apply a "box filter" to the original signal.
>           If filter is 0, the signal should be the same as the original
>           If filter is 1, you should, for each signal element i (of the new signal), average the i-1, i, and i+1
>           elements of the original signal.
>           If filter is 2, you should, for each signal element i (of the new signal), average the i-2, i-1, i, i+1,
>           and i+2 elements of the original signal iv. ...
>           Note: if the i-? or i+? element is "out of bounds", don't include it. For example, if filter is 1, and you are calculating the 0th                   element of the new signal, you should only average the 0th and 1th element of the original signal.
>
> Thank you ahead of time!
>

I'm reminded of the film Coogan's Bluff.  I have the Lee J Cobb role,
you're Clint Eastwood.

--
Cheers.

Mark Lawrence.