The DeMorgan gate

<< Click to Display Table of Contents >>

Navigation:  Building blocks of QGeNIe > Components of GeNIe models >

The DeMorgan gate

This section gives a brief introduction to the DeMorgan gate  (Maaskant 2006, Maaskant & Druzdzel 2008, Druzdzel 2009), which is the fundamental model of interaction among propositional variables in QGeNIe.

Those readers who were exposed to some logic in high school or college know that any logical function can be expressed in one of the Augustus De Morgan's canonical forms, an alternative (OR) of conjunctions (AND) or a conjunction of alternatives. It is also a fact stemming from so called De Morgan laws that the OR function and a negation can express the AND function. A combination of OR functions and negations can express any logical function. QGeNIe's DeMorgan gate offers essentially an intuitive way of expressing any logical function and, in particular, a combination of ORs, ANDs, and negation.

Four basic influence types

The DeMorgan gate allows for modeling four basic types of influences that one variable (parent in the directed graph) can have on another (a child in the directed graph): (1) a positive influence (a Cause) and (2) a negative influence (a Barrier), both combining with other causes using a noisy OR interaction, (3) a required condition (a Requirement) and (4) a condition that prevents the effect from happening (an Inhibitor), both combining with other causes through an AND interaction.

We will now explain the meaning of the four types of causal influences and how they form any logical function when combined.

Cause

A cause is a parent that has a positive influence on the child. Please note that this influence does not need to be perfect. For example, smoking is generally believed to be a causal factor in lung cancer. Yet, incidence of lung cancer among smokers, while much larger than incidence of lung cancer among non-smokers, is still within a few percent. Hence, the conditional probability of lung cancer given that a person is a smoker is still fairly low. The cause increases the probability of the effect but does not need to be perfect in its ability to cause it.

Barrier

A barrier is a parent that decreases the probability of a child. For example, regular exercise decreases the probability of heart disease. While it is a well established factor with a negative influence on heart disease, it is unable by itself to prevent heart disease. One way of looking at a barrier is that it is dual to a cause: Absence of the barrier event is a causal factor for the child. One might go around the very existence of barriers by using negated versions of the variables that represent them. In the example above, one might define a variable Lack of regular exercise, which would behave as a cause of the variable Heart disease. This, however, might become cumbersome if Regular exercise participated in other interactions in a model. It might happen that it is a parent of both Heart disease and Good physical shape. Because Regular exercise decreases the probability of one and increases the probability of the other, Barrier, which is a negated Cause, is a useful modeling construct.

Requirement

A requirement is a parent that is required for the child to be present. There are perfect requirements, such as being a biological female is a requirement for being pregnant but there are also requirements that are in practice not completely necessary. For example, a sexual intercourse is generally believed to be a requirement for pregnancy, but it is not a strict requirement, as pregnancy may be also caused by artificial insemination.

Inhibitor

An inhibitor is a parent that prevents the child from happening. For example, rain may inhibit wild land fire. Like in the other types of interactions, the parent may be imperfect in inhibiting the occurrence of the child. Fire may start even if there is rain. Similarly to the relationship between causes and barriers, inhibitors are dual to requirements: Absence of an inhibitor event is a requirement for the child. One might go around the very existence of inhibitors by using negated versions of the variables that represent them. In the example above, one might define a variable No rain, which would behave as a requirement for the variable Wild land fire. This, however, might become cumbersome if Rain participated in other interactions in a model. It might happen that it is a parent of both Wild land fire and Good crop. Because Rain is an inhibitor for the former and a requirement for the latter, Inhibitor, which is a negated Requirement, is a useful modeling construct.

 

For those readers who like a concise mathematical formulation, the four types of causes interact with their effect through the following logical formula:

 e = (c1 c2 ¬b1 ¬b2) r1 r2 ¬i1 ¬i2  ,

where:

cis stand for Causes

bis stand for Barriers

ris stand for Requirements

iis stand for Inhibitors

For the effect e to happen, all ris need to be present (one of them absent can bring down the effect) and all iis have to be absent (one of them present can bring down the effect). Any ci or bi can cause y but bi work through their absent state, i.e., their absence can affect e. bi are just negated cis and iis are just negated ris.

The DeMorgan gate is a canonical interaction model, similar to the Noisy-OR and Noisy-AND gates. In order for the DeMorgan model to be applicable in practice, the following conditions have to be fulfilled (see also Diez & Druzdzel 2006).

There should be a causal mechanism for each parent such that the parent is able to impact the child variable in the absence of the other anomalies. If co-occurrence of two or more parents is necessary to impact the child, the model may not be suitable. Please note that the impact is different between Causes/Barriers and Requirements/Inhibitors but each of them is capable of impacting the child variable in separation of other parent variables.

Are the causal mechanisms independent? This is quite likely the hardest condition to verify, because our knowledge of the domain may not be precise enough to verify that the causal mechanisms in question do not interact with one another. In practice, however, unless there are known interactions, it is not unreasonable to assume that independence of causal influences (also known as the ICI condition) holds and the model can be applied. Should this condition not hold, it is typically possible to restructure the model in such a way that the ICI condition is approximately satisfied.

