private void addChild(BayesNetNode node) { if (!(children.Contains(node))) { children.Add(node); } }
public void influencedBy(BayesNetNode parent1) { addParent(parent1); parent1.addChild(this); distribution = new ProbabilityDistribution(parent1.getVariable()); }