Probability | Binomial Distribution | Best Tire Forward

Question: Consider the following scenario


Part 1: Visualization

Consider the check and cross marks to be the tires. A check indicates a functional tires and a cross indicates a failed tire.

Success configurations for a 2-Tire Vehicle

    Module[{marks = {Style["\[Checkmark]", Darker@Green], Style["✗", Red]}, replacer, configs, tires = 2},
     replacer[list_List] := Table[If[list[[n]] == 1, marks[[1]], marks[[2]]], {n, 1, Length@list}];
     configs = (replacer /@ Union@SortBy[Select[Tuples[{0, 1}, tires], Plus @@ # >= 0.5 tires &], Plus @@ # &]);
     TableForm[Table[Apply[StringJoin,ToString[#, StandardForm] & /@ configs[[n]]], {n, 1, Length@configs}]]]
    
Success configurations for a 4-Tire Vehicle

    Module[{marks = {Style["\[Checkmark]", Darker@Green], Style["✗", Red]}, replacer, configs, tires = 4},
     replacer[list_List] := Table[If[list[[n]] == 1, marks[[1]], marks[[2]]], {n, 1, Length@list}];
     configs = (replacer /@ Union@SortBy[Select[Tuples[{0, 1}, tires], Plus @@ # >= 0.5 tires &], Plus @@ # &]);
     TableForm[Table[Apply[StringJoin,ToString[#, StandardForm] & /@ configs[[n]]], {n, 1, Length@configs}]]]
    
Success configurations for a 6-Tire Vehicle

    Module[{marks = {Style["\[Checkmark]", Darker@Green], Style["✗", Red]}, replacer, configs, tires = 6},
     replacer[list_List] := Table[If[list[[n]] == 1, marks[[1]], marks[[2]]], {n, 1, Length@list}];
     configs = (replacer /@ Union@SortBy[Select[Tuples[{0, 1}, tires], Plus @@ # >= 0.5 tires &], Plus @@ # &]);
     TableForm[Partition[Table[Apply[StringJoin, ToString[#, StandardForm] & /@ configs[[n]]], {n, 1, Length@configs}], 7]]]
    
Success configurations for a 8-Tire Vehicle

    Module[{marks = {Style["\[Checkmark]", Darker@Green], Style["✗", Red]}, replacer, configs, tires = 8},
    replacer[list_List] := Table[If[list[[n]] == 1, marks[[1]], marks[[2]]], {n, 1, Length@list}];
    configs = (replacer /@ Union@SortBy[Select[Tuples[{0, 1}, tires], Plus @@ # >= 0.5 tires &], Plus @@ # &]);
    TableForm@Partition[Join @@ {Table[Apply[StringJoin,ToString[#, StandardForm] & /@ configs[[n]]], {n, 1, Length@configs}],
    Table[Style[StringJoin @@ Table["\[Checkmark]", tires], White], 5]}, 8]]
    

Part 2: Mathematical Modeling

Mathematical modelling is straightforward since the objective is clear. For a vehicle with 2n tires, we need at-least n tires working. Total probability for a successful flight is \[\underset{n}{\Sigma} C_{k} p^{k}(1-p)^{2n-k} : k \ge n\]

The question asks the probability for which the 2-Tire vehicle is preferable to the 4-Tire vehicle. For this we need \(2n\) be equal to 2 and 4. The expansion results in the following. \[2p(1 − p) + p^{2} = 6p^{2} + (1 − p)^{2} + 4p^{3}(1 − p) + p^{4}\]

Solving for \(p\), we get the following solutions. \(p = 0; p = 0.66667; p = 1\). The code for solving that is pasted below.


    Module[{n = 4},
        Solve[
            Sum[Binomial[2, i] Power[p, i] Power[1 - p, 2 - i], {i, 1, 2}] ==
            Sum[Binomial[n, i] Power[p, i] Power[1 - p, n - i], {i, 0.5 n, n}],p]
        ]
    

Graphically, and comparing the 2-Tire vehicle to the 4-Tire vehicle, we see a nice pattern taking shape.


    Module[{maxE = 4},
        Plot[Evaluate@
        Table[Sum[
            Binomial[r, i] Power[p, i] Power[(1 - p), r - i], {i, 0.5 r, r}], {r, 2, maxE, 2}], {p, 0, 1},
                ImageSize -> 575,
                AxesLabel -> {"p", "p for 50% or more tires"},
                PlotLegends -> Table["No. of Tires = " <> ToString[n], {n, 2, maxE, 2}],
                Frame -> True]
        ]
    

    Module[{maxE = 16},
        Plot[Evaluate@
        Table[Sum[
            Binomial[r, i] Power[p, i] Power[(1 - p), r - i], {i, 0.5 r, r}], {r, 2, maxE, 2}], {p, 0, 1},
                ImageSize -> 575,
                AxesLabel -> {"p", "p for 50% or more tires"},
                PlotLegends -> Table["No. of Tires = " <> ToString[n], {n, 2, maxE, 2}],
                Frame -> True]
        ]