How can a Boolean representation be displayed as symbolic algebra?

Can Mathematica 9 convert a Boolean representation of an RBD to its symbolic algebraic form?

If I have a simple series configuration made up of 2 components

bexpr1=And[c1,c2]

and the corresponding symbolic representation for the system would be RS1 = R1*R2

The system I am interested in is more complex and contains 7 components in a 4 path architecture:

path1=And[c1,c2,c5,c7]

path2=And[c1,c3,c5,c7]

path3=And[c1,c3,c6,c7]

path4=And[c1,c4,c6,c7]

bexpr2=Or[path1,path2,path3,path4]

Of course, other systems can have higher complexity.

How can the algebraic form of the reliability function be obtained for bexpr2?

Thank you.

Are you just looking to use the engineering (+,*) notation for boolean logic?

One quick solution is to replace And with Times and Or with Plus:

bexpr2 /. {And -> Times, Or -> Plus}
c1 c2 c5 c7 + c1 c3 c5 c7 + c1 c3 c6 c7 + c1 c4 c6 c7

There are better ways of doing this using the Notation package that will allow Mathematica to still interpret this as a boolean logic statement.

Sean,

Thank you for the reply. I think I should have been more descriptive in my question.

The solution I’m trying to confirm can be seen in Eqn. (3) on page 5 in the PDF file at the following link.

http://www.reliasoft.com/newsletter/2Q2000/index.htm

For example,

dists = Table[{ToExpression["c" ~~ ToString[i]], 
    BernoulliDistribution[ToExpression["r" ~~ ToString[i]]]}, {i, 7}];

Expand[PDF[ReliabilityDistribution[bexpr2, dists], 1]]

(* Out[7]= r1 r2 r5 r7 + r1 r3 r5 r7 - r1 r2 r3 r5 r7 + r1 r3 r6 r7 + 
 r1 r4 r6 r7 - r1 r3 r4 r6 r7 - r1 r3 r5 r6 r7 - r1 r2 r4 r5 r6 r7 + 
 r1 r2 r3 r4 r5 r6 r7 *)

This is the same as Eqn. (3):

% === r1 r4 r6 r7 + r1 r3 r6 r7 - r1 r3 r4 r6 r7 + 
  r1 r2 r3 r4 r5 r6 r7 + r1 r3 r4 r5 r6 r7 - r1 r2 r3 r4 r5 r6 r7 - 
  r1 r2 r3 r5 r6 r7 - r1 r3 r5 r6 r7 + r1 r2 r3 r5 r6 r7 - 
  r1 r2 r4 r5 r6 r7 - r1 r3 r4 r5 r6 r7 + r1 r2 r3 r4 r5 r6 r7 + 
  r1 r2 r5 r7 + r1 r3 r5 r7 - r1 r2 r3 r5 r7

(* Out[8]= True *)

Ilian,

You produced an impressive solution, thank you.

I verified that your code in fact produces the result shown in Eq.(3) and that it works on other cases as well.
Your solution is exactly what I was looking for, nice piece of work indeed !

Also, kudos to the Mathematica Development Team for building such a brilliant computing environment ; do keep up the good work and keep pushing the boundaries !

There is also a more direct way to do this using a Library function, which will probably scale better for large problems:

Reliability`Library`StructureFunction[bexpr2]