Last week I upgraded from 14.04 to 16.04 with Gnome on my Asus zenbook UX301L and now it freezes randomly while programs like gedit and firefox are running and the laptop is hooked up to an external screen and mouse and keyboard while the lid is closed. Opening the lid doesn't bring the laptop screen to live and there's no reaction to keyboard, mouse or touchpad. I think it might have something to do with switchting between programs using Alt+Tab or suddenly using the mouse, but I'm not sure.
I've tried updated the kernel to 4.4.8 as suggested here Laptop freezes after connecting external monitor, since 16.04 update
I've also tried editing the grub file as suggested here: Freezing of screen on Ubuntu 16.04
But still the freezes remain. Does anyone have a suggestion of what might cause the problem?