You are being prescribed Methadone for treatment of your pain. Methadone takes a long time for your body to break down. It is taken between 2 and 4 times per day. Methadone is not available in all pharmacies. It is often dispensed as a liquid. Some pharmacies are able to make it into pills and there are now commercially available pills. It is preferable that you take it as a pill, although, if you have trouble swallowing pills a liquid form is also available.
Methadone should be taken on a scheduled basis regardless of how intense your pain is. If you wait until you are in severe pain to take the medication you will not find it to be as effective. When you have chronic pain, it is important to "get ahead" of the pain. If you are to take your pills twice a day you should take each pill 12 hours apart (i.e. 8 am and 8 pm). If you are to take your pills three times a day, you should take each pill 8 hours apart (7 am, 3 pm and 11 pm). For flexibility it is okay to vary these times by 1-2 hours.
You may also be prescribed a breakthrough medication. This is either a smaller dose of methadone, or a different shorter acting narcotic which typically lasts 3-4 hours. This is to be taken only if you have severe pain that is greater than 50% above your normal pain despite your long acting medication. Ideally, you should not take more than 2-3 doses per day, although when you are starting out, it may be necessary to take more. Generally speaking, if you require more than 2 breakthrough doses per day, your dose of methadone needs to be increased.