comeoncodeon.wordpress.com
Recurrence Relation and Matrix Exponentiation
Recurrence relations appear many times in computer science. Using recurrence relation and dynamic programming we can calculate the nth term in O(n) time. But many times we need to calculate the nth…