Algorithms_in_C++ 1.0.0
Set of algorithms implemented in C++.
|
Addition rule of probabilities. More...
#include <iostream>
Functions | |
double | addition_rule_independent (double A, double B) |
double | addition_rule_dependent (double A, double B, double B_given_A) |
int | main () |
Addition rule of probabilities.
double addition_rule_dependent | ( | double | A, |
double | B, | ||
double | B_given_A ) |
Calculates the probability of the events A or B for dependent events note that if value of B_given_A is unknown, use chainrule to find it \parama [in] A probability of event A \parama [in] B probability of event B \parama [in] B_given_A probability of event B condition A
double addition_rule_independent | ( | double | A, |
double | B ) |
calculates the probability of the independent events A or B for independent events \parama [in] A probability of event A \parama [in] B probability of event B
int main | ( | void | ) |
Main function