Librarium Online Forums banner

Common MathHammer Mistakes

6K views 26 replies 6 participants last post by  uber 
#1 · (Edited)
These are mistakes which almost everyone makes, and, while often not a big deal in the spur of the moment, when trying to mathhammer something out they can lead to wrong conclusions.

The first problem is that people miscalculate expectation. In a binomial distribution (which is what one normally uses for die rolls) the expectation is n*p, where n is the number of rolls, and p is the probability of success. This is all well and good in theory, but we quickly run into a problem... The problem is that sometimes you factor impossible events into your distribution. If I have 10 marines shoot at a carnifex, in our model they have the possibility of doing 10 wounds, which is impossible, all wounds after the 4th would be truncated, thus you can't actually use a straight up binomial model and you can't really use n*p (though n*p will usually be close).

This leads us into the second problem, which is that people use expectation even though they really shouldn't and are interpreting it incorrectly. It pains me to count the number of times i've heard, "well, i'm expected to do at least 4 wounds to X, so half the time I'll do 4 or more wounds to X." UNTRUE! You are talking about the median not the mean (aka expectation) of the distribution! The median number of wounds is the number (not necessarily unique) such that half the time you will do better, and half the time you will do worse. This solves our first problem because in the truncation example, unless the median of a distribution is in the truncated, it will not be changed by truncation.

