This Sunday well meaning pastors and congregants across North America will make unintended blunders into heresy by praying things like this: "Heavenly Father, we thank you for dying for us"; "Lord Jesus, we thank you for being such a loving Father." Prayers like this, while no doubt prayed with good intention, evince a deep confusion about the God to which we are praying. Our God is a Trinity, and this immediately makes it more complex and perilous to pray to the triune God than any other God in the major monotheisms (i.e. those conceptions in Judaism and Islam).
According to Christianity, God is one, but he exists as three distinct and equally divine persons: Father, Son, and Spirit. Because these persons are distinct, you cannot conflate their identities. If you are praying to the Father, then you cannot thank him for dying for us. But you can thank his Son for dying for us. Or you can thank him for sending his Son to die for us. And you cannot thank Jesus for being a loving Father. But you can thank the Father for being a loving Father. Or you can thank Jesus for having a loving Father.
In short, when you address the Christian God you must always be clear which aspect of that God you are addressing. Are you addressing all three persons or just one? And if one then which one? These questions are fundamental to the orthodoxy, and even the meaning of the prayer.
In addition, note that it is permissible to switch your referent within a prayer. You might begin by praying to the Father, but then switch to praying to the Son. But if you do, make it clear that you have switched referents. Don't pray, "Heavenly Father, we thank you for your mercy. We thank you for dying for us." Make it clear to the congregation (and to God) that the second sentence is directed to the Son.
Finally a question: is it appropriate to pray to the Trinity, or the Son, or the Spirit? After all, Jesus taught us to pray to the Father. Are we then obliged to pray only to the Father?
This is an excellent question. And the short answer is that we have four precedents of Christians praying to Jesus in the New Testament, including Stephen in his last moments being stoned, and Paul pleading for a thorn to be relieved. Such examples provide a precedent to pray to the Son as well. And surely if we can pray to the Son then it is appropriate to pray to the Spirit as well, for he is no less divine. And if we can pray to the Spirit, then surely we can address the entire Trinity as well.
But let it be noted that the normative pattern for prayer in the New Testament is indeed directed to the Father. And whenever and however you pray, always be clear to whom it is you are praying.