Added partial differentiate functions