The mean minimizes the square sum of the error terms, while the median minimizes the absolute sum, so Expectation is much less robust to outliers (ie if a gun has a 1/1000 chance of doing 5000000 wounds to the target, it's going to totally screw up the mean but do almost nothing to the median)

Now, even with the median people can still misinterpret in a different way! I also hear people say "If I shoot with 10 guys at the Falcon and my expected number of vehicle destroyed results is exactly 1, then the expected number of guys I need to kill the Falcon in one round of shooting is 10." WRONG AGAIN! In order to determine what the expected number of guys needed to kill the Falcon is you need to look at a geometric distribution. You figure out the probability to kill a carnifex with 1 guy, then plug that in for p, and find its expectation (which you probably dont want anyways...) or find the median (which is more useful).

Anywho, all this said, the median is a huge pain in the ass to calculate and usually must be done by simulation, and outliers are usually not that fair out or that heavily weighted (like 100 bolter shots doing 100 wounds to a carnifex) so on the fly expectation is ok, but when people say "I mathematically proved that X is better than Y" they better have their statistics right... (or i'll melee them with my bolt pistol)

enjoy
 
See less See more
#3 ·
Lol. After reading it I realize that you make a very fair criticism.


I'll sum it up here:

Expectation ie. n*p DOES NOT MEAN WHAT YOU THINK IT MEANS!!!

If you are really interested in getting a good 50%-of-the-time estimate, figure out the median of the distribution.

And, if you are interested in "how many units on average do I need to destroy the falcon" look into a geometric distribution.
 
#4 ·
I have an advanced high school understanding of probability and suchforth (I know, that's not a degree, but it's better than the average).....and while I understand the concepts of your.....wall-of-text.....translating it into something useful is just beyond me.

Maybe you should try to make it more "layman" friendly.
I think you probably need to define all the probability jargon so that everyone knows what they actually refer to.
 
#5 ·
Since people are having trouble with this let me give an example of using the median and geometric distributions:

Ok, say we want to apply the above to shooting a ML with a marine at a falcon.

For a single ML we have:

2/3*1/3*1/3 = 2/27 = p = probability a single shot will destroy a falcon

Now we want to figure out the number of shots we need to take in order to have at least a 50% chance of destroying the falcon, so we look at a geometric distribution on wikipedia, it tells us that the median is the smallest integer greater than

-log(2)/log(1-p)

so we plug that in and get 9, thus in order to have a 50% chance of destroying a non-holofield falcon, we need to shoot 9 shots.

If we used expectation instead of the median, we would have gotten the usual answer of 27/2 or 13.5, which may have a useful interpretation (especially if you are considering total number of shots to kill 2 or 3 falcons), but is not the "50% interpretation" that most use it as.
 
#6 ·
I agree with you that binomial distribution would be the best way to calculate how much firepower you actually need. I'd say you're going to have issues applying that in a game by game basis however due to the relatively small number of shots. You're not going have a finite variance unless you start adding up data from a long series of games or one very very large one. In either case, your shifting your parameters away from an individual game which may lead to some bias or skewness in the results.

I think this could work well with bolters, or other weapons that are going to have several hundred shots a game. Heavy weapons, however, maybe at best be shot 10 or 12 times a game, and not always at a falcon/carnifex/whatever. It's going to be difficult to show a match between the theoretical probability you calculate and actual probability experienced on and individual game by game basis. At that point, I think the math hammer most people use is just as good, considering the numbers you'd produce would probably within a standard deviation .
 
#7 ·
Binomial distributions always have finite variance. You don't need to sample anything or estimate any parameters, you can figure out the probabilities of each result by just plugging the probability of a single success into the binomial distribution formula.

Thus, it should work equally well with heavy weapons as it does with bolters.

Though, like I said, a geometric distribution would work much better for tanks (where all you care about is how many shots until something happens, not the expected damage of a single shot).

Also, the numbers that you produce (expectation etc...) are not random, so "standard deviations" don't apply. (though the 2 numbers may still be close)
 
#8 ·
Truncation of impossibly large numbers is neither necessary nor desirable. In just about any case where you're actually bothering to do math-hammer, expected results against a theoretically infinite target are more useful to a decision making process than expected results against an actual target--not to mention far less work.

If you really need info regarding specific numbers of wounds, and work is not an issue, the method suggested by Onlainari produces considerably more useful information than anything you've suggested here.
 
#9 · (Edited)
the point here is that expectation is often not useful, in cases such as shooting at falcons. Also, if one wants to combine probabilites say kill both a falcon and a wraithlord, using a geometric distribution will be way more useful.

"In just about any case where you're actually bothering to do math-hammer, expected results against a theoretically infinite target are more useful to a decision making process than expected results against an actual target"

making a statement without support isn't an argument. Care to explain why?

Also, the point is that expected results often aren't useful. Expectation is useful insomuch as it is used in the law of large numbers, so for tons of bolters wounding hormagaunts, sure. Not so much for killing a falcon with MLs...

My point re: number of wounds was just that expectation isn't really a great thing to look at for a small number of shots, because it really doesn't say much about probabilities which is what one is really looking at. So sure, look at probabilities or a binomial distribution (same thing...), but the strong law of large numbers doesn't actually say anything about the rate of convergence (and in terms of warhammer orders of magnitude it's not fast...) so expectation is really not all that useful.

furthermore, the median is actually fairly trivial to calculate for a geometric distribution.
 
#10 ·
"the point here is that expectation is often not useful, in cases such as shooting at falcons. Also, if one wants to combine probabilites say kill both a falcon and a wraithlord, using a geometric distribution will be way more useful. "

Sure, I never said it was. What I did say is that for this kind of question, you can either use:

1-(1-p)^n (for situations where only one success is necessary, like the Falcon)

-o-

P = p^r * (1-p)^(n-r) * nCr (for situations where more than one success is necessary, like a Carnifex)

where:
P = probability of getting exactly r successes
p = probability of success on a single trial
n = number of trials

and get more detailed information than you would following your suggestion.

For situations in which you need to know how likely you are to get one or a handful of successes (which is what I was talking about when I mentioned specific numbers of wounds) these two formulas are better.

For situations where you just need a rough idea of how many wounds to expect, using the simple expectation calculation (n*p)e right way to go.

It is not correct to include truncation as you suggest because, in fact, your results are never truncated. When shooting at a Carnifex, wounds beyond the fourth don't do you any good--that's certainly true. However, you can get more than four wounds. You can shoot ten bolters at it, get ten hits, ten wounds, and it can fail all ten of its saves--viola: ten wounds.

Truncation is necessary in situations where you would resolve each attack before moving on to the next one--in which you would actually stop rolling after getting the fourth wound, even if you had attacks left. That isn't the case in 40k. You roll them all at once--and in a situation like that it is actually correct to use n*r and actually incorrect to factor in a maximum number of wounds. There is no maximum which it would be appropriate figure in beyond the limit imposed by the amount of shots--and that, obviously, has already been accounted for.

So, actually, your first point is just flat-out wrong and your second point had already been addressed--and better--by Onlainari before you made this thread.

That enough of an argument for you? ;)
 
