private List<UnaryRule>[] matrixMultiply(List<UnaryRule>[] parentRules,List<UnaryRule>[] childRules){
  throw new Error("I'm broken by parent first");
}

private List < UnaryRule > [ ] matrixMultiply ( List < UnaryRule > [ ] parentRules , List < UnaryRule > [ ] childRules ) { throw new Error ( "I'm broken by parent first" ) ; }
' parentrules ' , ' childrules ' and the return value all have the same format as ' unaryruleswithparent ' , but can be thought of as square matrices . all this function does is a matrix multiplication , but operating directly on this non - standard matrix representation . ' parentrules ' gives the probability of going from a to b , ' childrules ' from b to c , and the return value from a to c ( summing out b ) . this function is intended primarily to compute unaryruleswithparent ^ n .