In case of existence of other, unmodeled causes (a non-zero Leak parameter), are these unmodeled causes independent of all parents of the effect variable? Typically, we assume that this condition holds unless there is evidence against it. In statistical modeling, this condition is often referred to as "independence of error terms."

We should keep in mind that the above conditions have to be satisfied approximately, as the modeling effort involving QGeNIe graphs is an attempt to approximate reality and the methodology is robust to minor violations of assumptions.

 

Parameter Elicitation

Of essence to model builders are the questions that are asked of an expert when eliciting the parameter for each link type. These questions have to be clear so as to obtain reliable parametrization.

It is important to realize that the DeMorgan model is an Independence of Causal Influences (ICI) model. A prominent member of the ICI family is the Noisy-OR model (Pearl 1988, Henrion 1989). This means in practice that the parents influence the child independently of each other. Influence of each parent can be specified in separation from the influences of the remaining parents. When specifying the influence of a single parent on the child, it is assumed that each remaining parent is in its "distinguished state." The distinguished state is the state in which the parent has no effect on the child. Because the effects of the four types of parents are different, their distinguished states are also different. In our experience, this leads to considerable confusion among QGeNIe users, so we would like to discuss this on an example and caution the readers to be very careful in selecting the distinguished state of any node during parameter elicitation.

Cause

The distinguished state of a cause is the state in which the cause has no effect on the child. In QGeNIe, it is always the state False. For example, Not being a smoker has no effect on Lung cancer in the example introduced above. Not being a smoker is the distinguished state in this interaction. So is Having no cancer.

Barrier

The distinguished state of a barrier is also the state in which the cause has no effect on the child. In QGeNIe, it is always the state True. For example, regular Exercise may be thought as not influencing the risk of Heart disease, and so it is the distinguished state in this interaction. So is No heart disease in the child node.

Requirement

The distinguished state of a requirement is the state that is necessary for the effect to take place at all. For example, Being a female is a requirement for becoming pregnant and it is the distinguished state in this interaction. In QGeNIe, it is always the state True. No pregnancy is the distinguished state of the child node.

Inhibitor

The distinguished state of an inhibitor is the state that has no effect on the child, i.e., the inhibiting factor being absent. In QGeNIe, it is always the state False. For example, Rain is an inhibitor of Wild land fire. Its distinguished state is No rain, which does not influence the wild land fire.

 

Now, for each type of interaction, the parameter pi associated with a link from a Cause or a Barrier i corresponds to the probability of the effect e happening if all parents  are in their distinguished states (i.e., not acting upon e) and node i is not in its distinguished state. The parameter pi associated with a link from a Requirement or an Inhibitor i corresponds to the probability of the effect e not happening if all parents  are in their distinguished states (i.e., not acting upon e) and node i is not in its distinguished state. There is also an additional parameter, called Leak which expresses the probability of the effect given that all parents are in their distinguished states. Rather than stating the questions to the expert in the abstract, we explain them based on a simple example model below.

 

Example 1

Consider the following network based on the DeMorgan gate with two causes (Pneumonia and Flu), one barrier (Bodily Temperature Balance), one requirement (Being Alive), and two inhibitors (Aspirine Intake and Tylenol Intake):

fever

We list questions for each of the causes in the above model with references to the states of all causes underlined for more clarity.

The "leak" parameter

In order to elicit the leak parameter (0.01 in the above figure), the knowledge engineer has to ask the following question: What is the probability of fever if an alive patient with bodily temperature balance, has neither pneumonia nor flu, and has taken neither aspirin nor Tylenol? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_leak

Please note that all causes in the screen shot below are instantiated to F, the barrier is instantiated to T, requirement to T, and inhibitors to F. The conditions in the question include reference to the distinguished states of each of the causes of Fever. The leak expresses the probability that fever happens due to other, unmodeled causes.

We list questions for each of the causes in the above model with references to the states of all causes underlined for more clarity.

Causes

Questions asking for the causal strength of a cause C of the node Fever are framed in such a way that only C is present and all other variables are in their distinguished states.

In order to elicit the strength of the influence of the node Pneumonia on Fever (0.9 in the figure), the knowledge engineer has to ask the following question: What is the probability of fever if an alive patient with bodily temperature balance, has pneumonia but no flu, and has taken neither aspirin nor Tylenol and no other unmodeled causal factors that may influence fever are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_pneumonia

In order to elicit the strength of the influence of the node Flu on Fever (0.6 in the figure), the knowledge engineer has to ask the following question: What is the probability of fever if an alive patient with bodily temperature balance, has flu but no pneumonia, and has taken neither aspirin nor Tylenol and no other unmodeled causal factors that may influence fever are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_flu

Barrier

Questions asking for the causal strength of a barrier B of the node Fever is framed in such as way that only B is absent (please note that the distinguished state of a barrier is its presence, which does not impact the effect) and all other causes and barriers are in their distinguished states.

