Fundamentals of Flow Assurance and its Applications