Tuesday, June 16, 2026
HomeLanguagessympy.stats.Gumbel() in python

sympy.stats.Gumbel() in python

With the help of sympy.stats.Gumbel() method, we can get the continuous random variable which represents the gumbel distribution.

Syntax : sympy.stats.Gumbel(name, beta, mu, minimum=False)
Where, If we set minimum is True than we can enable minimum distribution.
Return : Return the continuous random variable.

Example #1 :
In this example we can see that by using sympy.stats.Gumbel() method, we are able to get the continuous random variable representing gumbel distribution by using this method.




# Import sympy and gumbel
from sympy.stats import Gumbel, density
from sympy import Symbol, pprint
  
z = Symbol("z")
mu = Symbol("mu")
beta = Symbol("beta", positive = True)
  
# Using sympy.stats.Gumbel() method
X = Gumbel("x", beta, mu)
gfg = density(X)(z)
  
pprint(gfg)


Output :

-(-mu + z)
———–
beta -mu + z
– e – ——-
beta
e
————————-
beta

Example #2 :




# Import sympy and gumbel
from sympy.stats import Gumbel, density
from sympy import Symbol, pprint
  
z = 0.4
mu = 2
beta = 4
  
# Using sympy.stats.Gumbel() method
X = Gumbel("x", beta, mu)
gfg = density(X)(z)
  
pprint(gfg)


Output :

0.0839008899108612

Dominic
Dominichttp://wardslaus.com
infosec,malicious & dos attacks generator, boot rom exploit philanthropist , wild hacker , game developer,
RELATED ARTICLES

Most Popular

Dominic
32516 POSTS0 COMMENTS
Milvus
131 POSTS0 COMMENTS
Nango Kala
6897 POSTS0 COMMENTS
Nicole Veronica
12013 POSTS0 COMMENTS
Nokonwaba Nkukhwana
12109 POSTS0 COMMENTS
Shaida Kate Naidoo
7019 POSTS0 COMMENTS
Ted Musemwa
7262 POSTS0 COMMENTS
Thapelo Manthata
6976 POSTS0 COMMENTS
Umr Jansen
6964 POSTS0 COMMENTS