#11 ·
"1-(1-p)^n (for situations where only one success is necessary, like the Falcon)."

Here you are doing essentially the same thing as using a geometric distribution. Really you are just integrating over the density function. However if you instead want to combine results like shoot a falcon and a wraithlord, then you need the density function... So yes, you can use what I said, and just plug in lots of numbers instead of finding the median...

"For situations where you just need a rough idea of how many wounds to expect, using the simple expectation calculation (n*p)e right way to go"

Why? I would still say the median of a binomial is more useful, and you still haven't given me an argument as to why it isn't.

"It is not correct to include truncation as you suggest because, in fact, your results are never truncated. When shooting at a Carnifex, wounds beyond the fourth don't do you any good--that's certainly true. However, you can get more than four wounds. You can shoot ten bolters at it, get ten hits, ten wounds, and it can fail all ten of its saves--viola: ten wounds.

Truncation is necessary in situations where you would resolve each attack before moving on to the next one--in which you would actually stop rolling after getting the fourth wound, even if you had attacks left. That isn't the case in 40k. You roll them all at once--and in a situation like that it is actually correct to use n*r and actually incorrect to factor in a maximum number of wounds. There is no maximum which it would be appropriate figure in beyond the limit imposed by the amount of shots--and that, obviously, has already been accounted for."

Actually, no. Let me give you a simple example illustrating it. Say I had a gun which 90% of the time fired 1 strength 4 shot, and 10% the time fired 10000 shots that autohit and auto wound. Shooting at a carnifex, expectation would say that we will do

9/10*1/3*1/6*1/3+10000*1/10 ~ 1000.

So we expect to do slightly over 1000 wounds... See that makes no sense in this case. The more legit number is

9/10*1/3*1/6*1/3+4*1/10 ~ 4/10

Granted this isn't a situation which would happen, YET nonetheless illustrates that CLEARLY it entirely makes sense to truncate, and honestly any further argument by you on the subject is just unreasonable.

ps. If your argument is that the above would never happen, it still doesn't invalidate the point that truncation is necessary. The above just makes the math behind it more obvious.

pps. Can we try to keep this discussion civil, I respect the fact that you have thought about this, can you also respect that I have?
 
#12 · (Edited)
Actually, no. Let me give you a simple example illustrating it. Say I had a gun which 90% of the time fired 1 strength 4 shot, and 10% the time fired 10000 shots that autohit and auto wound. Shooting at a carnifex, expectation would say that we will do

9/10*1/3*1/6*1/3+10000*1/10 ~ 1000.

So we expect to do slightly over 1000 wounds... See that makes no sense in this case. The more legit number is

9/10*1/3*1/6*1/3+4*1/10 ~ 4/10

Granted this isn't a situation which would happen, YET nonetheless illustrates that CLEARLY it entirely makes sense to truncate, and honestly any further argument by you on the subject is just unreasonable.
That describes a situation and a truncation which is fundamentally different from the one we're calculating. It's true that if you have the potential for multiple wounds from a single attack your truncation is appropriate, but in a situation where each attack can only do one wound, it is not.

If all you're saying is that you should truncate the results of individual attacks to prevent them from adding impossible numbers to the mix, then I agree. However, that situation almost never happens in 40k, and the instances where they are (like fire from template weapons or blast weapons) are so obviously incapable of being analyzed by a simple p*n that it doesn't really make much sense to make note of them.

The point in summation, then, is that the truncation you're talking about is not the same truncation I'm talking about.

I'm talking about limiting the number of wounds done by the aggregate of multiple one-wound-possible attacks. This certainly seemed to be what you were talking about in your first post. This type of truncation is wrong.

