Suppose i have an integral which has a closed form,

$\quad \quad \int_{a}^{b} f(x) dx=F(a,b)$

I want to use output function $F$ as a pure function, like F[a,#]& so i try the following:

Integrate[f[x], {x, a, #}]&;

but this does not evaluate the integral before setting it as a pure function. So I tried the following:

Integrate[f[x], {x, a,b}];
(% /. {b -> #})&;

but this doesnot evaluate the last result variable %. So I also tried the following to no success:

Integrate[f[x], {x, a, #}]

In the maple programming language there is a command "unapply" which evaluates the definition of the function before assigning the arrow operator to it. Is there any equivalent to this in Mathematica? (I am new to Mathematica)


1 Answer 1


Not sure how general solution you want but you can do something like:

Evaluate[Integrate[f[x], {x, a, b}] /. b -> (#)] &
  • $\begingroup$ Thank you that's general enough for me. $\endgroup$
    – user13892
    Apr 18, 2015 at 18:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.