Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Defining a constant in Mathematica

  1. Mar 24, 2009 #1
    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 (Text):

    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?
  2. jcsd
  3. Mar 24, 2009 #2


    User Avatar
    Science Advisor
    Homework Helper

    Try giving it some information about a, like
    Code (Text):
    Assumptions -> b > 0 && Element[a, Reals]
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Similar Discussions: Defining a constant in Mathematica