# Surveillance Cameras

Cameras are arranged in an overlapping grid. All areas are covered until a 2-by-2 grid fails. Each camera has an expected lifetime of six years. Compare the reliability of this system to a system with only four cameras, with and without standby components.
 In[1]:= Xstructure = BooleanConsecutiveFunction[{2, 2}, {4, 4}][ Array[Subscript[x, #1, #2] &, {4, 4}]]; \[ScriptCapitalD]camera = ExponentialDistribution[1/6]; \[ScriptCapitalF] = FailureDistribution[structure, Join @@ Array[{Subscript[ x, #1, #2], \[ScriptCapitalD]camera} &, {4, 4}]]; \[ScriptCapitalF]nooverlap = FailureDistribution[ Subscript[x, 1] || Subscript[x, 2] || Subscript[x, 3] || Subscript[ x, 4], {{Subscript[x, 1], \[ScriptCapitalD]camera}, {Subscript[x, 2], \[ScriptCapitalD]camera}, {Subscript[x, 3], \[ScriptCapitalD]camera}, {Subscript[x, 4], \[ScriptCapitalD]camera}}]; \[ScriptCapitalD]standby = StandbyDistribution[\[ScriptCapitalD]camera, \ {\[ScriptCapitalD]camera, \[ScriptCapitalD]camera, \ \[ScriptCapitalD]camera}, 0.9]; \[ScriptCapitalF]standby = FailureDistribution[ Subscript[x, 1] || Subscript[x, 2] || Subscript[x, 3] || Subscript[ x, 4], {{Subscript[x, 1], \[ScriptCapitalD]standby}, {Subscript[x, 2], \[ScriptCapitalD]standby}, {Subscript[x, 3], \[ScriptCapitalD]standby}, {Subscript[x, 4], \[ScriptCapitalD]standby}}];
 In[2]:= XPlot[Evaluate@{SurvivalFunction[\[ScriptCapitalF], t], SurvivalFunction[\[ScriptCapitalF]nooverlap, t], SurvivalFunction[\[ScriptCapitalF]standby, t]}, {t, 0, 15}, Filling -> Axis, PlotLegends -> Placed[{"Consecutive", "No overlap", "Standby"}, Below]]
 Out[2]=