Fix memory errors

This commit is contained in:
Isaac Shoebottom 2024-02-17 21:24:22 -04:00
parent 3816763622
commit 3426d4575c
2 changed files with 33 additions and 37 deletions

View File

@ -259,33 +259,31 @@ def pd_from(x, l):
def man(): def man():
""" """
Prints the manual for the module. Prints the manual for the module.
Formatted this way to fit in memory on the calculator.
""" """
print( print("This module contains functions for computing the total probability of events.")
""" print("The functions are:")
This module contains functions for computing the total probability of events. print("bnd(x, n, p) - The binomial distribution")
The functions are: print("bnd_mean(n, p) - The mean of the binomial distribution")
bnd(x, n, p) - The binomial distribution print("bnd_var(n, p) - The variance of the binomial distribution")
bnd_mean(n, p) - The mean of the binomial distribution print("bnd_std(n, p) - The standard deviation of the binomial distribution")
bnd_var(n, p) - The variance of the binomial distribution print("bnd_upto(x, n, p) - The cumulative probability of getting upto x successes in n trials")
bnd_std(n, p) - The standard deviation of the binomial distribution print("bnd_from(x, n, p) - The cumulative probability of getting from x successes in n trials")
bnd_upto(x, n, p) - The cumulative probability of getting upto x successes in n trials print("gd(x, p, q) - The geometric distribution")
bnd_from(x, n, p) - The cumulative probability of getting from x successes in n trials print("gd_mean(p) - The mean of the geometric distribution")
gd(x, p, q) - The geometric distribution print("gd_var(p) - The variance of the geometric distribution")
gd_mean(p) - The mean of the geometric distribution print("gd_std(p) - The standard deviation of the geometric distribution")
gd_var(p) - The variance of the geometric distribution print("gd_upto(x, p, q) - The cumulative probability of getting upto x trials until the first success")
gd_std(p) - The standard deviation of the geometric distribution print("gd_from(x, p, q) - The cumulative probability of getting from x trials until the first success")
gd_upto(x, p, q) - The cumulative probability of getting upto x trials until the first success print("hgd(x, N, n, k) - The hyper geometric distribution")
gd_from(x, p, q) - The cumulative probability of getting from x trials until the first success print("hgd_mean(N, n, k) - The mean of the hyper geometric distribution")
hgd(x, N, n, k) - The hyper geometric distribution print("hgd_var(N, n, k) - The variance of the hyper geometric distribution")
hgd_mean(N, n, k) - The mean of the hyper geometric distribution print("hgd_std(N, n, k) - The standard deviation of the hyper geometric distribution")
hgd_var(N, n, k) - The variance of the hyper geometric distribution print("hgd_upto(x, N, n, k) - The cumulative probability of getting upto x successes in n draws from a population of size N with k successes")
hgd_std(N, n, k) - The standard deviation of the hyper geometric distribution print("hgd_from(x, N, n, k) - The cumulative probability of getting from x successes in n draws from a population of size N with k successes")
hgd_upto(x, N, n, k) - The cumulative probability of getting upto x successes in n draws from a population of size N with k successes print("pd(x, l) - The poisson distribution")
hgd_from(x, N, n, k) - The cumulative probability of getting from x successes in n draws from a population of size N with k successes print("pd_mean(l) - The mean of the poisson distribution")
pd(x, l) - The poisson distribution print("pd_var(l) - The variance of the poisson distribution")
pd_mean(l) - The mean of the poisson distribution print("pd_std(l) - The standard deviation of the poisson distribution")
pd_var(l) - The variance of the poisson distribution print("pd_upto(x, l) - The cumulative probability of getting upto x occurrences")
pd_std(l) - The standard deviation of the poisson distribution print("pd_from(x, l) - The cumulative probability of getting from x occurrences")
pd_upto(x, l) - The cumulative probability of getting upto x occurrences
pd_from(x, l) - The cumulative probability of getting from x occurrences
""")

View File

@ -37,11 +37,9 @@ def man():
""" """
Prints the manual for the module. Prints the manual for the module.
""" """
print(""" print("This module contains functions for computing the total probability of events.")
This module contains functions for computing the total probability of events. print("The functions are:")
The functions are: print("i(A, B) - The intersection of A and B")
i(A, B) - The intersection of A and B print("u(A, B) - The union of A and B")
u(A, B) - The union of A and B print("g(A, B) - The conditional probability of A given B")
g(A, B) - The conditional probability of A given B print("n(A) - The negation of A")
n(A) - The negation of A
""")