The code runs without results

You are missing semi-colons at the end of multiple lines. You are using some variables (such as p_f and p_h) in equations which you haven’t declared as variables.