That is quite different from the type of truncation which would limit the number of possible wounds from a single attack. I'm still not certain that you're right on this, either, but it doesn't really matter since it really never comes up in 40k.

Can you think of a single instance where you've actually seen the error you purport having been made?

Were you actually talking about this second type of truncation the whole time, or were you, as I suspect, actually talking about the first type before switching to the second type to justify your position? If so, you must know that this can't be a good argument.


As for your first point, I'm actually kind of curious, now. Can you describe the situation where you're shooting at both a Falcon and a Wraithlord and run out the numbers for me? You might have a point, there.


edit: Two Quick Thoughts:

First, even Template and Blast weapons won't need the sort of truncation you suggest, since their results are naturally limited by the number of models available as targets.

Second, no, I still disagree. Even if you have a weapon which did 10,000 wounds 10% of the time and none the rest, 1000 would still be the correct number of average wounds. Sure, you only need four, but you'd still be getting 10,000 1/10 times. You wouldn't just be getting four.

Your argument, here, seems predicated on the notion that a thousand wounds is a silly number, thus any method which produces it must also be silly. This is not the case. The method can produce numbers which are larger than the available number of wounds. This, as I discussed earlier, isn't actually a problem. The number your hypothetical gun produces is silly because the gun is silly--not because the method is wrong. The silly number is correct for the silly gun.
 
#13 ·
my problem with not truncating is basically this.

Say, I have 2 guns, one which does a str 4 shot 10% of the time and 10000 wounds 90% of the time and another which does a str 4 shot 10% of the time and 5 wounds 90% of the time.

Now my results when shooting at a carnifex would be the exact same regardless of which of these guns I use, thus my expectation should be the same... Or if it isn't (because we aren't truncating) then the expectation which we are using is a silly representation of how "good" a gun is against a target.
 
#14 ·
I agree that expectation is a silly way to measure a gun like the one you propose. Rather, since on a 'success' it will simply wipe out whatever it's shooting at, it should be valued based on its probability of doing so--not its expected returns.

That, however, doesn't mean that it's bad for all guns.

In fact, the type of expected results calculation I'm discussing is quite useful for evaluating the types of weapons which actually show up in the game. The fact that it produces silly results (not wrong ones, remember, just silly ones) for a silly gun doesn't indicate that we shouldn't use it on the guns which actually exist--and for which it does actually produce useful results.


The fact that you've managed to propose a situation for which expectation doesn't yield a good evaluation doesn't mean that expectation doesn't yield a good evaluation for everything, and the fact that the situation you've used as an example isn't even one which can occur in the game makes your position considerably weaker.
 
#15 ·
The gun just illustrates why one needs to truncate the probability distribution. Saying "the gun won't ever show up in the game" doesn't change what it illustrates...

You talk about the "fundamental difference between doing too many wounds with one attack as opposed to many attacks" which frankly makes no sense if one is shooting from a single squad at a single target. Regardless of whether we shoot 10 melta guns at a carnifex or 1 melta gun which does 1d10 wounds, the carnifex still dies when we do 4 or more wounds. If after we shoot enough to kill the first carnifex, we can redirect our remaining shots at another carnifex, then yes, truncation makes no sense... However, this is not how 40k works. All shots after the 4th wound are wasted... Why should wasted shots be accounted for in expectation?

How about if we adjusted the game so that in a given squad you fire with one weapon at a time, and stop rolling once everyone in your target squad is dead, would this change expectation?
 
#16 ·
The thing is, though, that the gun doesn't illustrate why you need to truncate expectation. It just shows that there are hypothetical guns for which expectation is not the most useful value to find.

The fact is that the manner in which you're proposing to find expected returns is actually wrong and the truncation is inappropriate for this game. It wouldn't really matter whether, in practice you rolled the shots one at a time.

There are situations in which I could see results needing to be truncated, but the result would be something different from straight-forward expectation, and none of those situations occur in 40k.
 
#17 ·
If you roll the shots one at a time it is impossible to do more than 4 wounds, so you would effectively truncate the distribution (though I would say regardless it is impossible to effectively do more than 4 wounds).

