Fundamentals of numerical reservoir simulation