God never intended prayer to change His purpose or move Him to come to fresh ideas. He has ordained that we be saved through the means of preaching the gospel, but prayer is also a means of salvation. We have seen that it is His will that we pray; it fits into the design of His purpose.
Prayer is therefore not a vain exercise but a means by which God exercises His decrees. When we pray for things God has already decreed, things happen! These prayers are not meaningless. Elijah was a man close to God, and he knew God's will, but that certainly did not prevent him from asking God in prayer for rain (I Kings 18:41-46). Therefore, even though we know His will and that He knows our need, He requires we ask for it. Does not Jesus command us to do this regarding end-time events? "Watch . . . and pray always," He says in Luke 21:36. Prayer keeps our minds focused on what is important to God's purpose.
Perhaps we need to change our views about prayer. Frequently, the prevailing idea of many is that we come to God and ask Him for something we want, expecting Him to give it if we have enough faith. But this is actually degrading to God! This popular belief reduces God to a servant—our servant, like a genie in a bottle—performing our pleasures and granting our desires. No, prayer is worshipfully coming to Him, humbly acknowledging His sovereign authority and loving wisdom, telling Him our need, committing our way to Him, and then patiently allowing Him to deal with our request as it seems best to Him. This does not mean we should not confidently present our needs to God as we see them, but then we should leave it with Him to deal with in His time and manner. Remember, He already knows what He wants to accomplish and when.
Doing this works to make our will subject to His. No prayer is pleasing to Him unless the attitude motivating it is "not [m]y will, but Yours, be done" (Luke 22:42). When God grants blessings on praying people, it is not because of their prayers, as if they motivated Him to act, but He acts for His own name's sake and His sovereign will.
He intensely desires that His thoughts become ours because we reflect His image this way. If we think like God, we will act like Him, which is the purpose of conversion. Much of the communication of His thoughts to ours takes place in prayer. God answers every faithful prayer, but not always in the way or when we think best. Often His answer is the opposite of what we feel to be best, but if we have really left it with God, then at least we know it is indeed His answer.
The story of the resurrection of Lazarus in John 11 illustrates this well. Interestingly, Mary and Martha never directly ask Jesus to heal Lazarus, though they clearly suggest it in calling Him to come. God in the flesh, however, responds in a way totally different from what they anticipated. Nonetheless, their approach is still a good example of the proper attitude in presenting a need to God. They do not even go into much detail in expressing their need—just simple trust that He could and would do the right thing.