<< lognormal Distribution Functions negbinomial >>

sci_gsl >> sci_gsl > Distribution Functions > logth

logth

Logarithmic Distribution

Syntax

y = logth(p,k,c)

Parameters

y:

output

p:

probabiliy of success

k:

k is an integer greater than equal to 1.

c = 1:

It will allow the user to generate a logarithmic random variate with probability of success p. In this case the function is independent of k and hence any value of k can be set.

c >=2:

It will allow the user to compute the probability p(k) of obtaining k from a logarithmic distribution with probability of success p.

Description

This function is used to calculate logarithmic random variate and probability p(k) of obtaining k from a logarithmic distribution with parameter p.

Examples

// probability p(k) of obtaining k=1 from a logarithmic  distribution with p=0.7.
p=0.7
k=1
c=2
y = logth(p,k,c)
disp(y)

Authors


Report an issue
<< lognormal Distribution Functions negbinomial >>