Before I go deep into this topic, I need to give a nod to C. S. Lewis for his book, Miracles, in which he deals with this problem from a fairly comprehensive perspective. I also give a nod to John C. Polkinghorne, who presents a somewhat different perspective from Lewis' supernatural intervention idea in his books, particularly in Belief in God in an Age of Science. (See, especially, Chapter 3, "Does God Act in the Physical World?")
Between the two authors, Polkinghorne seems to be more of a scientific skeptic. Yet, he has a point. If God designed the laws of physics, why would he disobey them? This represents a fundamental existential challenge to the claim that miracles happen, and it needs to be addressed in a serious manner.
So, the fundamental issue concerning miracles is the fact of physical determinism. As it happens, this is precisely the fundamental problem for the existence of free will, also called free moral agency to emphasize the connection with moral responsibility or culpability. If, as many scientists suggest, free will is an illusion, then no one is morally responsible. All are mere deterministic automata.
Yet even the determinists will admit that the picture of physical determinism is complicated by quantum physics, which introduces uncertainty and randomness to the picture. Fortunately for the sake of mathematical physics, the uncertainty, first observed by Werner Heisenberg and formulated in a limited way as the Heisenberg uncertainty principle, can be expressed using mathematical probability distributions. Thus, the uncertainty principle is a corollary of the even more fundamental randomness of elementary particles, which physics now models as probability distributions at the quantum level. This fundamental reality was offensive to Albert Einstein's sense of divine propriety, and he famously declared, "God does not play dice!"
Yet, ironically, it is probably this very randomness built into the fabric of reality that is God's entrée into it.
To see the significance of this, it may help to review the physics of Brownian motion. Fine dust particles in the air, so fine that they are normally not seen, can be seen when sunlight shines through a window in a dark room. These particles are seen to dance about at random. This dancing of the particles is referred to as Brownian motion. It is caused by the movement of air molecules colliding with the dust. The air molecules move at random in a manner that might be likened to a three dimensional pool table when the balls collide with each other. The motions of these molecules are the product of motions of the constituent atoms. Molecules can be thought of as balls connected by coils of wire. These molecules change their shape according to the momentum of the atoms and the attractive molecular forces between them. Occasionally, a collision between molecules is so violent that the molecule breaks up. We actually see this in the process known as electrolysis. All of these tiny motions can be analyzed as the composite motions of the underlying elementary particles (protons, neutrons and electrons) of which they are constituted. It is these elementary particles that are modeled as probability distributions in quantum physics.
If instead of being randomly governed, God decided to intervene and control the position and momentum of each elementary particle, he would be violating the randomness, but not the underlying physical laws. Thus, nothing would need to be done to alter the four fundamental forces of nature and the interaction between these forces and the matter and energy of the universe in order for God to effectively intervene.
As a possible application in the case of Brownian motion, God could control the motion of the invisible molecules in order to cause the fine dust particles to move in concert, rather than at random.
Any miracle whatever, including the Resurrection, could be described, in principle, according to this model of divine intervention.
Something like the Resurrection is most simply described as the processes of damage and decay moving backwards in time. This backwards movement of time is known in physics to be a probabilistic impossibility. The preponderance of decay in order over spontaneous organization in a closed system is known as the Second Law of Thermodynamics, or the Law of Entropy. Thus, the only thing holding reorganization at bay is the randomness of physics (plus a few irregularities known to particle physicists as, for example, an imbalance in the spin properties of matter vs. antimatter - see the section on Electric Dipole Moment in the article on T-Symmetry.) which, if God chose to intervene, could be overcome.
Obviously, such an intervention would require inconceivable knowledge, observational ability and fine control on God's part. But then any reasonable concept of God would allow for this.
Polkinghorne, in his skepticism, is inclined to favor a more limited type of God concept, the sort of concept that was introduced by Alfred North Whitehead in a formulation known as process theology.
Incidentally, the intervention of God in miracles that we have described can, in theory, also serve to explain how the human soul might influence human physical thought and motion, i.e., free moral agency.
This view of God's (and humanity's) intervention in the physical world has enormous existential implications. To approach this topic, let's recall what St. Paul said in Romans, Chapter 8 (verses 19-21),
For the creation waits with eager longing for the revealing of the sons of God; for the creation was subjected to futility, not of its own will but by the will of him who subjected it in hope; because the creation itself will be set free from its bondage to decay and obtain the glorious liberty of the children of God.
Thus, even St. Paul, who didn't have the benefit of a 20th century education in mathematical physics, could see the importance of this fundamental existential predicament of humanity, and the even deeper implications of God's intervention in it.
Indeed, it is this very existential dilemma that Jesus refers to when he says [Matthew 26:11], "For you always have the poor with you, but you will not always have me." That is to say, the inevitable existence of poverty is a corollary of the Second Law of Thermodynamics. Even in principle, it is impossible for any conceivable form of governance to prevent poverty.
That won't stop Satan from spreading the lie that poverty can be overcome, and it won't stop the naive from swallowing it hook line and sinker. These are the three shortcuts to overcoming the human existential dilemma that Satan proposed to Jesus in the temptations in the desert.
I claim that a deep understanding of the fall from the Garden of Eden leads us to the conclusion that our existential dilemma is a natural consequence of the choice of Adam and Eve to know, in an experiential sense, good and evil.
It is also the existence of random decay in the universe that explains all human suffering and most human evil. It dictates that human beings do not reliably learn from experience. It ensures that wisdom is a rarity. It accounts for why even a brilliantly designed republic like the United States of America can have such a short lived history in a stable form.
Only God can alter this picture. Only God can overcome the human existential dilemma. The question is, of course, what God's motivation and God's plans are in all of this.
Consider what it will take for human beings to overcome the Second Law of Thermodynamics. As we have seen above, God's intervention in the form of miracles requires an inconceivable knowledge and fine control. Thus it is only through union with God that humanity can overcome Entropy. That unity conveys inconceivable power, but it can only be purchased at a price of purification. Human beings must become pure of heart in order to see God. I claim it is this understanding of the human existential dilemma that gives such force to the brilliance of Jesus' teaching in the Beatitudes.
Seeing the crowds, he went up on the mountain, and when he sat down his disciples came to him.
And he opened his mouth and taught them, saying:
"Blessed are the poor in spirit, for theirs is the kingdom of heaven."
"Blessed are those who mourn, for they shall be comforted."
"Blessed are the meek, for they shall inherit the earth."
"Blessed are those who hunger and thirst for righteousness, for they shall be satisfied."
"Blessed are the merciful, for they shall obtain mercy."
"Blessed are the pure in heart, for they shall see God."
"Blessed are the peacemakers, for they shall be called sons of God."
"Blessed are those who are persecuted for righteousness' sake, for theirs is the kingdom of heaven."
"Blessed are you when men revile you and persecute you and utter all kinds of evil against you falsely on my account. Rejoice and be glad, for your reward is great in heaven, for so men persecuted the prophets who were before you."
In essence, Jesus proclaims that in order for humanity to overcome its physical limitations, each of us must first overcome, with God's grace, our spiritual limitations. Spiritual rebirth must precede physical rebirth. It is our spiritual rebirth that leads to union with God. It is only this union that can both enable and justify the exercise of such power.
The reason it quite simple. The power to construct implies the power to destroy, but not vice versa. Thus, the power to construct cannot be entrusted to any other than the pure in heart who are also wise.
To put it another way, the small miracles of human free will must be purified to unite with the large miracles of divine intervention.