// ~->[DNET-1]->~ // File created by YendallJ at Norsys using Netica 5.00 on Mar 29, 2011 at 19:26:44. bnet Imposs_Demo { autoupdate = TRUE; comment = "\n\ IMPOSSIBLE CONDITION CHECK\n\ --------------------------\n\n\ This Bayes net was built to demonstrate the following situation:\n\n\ \| > In the original net P(A=false) was 100% so it could never \n\ \| > arise that B was true. The net designer was counting on\n\ \| > that when he built the CPT of node D. So he used Xs for\n\ \| > that condition of the table. He also used Xs for the\n\ \| > condition B and C were false at the same time, based on\n\ \| > the overall network. Everything worked fine.\n\n\ \| > But then, in a re-design of network it was indicated\n\ \| > that occasionally A could be true, so P(A=true) was\n\ \| > changed to 10%. When the network was compiled and\n\ \| > updated, the error message you see was generated,\n\ \| > so the designer knew exactly what needed to be fixed\n\ \| > (in the CPT of node D).\n\n\ \| > If you change P(A=false) back to 100%, you will see\n\ \| > that the net compiles and updates without error.\n\ \| > Then you may want to change the CPT of node C, in which\n\ \| > case a different row of Xs in the D table will be\n\ \| > flagged as incorrect when you next compile.\n\n\ This is a simplified example to demonstrate the concept\n\ (actually, node A would have little purpose in the \n\ original design), but in real-life situations, the \n\ relationships may be very subtle, and it is easy to make \n\ this type of error.\n\n\ Bayes net designers often simply put a uniform distribution\n\ for probabilities conditioned on events impossible to occur.\n\ Since these distributions are irrelevant, any distribution\n\ will yield the same inference results.\n\n\ However, a miscalculation of what is impossible, or a change \n\ to some other part of the network which makes the condition\n\ possible, means that the distribution does matter, and\n\ perhaps a uniform distribution is not at all the right one.\n\n\ So, if the Bayes net designer uses a distribution of Xs\n\ instead of a uniform (or any other) distribution in the\n\ initial design, then during belief updating Netica will \n\ check to see if that condition truly is impossible, and \n\ give an error message if necessary.\n\n\ There is no performance penalty for using the Xs, providing\n\ they indicate truly impossible conditions.\n\n\ The Xs are also an important documentation aid, to indicate \n\ to other designers which parts of the CPT are irrelevant.\n\n\n\n\n\n\ "; whenchanged = 1051164768; visual V1 { defdispform = BELIEFBARS; nodelabeling = TITLE; NodeMaxNumEntries = 50; nodefont = font {shape= "Arial"; size= 10;}; linkfont = font {shape= "Arial"; size= 9;}; windowposn = (16, -1, 761, 523); CommentShowing = TRUE; CommentWindowPosn = (39, 522, 699, 840); resolution = 72; drawingbounds = (1080, 720); showpagebreaks = FALSE; usegrid = TRUE; gridspace = (6, 6); NodeSet Node {BuiltIn = 1; Color = 0xc0c0c0;}; NodeSet Nature {BuiltIn = 1; Color = 0xf8eed2;}; NodeSet Deterministic {BuiltIn = 1; Color = 0xd3caa6;}; NodeSet Finding {BuiltIn = 1; Color = 0xc8c8c8;}; NodeSet Constant {BuiltIn = 1; Color = 0xffffff;}; NodeSet ConstantValue {BuiltIn = 1; Color = 0xffffb4;}; NodeSet Utility {BuiltIn = 1; Color = 0xffbdbd;}; NodeSet Decision {BuiltIn = 1; Color = 0xdee8ff;}; NodeSet Documentation {BuiltIn = 1; Color = 0xf0fafa;}; NodeSet Title {BuiltIn = 1; Color = 0xffffff;}; PrinterSetting A { margins = (1270, 1270, 1270, 1270); landscape = FALSE; magnify = 1; }; }; node A { kind = NATURE; discrete = TRUE; chance = CHANCE; states = (true, false); parents = (); probs = // true false (0.1, 0.9); whenchanged = 947832651; visual V1 { center = (384, 78); height = 2; }; }; node B { kind = NATURE; discrete = TRUE; chance = DETERMIN; states = (true, false); parents = (A); functable = // A (true, // true false); // false ; whenchanged = 947076241; visual V1 { center = (216, 234); height = 1; }; }; node C { kind = NATURE; discrete = TRUE; chance = DETERMIN; states = (true, false); parents = (A); functable = // A (false, // true true); // false ; whenchanged = 947076290; visual V1 { center = (546, 234); height = 4; }; }; node D { kind = NATURE; discrete = TRUE; chance = CHANCE; states = (true, false); parents = (B, C); probs = // true false // B C (@imposs, @imposs, // true true @imposs, @imposs, // true false 0.2, 0.8, // false true @imposs, @imposs); // false false ; whenchanged = 947076604; visual V1 { center = (384, 396); height = 3; }; }; node NOTE1 { kind = CONSTANT; discrete = FALSE; parents = (); title = "When you compile and update this\n\ net, you should get an error message.\n\n\ Choose Window->Description of Net\n\ from the menu for an explanation."; whenchanged = 947856464; visual V1 { center = (144, 354); height = 5; }; }; node TITLE1 { kind = CONSTANT; discrete = FALSE; parents = (); title = "Demo of Impossible\nCondition Check"; whenchanged = 947832749; visual V1 { center = (120, 114); font = font {shape= "Arial"; size= 14;}; height = 6; }; }; };