-Download a kernel that is compatible with your current ROM.
-Check the md5 to verify its integrity.
-Enter TWRP recovery.
-Select the install option from the TWRP home screen.
-Navigate to the kernel and select it.
-Swipe to install.
-You'll have an option to wipe cache/dalvik and an option to reboot system. Wipe the cache/dalvik, hit the back button, and hit the reboot system button.
Once your phone has booted up you can use a kernel tuning app to change governors, I/O scheduler, clock speed, and other options. Some of the popular kernel apps are Kernel Auditor, Trickster Mod, No Frills, Kernel Tuner, and many more.