I think either you misunderstand what I mean when I say truncate the distribution (count all results >4 wounds as 4 wounds), are being intentionally obstinante, or just lack a fundamental understanding of probability.

If you still disagree, read the beginning of this article for when to use a truncated distribution for expectation calculations

Cookie Absent
 
#18 · (Edited)
Rolling the dice sequentially doesn't prevent you from getting more than four wounds. You still get to roll for every attack. Even if you do enough wounds to kill the 'fex, you can just keep right on rolling and get more.

Your claim is that, because the game effect of getting more wounds is identical to the game effect of getting exactly enough, we should discount the extra. There is no good reason to believe this. The extra can occur.

I read your post, and I know what you mean by truncation. The fact is that you're wrong, and in a minute here I'll show you why.

An incedental fact is that your example was also wrong, on top of not actually serving as the analogy you intended it to be. I'm not going to pursue this further. Any modicum of observation should demonstrate why your example is unconvincing, but harping about it won't prove me right.

This argument, however, will prove me right. Observe:


1. Expectated value is the sum of the products of the probabilities and values of each of the possible outcomes of an event.

2a. A binary event has only two possible results: success or failure.

2b. An event with only success or failure as possible results can be evaluated by assigning a value of 1 to success and zero to failure.

Therefore 3. Evaluating a binary event as suggested in 2b results in an expected value equal to the probability of getting a success.

4. The total expected value of any number of events is equal to the sum of the expected values of each of those events.

Therefor 5. The total expected value of any number of identical events is equal to the expected value of a single instance of that event times the number of events.


To explain it in terms of 40k, let's look at a basic attack.

