Restructured bayesian network: Removed duplicate functions