Mathematica Defining a constant in Mathematica

Click For Summary
The discussion centers on calculating the expected value of a Gumbel distribution using integration. The user is attempting to integrate the function involving the Gumbel distribution parameters a and b but encounters complications when not using specific values for a and b. While the integration works smoothly with a = 2 and b = 5, it results in a complex expression for other values. Suggestions include applying additional assumptions to the variables, such as setting a as a real number, to simplify the integration process. The focus is on finding a solution that allows for a more general application of the expected value calculation without leading to overly complex expressions.
ToxicBug
Messages
84
Reaction score
0
Hello, I've been breaking my head over this for a couple hours now.

I'm trying to find the expected value of a Gumbel distribution.
Code:
Integrate[ y*E^(-((y - a)/b))*E^(-E^(-((y - a)/b)))/b, {y, -Infinity, Infinity},
  Assumptions -> b > 0]

If I set a = 2 and b = 5, it works. Otherwise it gives me a very complicated expression. I've tried SetAttributes[a, Constant], but it doesn't do the trick. Anyone know how can I solve this?
 
Physics news on Phys.org
Try giving it some information about a, like
Code:
Assumptions -> b > 0 && Element[a, Reals]
 

Similar threads

  • · Replies 12 ·
Replies
12
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
6K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 5 ·
Replies
5
Views
5K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K