The attack is a single event. It consists of the roll of three dice--a roll to hit, a roll to wound and a roll to save. Each must generate a success in order for the attack to be successful. (note that for the roll-to-save to be successful from the standpoint of the attacker--which is where we are--it must be failed from the defender's)

If each die has a probability of generating a success (call them Ph, Pw, and Ps respectively) the probability of the event[/ii] being successful is Ph*Pw*Ps.

The probability of getting a success on the attack--the event--is then Ph*Pw*Ps.

The expected value of one such attack is equal to that probability--by definition.

The expected value of X such attacks is equal to that probability mulitplied by X--once again, by definition.

Note that a success in 40k, a success is not always a single wound. It might be a single markerlight token or a wound which inflicts Instant Death, turning into multiple wounds. It is, however, a single wound in the vast majority of cases.

That's it. I've put forth both the rationale behind and, indeed, the very definition of expected value. There is no room for the type of truncation you suggest in your first post. In fact, I would defy you to even indicate where, in this calculation, that truncation would even go.

At least at this point it should be clear that your suggestion is not compatible with the definition of expectation. No matter what you cut or where, your result would be different than the ones found by the method which the definition calls for.

It's really quite simple. What you're suggesting is interesting. In some situations it might be useful. What it will never be is expected value.
 
#19 · (Edited)
Expected value is actually just a property of a random variable. I'm truncating the distribution of the random variable, and the expectation of that new distribution is exactly what i'm saying it is.

My random variable is "the outcome of a squad firing at a carnifex", your random variable is "the outcome of 1 gun firing at 1 carnifex", so with an infinite supply of carnifexes (in a single squad) for you, your expectation is fine.

Say we had a 10 man fire dragon squad firing at a carnifex. We calculate the state of the carnifex (ie 4 wounds, 3 wounds, 2 wounds, 1 wound, or 0 wounds) after all 10 fire dragons fired, and repeated this 1000 times. If you were to take 4 minus my expectation you would get the average number of wounds remaining on all the carnifexes (or a very very close number).

Whereas, if we took 10 firedragons each independent, each firing at his own carnifex, and repeated this 1000 times, the average number of wounds done to each group of 10 carnifexes would be equal (or rather very very close) to your expectation.


Here you say:
"The expected value of X such attacks is equal to that probability mulitplied by X--once again, by definition. "

by definition of a binomial distribution. I'm using a truncated binomial, so for this distribution expectation is different

Furthermore, you just claimed that a JSTOR article was wrong...
 
#21 · (Edited)
Expected value is actually just a property of a random variable. I'm truncating the distribution of the random variable, and the expectation of that new is distribution is exactly what i'm saying it is.

My random variable is "the outcome of a squad firing at a carnifex", your random variable is "the outcome of 1 gun firing at 1 carnifex", so with an infinite supply of carnifexes (in a single squad) for you, your expectation is fine.
I see what you're saying, but you're still off.

In actuality, the number I'm is the outcome of a squad firing at a single carnifex. Not just one gun at one 'fex, but any number of guns at a single 'fex. While it's true that wounds beyond the fourth are "wasted," this isn't relavent in the context of a single squad shooting at a single fex.

Where it becomes relavent is, as you point out later, when multiple squads are shooting at multiple 'fexes. You give the following scenario:

"Say we had a 10 man fire dragon squad firing at a carnifex. We calculate the state of the carnifex (ie 4 wounds, 3 wounds, 2 wounds, 1 wound, or 0 wounds) after all 10 fire dragons fired, and repeated this 1000 times. If you were to take 4 minus my expectation you would get the average number of wounds remaining on all the carnifexes (or a very very close number). "

This is certainly true, but the method you use here is correct when the event in question is a single squad shooting at a single 'fex--and you want expected value for a set of such events.

It is not correct for an event which is a single gun shooting at a single fex and what you want is expected value for a set of those events.

So, I do see what you're saying. If you're calculating a certain thing, namely expected results for a series of non-binary events (i.e. several squads firing on several carnifices) you'll need to do things differently. You have to have some way to prevent "rollover" wounds from affecting the outcome.


When you're only interested in one squad and one 'fex, though (as is virtually always the case) you don't have to worry about roll-over wounds. In fact, eliminating roll-over wounds isn't even accurate, since, as I said, those wounds do occur--even if they have no actual effect on the game.

The method you propose is indeed correct for a certain type of evaluation, but it is roundabout and indeed inaccurate when dealing with the situation that most people are interested in: namely a single set of weapons all firing at a single target.

To put it another way, you're finding expected value in terms of the 'fex's state. When I do 'mathhammer' that's not what I'm finding. I'm finding expected value in terms of the number of wounds done. While you have demonstrated that the two are different (imagine that) and that the former requires a different method than the latter (go figure) it remains a fact that, to find the expected number of wounds inflicted, my method is the correct one. Oddly, the expected number of wounds inflicted will not, because of those differences in method, dovetail perfectly with expected number of wounds remaining.

That isn't a reason to ditch the one in favour of the other, though, and it remains the case that nothing you've said justifies your initial suggestion that finding expected value in terms of wounds can't be done properly in the method I support. Clearly, it can.
 
#20 ·
There are 5 possible outcomes in my distribution, the distribution looks like this:

1) Carnifex has 4 wounds left after firing

probability:
(1 - 2/3 * 5/6)^10

2) Carnifex has 3 wounds left after firing

probability
10 * (1 - 2/3 * 5/6)^9 * (2/3 * 5/6)

3) Carnifex has 2 wounds left after firing

probability
10*9/2 * (1 - 2/3 * 5/6)^8 * (2/3 * 5/6)^2

4) Carnifex has 1 wound left after firing

probability
10*9*8/(2*3) * (1 - 2/3 * 5/6)^7 * (2/3 * 5/6)^3

5) Carnifex is dead after firing

1 - the sum of all of the above

Notice that the last possibility in my distribution encompasses 4+ successes in a traditional binomial. All I am doing is figuring out the expectation of this distribution.

*by firing, I mean being fired upon by 10 Fire Dragons
 
#22 ·
"In actuality, the number I'm is the outcome of a squad firing at a single carnifex. Not just one gun at one 'fex, but any number of guns at a single 'fex. While it's true that wounds beyond the fourth are "wasted," this isn't relavent in the context of a single squad shooting at a single fex."

Yes. Yes it is relevant...

"When you're only interested in one squad and one 'fex, though (as is virtually always the case) you don't have to worry about roll-over wounds. In fact, eliminating roll-over wounds isn't even accurate, since, as I said, those wounds do occur--even if they have no actual effect on the game."

