Temporal Compression Algorithm(there are some details missing and more
work needs to be done on it)