typos in the assignment as it seems? :\
Basically doing the same for z as was done for x and y before… don't know if correct - we'll see :D
if my interpretation of the assignment is correct, time (num frames) has a different filter window size (rt instead of r)