In order to elicit the strength of the influence of the node Bodily Temperature Balance on Fever (0.6 in the figure), the knowledge engineer has to ask the following question: What is the probability of fever if an alive patient with abnormal temperature balance, who has neither flu nor pneumonia, and has taken neither aspirin nor Tylenol and no other unmodeled causal factors that may influence fever are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_balance

Requirement

Questions asking for the causal strength of a requirement B of the node Fever is framed in such as way that only B is absent (please note that the distinguished state of a barrier is its presence, which does not impact the effect) and all other causes and barriers are in their distinguished states.

In order to elicit the strength of the influence of the node Being Alive on Fever (0.98 in the figure - please note that we allow for a patient to be just dead, with the body temperature still being high), the knowledge engineer has to ask the following question: What is the probability of no fever in a dead patient with abnormal temperature balance, who has both flu and pneumonia, and has taken neither aspirin nor Tylenol and no other unmodeled causal factors that may influence fever are present? Please note that in this case all causes and barriers have to be in active (rather than distinguished) state and the question is asking for the probability of no fever! This is just the effect that requirements interact with other causes through the AND function. QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_alive

Inhibitors

In order to elicit the strength of the influence of the node Aspirine Intake on Fever (0.6 in the figure), the knowledge engineer has to ask the following question: What is the probability of no fever if an alive patient with abnormal temperature balance, who has both flu and pneumonia, and has taken aspirin but not Tylenol and no other unmodeled causal factors that may influence fever are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_aspirine

In order to elicit the strength of the influence of the node Tylenol Intake on Fever (0.9 in the figure), the knowledge engineer has to ask the following question: What is the probability of no fever if an alive patient with abnormal temperature balance, who has both flu and pneumonia, and has taken Tylenol but not aspirin and no other unmodeled causal factors that may influence fever are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fever_tylenol

Please note that in both cases all causes and barriers have to be in active (rather than distinguished) state and the question is asking for the probability of no fever! This is just the effect that inhibitors interact with other causes through the AND function.

Each of the above questions can be adjusted to the needs of particular context, i.e., things can be rephrased or omitted if they do not make sense.

Example 2

Consider the following network based on the DeMorgan gate with one cause (Fire Spreads Quickly), one barrier (Fire Escapes Are Accessible), one requirement (People Are Still In the Building), and one inhibitor (Fire Is Quickly Controlled):

fire

The "leak" parameter

In order to elicit the leak parameter (0.05 in the above figure), the knowledge engineer has to ask the following question: What is the probability of casualties if the fire does not spread quickly, fire escapes are accessible, people are still in the building, and fire is not quickly controlled? Please note that the conditions in the question include reference to the distinguished states of each of the causes of There Are Casualties. The leak expresses the probability that casualties happen due to other, unmodeled causes. QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fire_leak

Cause

Question asking for the causal strength of a cause C of the node There Are Casualties is framed in such as way that only C is present and all other variables are in their distinguished state.

In order to elicit the strength of the influence of the node Fire Spreads Quickly on There Are Casualties (0.33 in the figure), the knowledge engineer has to ask the following question: What is the probability of casualties if the fire spreads quickly, fire escapes are accessible, people are still in the building, fire is not quickly controlled, and no other unmodeled causal factors are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fire_cause

Barrier

In order to elicit the strength of the influence of the node Fire Escapes Are Accessible on There Are Casualties (0.66 in the figure), the knowledge engineer has to ask the following question: What is the probability of casualties if the fire does not spread quickly, fire escapes are not accessible, people are still in the building, fire is not quickly controlled, and no other unmodeled causal factors are present? QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fire_barrier

Requirement

In order to elicit the strength of the influence of the node People Are Still In the Building on There Are Casualties (0.88 in the figure), the knowledge engineer has to ask the following question: What is the probability of no casualties if the fire spreads quickly, fire escapes are not accessible, there are no people in the building, fire is not quickly controlled, and no other unmodeled causal factors are present? Please note that in this case all causes and barriers have to be in active (rather than distinguished) state and the question is asking for the probability of no casualties! This is just the effect that requirements interact with other causes through the AND function. QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fire_requirement

Inhibitor

In order to elicit the strength of the influence of the node Fire Is Quickly Controlled on There Are Casualties (0.75 in the figure), the knowledge engineer has to ask the following question: What is the probability of no casualties if the fire spreads quickly, fire escapes are not accessible, there are people in the building, fire is quickly controlled, and no other unmodeled causal factors are present? Please note that in this case all causes and barriers have to be in active (rather than distinguished) state and the question is asking for the probability of no casualties! This is just the effect that requirements interact with other causes through the AND function. QGeNIe helps in the elicitation process by dimming the entire model except for the nodes involved and marking the nodes with the states that should be stated in the question.

fire_inhibitor

Each of the above questions can be adjusted to the needs of particular context, i.e., things can be rephrased or omitted if they do not make sense.