Examples:
All unknown prob. are arbitrary 5%, except extra move which is 0%
Ignoring A for simplicity for now (because of the recursion that needs fixing up)
Cruiser 2982/12500, repairs needed: 38
pickups attempted = 38 * 1.1 = 41.8
1/42 = 0.024
HMR is twice as fast
Cruiser 8382/12500, repairs needed: 16.5
pickups attempted = 16.5 * 1.1 = 18.15
1/18 = 0.056
Self-repairs are slightly faster than HMR
Immediate conclusion drawn from two examples:
HMR is faster on average with these probabilities if number of self-repairs needed are greater than 19, all other factors are irrelevant, further examples not needed.
However final caveat, this is probability and I know that it isn't this straight forward as my formula. Here we go XD
Probability of no HMR = 0.95
but the probability of no HMR for 14 moves (which is actually 0.95^14) has already dropped to 49%. Therefore the full 19 moves shouldn't be necessary after all, on average. 14 moves is enough with a 5% probability to get over 50/50 chances.
True conclusion:
with a 5% probability of HMR, HMR is faster on average than 13 (because 13*1.1>14) self-repairs, or 3 full turns of self-repair (1950 HP Normal or 3250 HP Capital ships), assuming that it's a full repair, if not then adjustment is required. 11-12 moves for an auto-repair bomber as they'll heal around an extra 225 HP faster.
Now going to look back at the examples in this light, it changes the 2nd result:
When talking about fleet repairs, repair ships can reduce the number of actual moves/turns available for searching for pickups to repair to full health, making HMR somewhat less efficient.
Cruiser 2982/12500, repairs needed: 38
pickups attempted = 38 * 1.1 = 41.8
At least 1 HMR = (1 - 0.95^42) = 88%
12% probability that self-repairs would be faster
Cruiser 8382/12500, repairs needed: 16.5
pickups attempted = 16.5 * 1.1 = 18.15
At least 1 HMR = (1 - 0.95^18) = 60%
40% probability that self-repairs would be faster
The above based on 5% probabilities for HMR, free attack, triple attack (invulnerability and hp+/- ignored)
Finally, if using calculation by 13(14) instead of 19(20) seems highly counter-intuitive, that's because it is.
The general formula for rolling at least one 6 in n rolls is 1 - (5/6)^n.
So the probability of rolling at least one 6 in 6 rolls is actually around 2/3 or 66.6%..
This is why I have problems with probability sometimes XD, you wouldn't think that rolling a 6 on a die 6 times would be a winning bet, and you would still expect one 6 on average for every 6 rolls made in a large numbers scenario.
However I believe what this is saying is, it's more likely to roll at least one 6 in 6 rolls, then it is not to. It is not the same as the expected number of sixes.
Therefore the likelihood to get a HMR in 14 moves at 5% is more likely than it is not to, but the expected number of HMR at 20 moves is 1. Use whichever you feel is more correct.
Can someone can explain the difference better? If I was rolling for a 6 on 6 rolls and it was for money, the gut instinct might be that it's a 50/50 bet, even incl. that I might roll 6 multiple times. I guess that is why it's not a 50/50 bet, and it's actually in favour of the person rolling for sixes, because of the probability for rolling at least one six is greater than the probability for rolling exactly one. Still seems a little counter-intuitive, but not as much when I think of it that way.
I found a google answer that gives the same result, that betting on rolling a 6 in just 4 rolls is a winning proposition for the person rolling for 6. But it doesn't really explain why. It just uses the same calculations for probability.
http://answers.yahoo.com/question/index ... 803AAMxVFs
Final formulae:
recap:
A = actual net HP change from PU
U = expected gross amount of HP up
D = expected gross amount of HP down :::: made this a positive number, if making it negative the formula is A=U+(D*(1-I))
I = Chance of Invul PU prior same turn :::: replace this if someone knows the correct probabilities
M = move difference up/down because of A
G = Chance of Hypergate
A = U-(D*(1-I))
M = ceil A/150 (normal ships)
M = ceil A/250 (capital ships)
If hitpoints < 50%:
Q = number of self-repairs to equal a half-max
Z = Q + FQ + RQ + GQ + 2QX + M (if extra move pickup exists else) Z = Q + FQ + RQ +GQ + M
P = 1 - (1-H)^Z
If P > 0.5 (pickups are faster than self-repairs)
If P > "breakpoint" (e.g. breakpoint of 0.75 or 75% for fleetwide repairs, etc, pickups are faster than self-repairs)
If hitpoints > 50% (or at least if HP >50% after A is applied):
N = number of self-repairs needed to repair to full or just below
Z = N + FN + RN + GN + 2NX (if extra move pickup exists else) Z = N + FN + RN + GN
P = 1 - (1-H)^Z
If P > 0.5 (pickups are faster than self-repairs)
If P > "breakpoint" (e.g. breakpoint of 0.75 or 75% chance for fleetwide repairs, etc, pickups are faster than self-repairs)
Should be correct, other than I don't have the correct formula for M as it's most likely recursive (U/D are a factor of M and vice versa), but M only plays a minor part anyway.
Z is somewhat recursive too (N and Q are constant, but Z is a truer value to use in Z = N + RZ + GZ + 2ZX for example.)
One final caveat, doing PUs with hp <=450 hp can result in immediate termination.