Frequently used algoritms