I am not sure what the cause of the problem is. I don’t know of software which could calibrate the phone and which you could download and run yourself. I have found that my phone also just turns itself off when I am using a Bluetooth headset. Perhaps you may also be running certain 3rd party apps which are clashing with something on your phone.
As for programs running slowly, do you run many apps at the same time? You can tell how many are running at a time by holding down the ‘menu’ button. Try closing some of the apps you are not using.
Other than that, visit your local Nokia dealership and see if they can help you out. Sorry I couldn’t be much more help.