Basically, the equation works by calculating the odds of all eggs being normal, then subtracting this number from one to get the odds of getting at least one morph in the clutch. One, being the sum of the probabilities of all possibilities (i.e. 100%).

So in the examples, if your odds are 50% of hitting, there is also a 50% chance of not hitting. You then calculate the odds of all eggs not hitting, which is... (0.50) x (0.50) x ....
To simplify this formula, you then just use an exponent for the number of eggs i.e. (0.50)^#eggs

You can also calculate the odds of getting exactly one, exactly two, etc... but that becomes a lot more difficult because order matters. For instance, to get one morph in a clutch of four, you need to calculate the odds of egg#1 being a morph and all other eggs normal + the odds of egg#2 being a morph and all other eggs normal, etc... There are 4 ways of ordering this, so your total odds are:
4 x (0.50)^1 x (0.50)^3 = 0.25

where 0.50^1 is the odds of getting the morph and 0.50^3 is the odds of the other 3 eggs being normal.

This gets a lot more complex when you have 2 eggs in a clutch that turn out to be a morph, because the number of ways you can order it are more complex. For instance, the 2 eggs being the morph in a clutch of 4 can be: 1&2, 1&3, 1&4, 2&3, 2&4, and 3&4, a total of 6 combinations. You also need to be careful not to count any combination twice. For a general formula to calculate the number of orderings, you can use the formula for combinatorics:
For nCk (read n choose k):
Code:
       n!
--------------
k! x (n - k)!
where ! means factorial. e.g. 3! = 3 x 2 x 1

In our example, this would be:
Code:
       4!               4!         4 x 3 x 2 x 1
--------------   =  ----------  = ---------------  = 6, as we counted above
2! x (4 - 2)!        2! x (2)!      2 x 1 x 2 x 1
So, in other words, the general formula for getting a number of mutations k of probability p in a clutch of size n is:

Code:
(# of combinations) x (probability of the combination)

       n!              
--------------  x  [ (p)^k x (1 - p)^(n-k) ]
k! x (n - k)!