Yes. Yes you do have to worry about roll-over wounds

Again, I will say:

Suppose we had a 10 man fire dragon squad firing at a carnifex. We calculate the state of the carnifex (ie 4 wounds, 3 wounds, 2 wounds, 1 wound, or 0 wounds) after all 10 fire dragons fired, and repeated this 1000 times. If you were to take 4 minus my expectation you would get the average number of wounds remaining on all the carnifexes (or a very very close number).

Whereas, if we took 10 firedragons each independent, each firing at his own carnifex, and repeated this 1000 times, the average number of wounds done to each group of 10 carnifexes would be equal (or rather very very close) to your expectation.

Your scenario works if we are talking about heavy weapons from different squads, and they have other targets worth shooting at (such as other Fexes) once the first is dead... Mine is for one large target or a squad shooting at one target.

"To put it another way, you're finding expected value in terms of the 'fex's state. When I do 'mathhammer' that's not what I'm finding. I'm finding expected value in terms of the number of wounds done. While you have demonstrated that the two are different (imagine that) and that the former requires a different method than the latter (go figure) it remains a fact that, to find the expected number of wounds inflicted, my method is the correct one. Oddly, the expected number of wounds inflicted will not, because of those differences in method, dovetail perfectly with expected number of wounds remaining."

What I care about is the interpretation through the law of large numbers. Mine has a reasonable interpretation through that, your distribution frankly does not if it is only 1 fex and 1 squad as is largely the case (according to you). The whole point of expectation is that it appears in the law of large numbers and the central limit theorem, other than that there is really nothing special about it.
 
#23 · (Edited)
it is a point well taken that the expected value can easily be misused.

i used to teach a course on the binomial theorem, and i question i loved to give students on an exam was this:

1 out of 8 cars on the lot is black. if you pick 8 cars randomly, what is the probability of exactly 1 being black?

you can't imagine how many students told me the answer was 1. that actually is impossible.

i just diddled with some numbers, and i noticed a pattern. if you find the expected value to be 1, such as in the test question, it actually translates to around a 36% probability of occurring. what this means is that even though you can expect to pick 1 black car, the actual probability of that happening is just over 36%.

this casts the discussion over destroying falcons in an entirely different light. what you want to know is the smallest number of missiles to fire to give yourself at least a 50% chance of blowing up the target, yeah?

you don't need all your wiki hardware.

all you need to know is that getting at least one successful outcome (blowing up the target) is just the complement of having all failed shots. as soon as the probability of failing all shots drops below 50 percent then you have your answer.

for any binomial distribution the p(all failures) = q^n where q is the probability of a failed trial and n is the total number of trials.

in your example q=25/27

so we get the equation .5= (25/27)^n

taking log of both sides gives us log .5 = n log (25/27) remembering our power rule of logs, of course.

solving for n gives us 8.98. this means that the probability of getting all failures in 8.98 shots is precisley 50%. so if you round up to 9 then you get that the probability of getting all failures in 9 shots is less than 50 percent.

if you are uncomfortable with using logs, then really all you have to do is figure out what the probability of a failed shot is that just start raising it to higher and higher powers until the value you get is acceptably low to you. whatever the exponent you stopped at is the number of shots you will need to shoot to get the probabilty of at least one success. if you picked a high enough exponent this probability should be over 50%. after all you don't want to shoot a shot that you are odds on to miss. right?

i still think expected values are useful, but keep in mind that they can be overkill. in the previous example the expected value came out to be 13.5. this means that you would have to shoot on average 13.5 times before you destroy the falcon. the actual probability of getting at least one destroyed falcon in 13.5 shots is about 65%.

the moral of the story is that if you just play on the expected value then you will be fine. worrying about smallest number of shots to ensure a 50% probability of success is a fun little exercise, but outside of us mathematicians i don't think you need to worry about it.
 
#25 ·
i think this discussion has been useful in showing that using the expected value can be misleading, but i really think that most of this discussion has been unnecessary.

