Lost opportunities
The meanings of these are indistinguishable, except for a subtlety that I'll explain later:
We may have been able to save the victims.
We might have been able to save the victims.
The words "would" and "could" suggest both the past tense and the consequence of some imagined hypothesis, with either or both meanings being activated when suitable to the context. To use "would" here, you need to establish an imagined hypothesis. Then "would" indicates the consequence:
If only we had the antidote yesterday! We would have been able to save the victims.
It's possible to say "could have been able to", but "could" is the past tense of "can", so it already indicates ability. So, "could have been able to save the victims" is awkward. However, you could say:
If only we had the antidote yesterday! We could have saved the victims.
"Would have" and "could have" imply that the opportunity is now lost.
"May have", "might have", and "could have" don't require context to set up an imaginary hypothesis, but they do suggest that you have such a hypothesis in mind:
"We might have been able to save the victims."
"How?"
"The most recent antidote has been sitting in the refrigerator since yesterday."
"What? And no one tested it?"
An important difference
A very big difference between the may/might and would/could sentences is that the would/could sentences claim a high level of certainty about the hypothetical situation: the antidote is assumed to work. The may/might sentences lack that certainty. They suggest only that in the hypothetical situation (which might not even be stated yet), the antidote might have worked. "Would" corresponds to "will", and says that the antidote will work (in the imagined situation, which occurred yesterday). "Could" corresponds to "can", and suggests that the antidote can work (in the imagined situation, which occurred yesterday).
A subtle difference
"May have" mainly indicates uncertainty about what we could have done. "Might have" suggests both uncertainty and that the opportunity, if it even existed, is now lost.
This is English, so don't take that as a rule. Instead, memorize this well-known couplet (by John Greenleaf Whittier, 1856):
For of all sad words of tongue or pen,
The saddest are these: "It might have been!"
One more power of might
There's one more possibility with "might", which illustrates the flexibility of these words. "Might" can suggest that the victims actually were saved, or are actually in the process of being saved:
We might have been able to save the victims. I just read an article in a medical journal, which says that the antidote we tried yesterday was proven to work on mice in a recent experiment.
In other words, the antidote we tried yesterday might be working, right now. Since the uncertainty of the word "might" applies to our ability to save the victims, if we had that ability yesterday, then our efforts yesterday were successful, or are on the way to succeeding. Currently, we don't know (that's the uncertainty of "might"). Obviously, your listener will hear this meaning only if the victims are still alive.
You can also do this with "may have" and "could have", but those don't make the pun in the title of this section. Since "may have" has the least connotation of lost opportunity, it provides the clearest way to express optimistic uncertainty about the effects of yesterday's action: "We may have saved the victims."
The "have had" construction is the present perfect form of "to have". As with other verbs, the present perfect describes either an ongoing condition,
He has had that car since he was a teenager.
or a life experience:
In my life I have had many good dinners.
Adding "could" or "would" to this is no different from other uses of could (to describe potential) or would (to describe a hypothetical).
He would have had that car since he was a teenager, if he hadn't driven it into the lake last week.
In my life I could have had many good dinners, if I was a better cook.
It's not a common construction, and it's not important to use it. Usually these kind of sentences can be written using the simple past:
He had that car since he was a teenager
I had many good dinners in my life.
Remember that to use the past perfect of "to have", you have to start with an example that correctly uses that verb. For example:
That building has a good address.
That building has lots of tenants.
That building has ongoing construction.
Then you can change it to the present perfect:
That building has had a good address (but ...)
That building has had lots of tenants (but ...)
That building has had ongoing construction (but ...)
And then add could/would as appropriate.
That building would have had ongoing construction (if it wasn't raining).
Best Answer
These all use the phrasal verb "have to" = "be required to".
Syntactically this behaves just like the verb "have" (the full verb, not the auxiliary), but it has a distinct meaning.
So the structures are just like