Concepts4
βοΈAlgorithmAdvanced
Matrix Exponentiation - Advanced
Matrix exponentiation turns repeated linear transitions into fast O(n^{3} log k) computation using exponentiation by squaring.
#matrix exponentiation#adjacency matrix#walk counting+12
βοΈAlgorithmAdvanced
DP with Probability
DP with probability models how chance flows between states over time by repeatedly redistributing mass according to transition probabilities.
#markov chain#probability dp#absorbing state+12
βMathAdvanced
Linear Recurrence
A linear recurrence defines each term as a fixed linear combination of a small, fixed number of previous terms.
#linear recurrence#matrix exponentiation#kitamasa+12
ποΈData StructureAdvanced
Aho-Corasick - DP Applications
AhoβCorasick (AC) turns a set of forbidden patterns into a finite automaton that lets you process or generate strings while tracking whether any pattern appears.
#aho-corasick#automaton dp#forbidden substrings+12