Hybrid Machine Learning Algorithms for Solving Forward and Inverse Problems in Physical Sciences