6
$\begingroup$

Consider for example the Exponential distribution with c.d.f. $F(x) = 1-e^{-\lambda x}$.

$F^{-1}(x)$ would be inverse cdf (quantile function). If I generate y=F−1(x) with x uniformily distributed on [0,1], then y will follow..

If I generate $y = F^{-1}(x)$ with x uniformly distributed on $0 \lt x \lt 1$, then y will follow the specific distribution.

So I have an idea but i don't know if it is realizable:

For different values of x, where $0 \lt x \lt 1$, if we can get 1000 random numbers with the equation, $y= F^{-1}(x)$. (lets assume, we get 10,4,5,77,2,11,10,....). Can we generate this 1000 random values in interval (for example) 0-100? Hence, whether it is possible to generate random numbers "inside an interval" for exponential (and other distributions, in particular Zipf distribution).

UPDATE: If we consider the Zipf Distribution that has (from Wikipedia): $$ pdf(x) = \frac{1}{x^s \times H_{N,s}} $$ $$ cdf(x) = \frac{H_{x,s}}{H_{N,s}} $$

where $s \gt 0$ is the scale parameter, H is the Harmonic number $H_{N,s} = \sum_{i=1}^N \frac{1}{i^s}$

How can i generate a random generator "inside an interval" (for example from 1 to 100)? Thank you

  • 0
    Question is unclear for me. 1. By $F^-(x)$ you mean $F^{-1}(x)$? 2. "If I assume... " should read: "If I generate $y=F^{-1}(x)$ with $x$ uniformily distributed on [0,1], then $y$ will follow..." 3. The final paragraph is confusing; do you want to generate values restricted to an interval? ("within a limit" means "inside an interval"??) That would amount to generate random numbers following a modified (truncated) density. – 2011-07-15
  • 1
    yes you are right, i'm sorry the english is not my motherlanguage. I modified the question: it is as you 've already understood. – 2011-07-15

2 Answers 2