Independent Events

Author

Eric W. Weisstein
August 31, 2026

This notebook downloaded from https://mathworld.wolfram.com/notebooks/Probability/IndependentEvents.nb.

For more information, see Eric's MathWorld entry https://mathworld.wolfram.com/IndependentEvents.

Copyright 2026 Wolfram Research, Inc. except for portions noted otherwise

Figure

An area model with P(A)=1/2 and P(B)=2/5; the overlap has area 1/5=P(A)P(B).

Module[{ink, frame, eventA, eventB, probability, intersection, formulas}, 
  ink = LightDarkSwitched[Black, White]; frame = {EdgeForm[{ink, AbsoluteThickness[2]}], 
     FaceForm[None], Rectangle[{0, 0}, {1, 1}]}; 
   eventA = {Opacity[0.42], Blue, Rectangle[{0, 0}, {1/2, 1}]}; 
   eventB = {Opacity[0.42], Orange, Rectangle[{0, 0}, {1, 2/5}]}; 
   probability[event_] := Row[{Style["P", Italic], "(", event, ")"}]; 
   intersection = Row[{Style["A", Italic], FromCharacterCode[8745], Style["B", Italic]}]; 
   formulas = Column[(Style[#1, 17, FontFamily -> "Times"] & ) /@ 
      {Row[{probability[Style["A", Italic]], " = ", 1/2}], 
       Row[{probability[Style["B", Italic]], " = ", 2/5}], 
       Row[{probability[intersection], " = ", 1/5}], Row[{probability[intersection], " = ", 
         probability[Style["A", Italic]], Spacer[4], probability[Style["B", Italic]]}]}, 
     Alignment -> Left]; Graphics[{eventA, eventB, frame, 
     {ink, Text[Style["A", 20, Italic, FontFamily -> "Times"], {0.25, 0.72}], 
      Text[Style["B", 20, Italic, FontFamily -> "Times"], {0.78, 0.2}], 
      Text[Style[Row[{"A", FromCharacterCode[8745], "B"}], 15, Italic, FontFamily -> "Times"], 
       {0.25, 0.2}], Text[formulas, {1.25, 0.52}, {-1, 0}]}}]]