## EXAMPLE 1
## Figure 1 in Coolen and Coolen-Maturi (2012)
# First, define the structure, ensuring that each physically separate component
# is separately numbered
fig1 <- createSystem(s -- 1 -- 2:3 -- 4 -- 5:6 -- t, 2 -- 5, 3 -- 6)
# Second, specify the type of each of those numbered components
# (leaving s,t with no type)
fig1 <- setCompTypes(fig1,
list("Type 1" = c("1","2","5"),
"Type 2" = c("3","4","6")))
# Third, compute the survival signature (getting fractions rather than decimals)
computeSystemSurvivalSignature(fig1, frac = TRUE)
## EXAMPLE 2
## Figure 3 in Coolen et al (2013)
# First, define the structure, ensuring that each physically separate component
# is separately numbered.
# For this example, we demonstrate how to define the component types at system
# creation time
fig3 <- createSystem(s -- 1:4 -- 2:5 -- 3:6 -- t, s -- 7:8, 8 -- 9, 7:9 -- t,
types = list("Type 1" = "1",
"Type 2" = c("2","3","4","7"),
"Type 3" = c("5","6","8","9")))
# Third, compute the survival signature (getting fractions rather than decimals)
computeSystemSurvivalSignature(fig3, frac=TRUE)
Run the code above in your browser using DataLab