the crazy gun example posed earlier leads to peculiar results if you think about what happens when you fire it once. but expected value is really designed to be the mean of a data set.

think about this, say you have a squad of 100 soldiers who all have the option to either take the crazy gun that 90% of the time does pretty much nothing and 10% of the time causes 1000 wounds. using your truncated calculation would suggest that it would be foolish to arm them such. but the truth is that the expected value is vindicated here as on average every time the soldiers fire you will cause 10,000 wounds. that is pretty damned awesome. a gun with a lower expected value, but with a higher truncated value would look better to you but would actually be worse in this example.

the point is that expected values have to be understood in their proper context.

if you want to gauge the wisdom of using a certain gun, i don't really see the benefit of consulting the expected value. what i do is look at the number of wounds per shot. the higher the value the better the choice.

ex: plasma gun vs melta gun. the melta gun is stronger and has lower AP. the plasma gun gets two shots and can overheat. since overheating only can happen on a miss it has nothing to do with how many wounds it can deliver.

both guns hit the same, but melta guns have a 16% better chance of wounding than plasma. taking .66x.84=.55 which is the number of wounds per shot of melta against a T4 target. .66x.66=.43 is the number of wounds per shot of plasma, but since plasma is rapid fire we double that to get .86. thus for plasma is better at killing T4 targets than melta.

once you know what your goal is then it really isn't all that hard to figure out what the best tool for the job is.

i have yet to encounter a moment in a game where i needed to know more than that.

and in case you are wondering i have never lost a game.
 
#26 ·
"Therefore 3. Evaluating a binary event as suggested in 2b results in an expected value equal to the probability of getting a success."

actually this isn't right. the expected value is E(X), and it is not equal to the probability of getting a success, p. the expected value is defined as you said. what it means though is the average number of successes you can expect to get for a given number of trials. i don't think you meant what you actually wrote, because everything else you said is correct.


as to the whole issue that started this debate (truncation), it only has meaning if you resolve each shot separately, not if you fire each shot separately. until saves are rolled, the carnifex still has all its wounds available. you are only disallowed from further shots if it is dead. thus the reall issue is do you roll saves as the dice come out, or do you wait until all attacks are rolled. the book is quite clear on the order. the rules are designed to reflect reality, and since one guy doesn't wait until his buddies bullets hit...neither will the models. they all fire at the same time, and whatever happens after the bullets leave the barrels is up to fate.

also, i looked at that article, and it wasn't very helpful as only the abstract was available. there is simply no way to determine if it is modelling what we are talking about.
 
#27 ·
Suppose we had a 10 man fire dragon squad firing at a carnifex. We calculate the state of the carnifex (ie 4 wounds, 3 wounds, 2 wounds, 1 wound, or 0 wounds) after all 10 fire dragons fired, and repeated this 1000 times. If you were to take 4 minus my expectation you would get the average number of wounds remaining on all the carnifexes (or a very very close number).
doing this experiment would give you a data set with 1000 elements all ranging between 0 and 4. simply adding them all up and dividing by 1000 would give you the average number of wounds on the carnifexes. there is no reason to take 4 minus the expected value.

Whereas, if we took 10 firedragons each independent, each firing at his own carnifex, and repeated this 1000 times, the average number of wounds done to each group of 10 carnifexes would be equal (or rather very very close) to your expectation.

this answer would be exactly the same as the former part. wounds are independent events. the occurrence of a wound is independent of how the rolls prior to it have turned out. the probability of the 10th shot scoring a wound is exactly the same as that of the first shot. the whole reason that the binomial formula works at all this case is because of this. you seem to keep falling back on the fact that a carnifex can only suffer 4 wounds. so what? it's possible that the carnifex may have to make 25 saves off a given attack. if you want to compute the probability of an unsaved wound, then you have the problem of what to do after you have scored the 4th one, but that isn't what the other guy is talking about. make sure everybody is having the same discussion. are you now asking how many shots should you fire to have a 50% chance of killing a carnifex? that is very different from the falcon question
 
This is an older thread, you may not receive a response, and could be reviving an old thread. Please consider creating a new thread.
Top