How to reset trackpad after pinch to zoom stops working
Go into the trackpad settings in System Preferences and uncheck every single checkbox in all the tabs (pinch to zoom etc. etc.) , wait 5 seconds and recheck all the box you use. (sometimes I switch apps before rechecking the checkboxes and with more than 5 seconds).

You can also try 

pmset displaysleepnow; sleep 5; caffeinate -u -t 1


Your screen will turn off for 5 seconds and then turn back on.