Boy, there is alot of stuff you could be doing, but I'm not quite sure what your training plan is and the type of environment your riding (flats, rolling terrain, etc). Are you doing any extended interval work above your anaerobic threshold? Are you using a power meter and training by wattage? If you want to go faster you need to build into your workout some periods of work where you are going harder than normal, recovering at a slower than normal pace, then going harder than normal, lather rinse repeat. Slowly build that up over time. You can base your effort on your perceived exertion, but if you have a power meter to measure your wattage and record it, and preferably a heart rate monitor too to measure your recovery between intervals, your better off because you can see your improvements over time. There are plenty of sites with suggested interval programs that you can google. Just don't overdo it, less is more. One or two interval sessions a week with enough post ride recovery is plenty.
Also 30km is approx 18mph and 40km is approx 24mph, that's a big jump in speed at least over an extended distance. One of the metrics for a cyclist who wants to imorove his time trialing is being able to do a flat 40km time trial under an hour.