Go to CCP Homepage

Go to Materials Page

Go to Multivariate Calculus Materials

Go to Table of Contents

Go Back One Page

Go Forward One Page

Mathematica Tutor

Part 10: Integration

  1. First we calculate indefinite integrals. If necessary, unassign x:
    x=.

    Then enter
    Integrate[x*Sin[x],x]


    Check that the result is an antiderivative of x sin(x):
    Enter

    D[%,x]

  2. Now try to find an antiderivative for sin(x3 + x5). Mathematica does not know an antiderivative of this function that may be defined in terms of functions known to it. On the other hand, try
    Integrate[Sin[x^2], x]
    The Fresnel S function is known to Mathematica, but probably not to you. However, you can check by differentiation that the expression is an antiderivative.

  3. Next we calculate definite integrals. To integrate x sin(x) over the interval [0,pi/2], enter
    Integrate[x*Sin[x], {x, 0, Pi/2}]

  4. Now try this method on the integral of sin(x3+x5) over the interval [0,pi/2]. Mathematica still doesn't know an antiderivative for sin(x3+x5). To obtain a numerical estimate, enter
    N[Integrate[Sin[x^3 + x^5], {x, 0, Pi/2}]]

    If you know that all you want is a numerical estimate, you can enter
    NIntegrate[Sin[x^3 + x^5], {x, 0, Pi/2}]
    The significance of using the NIntegrate function is that Mathematica does not try to find a symbolic solution before starting on the numerical estimate.

  5. Use Mathematica to find the exact value of each of the following integrals. (Type Infinity with a capital I for the infinity symbol.)

    • The integral of 1/(1+x2) from 0 to 1,

    • The integral of 1/(1+x2) from 0 to Infinity,

    • The integral of 1/(1+x4) from 0 to Infinity.

Note: In modern versions of Mathematica , you have access to several palettes. These palettes simplify the creation of many common Mathematica commands. The BasicInput Palette is particularly useful for setting up integrals. The use of these palettes is described in the Appendix.

Go to CCP Homepage

Go to Materials Page

Go to Multivariate Calculus Materials

Go to Table of Contents

Go Back One Page

Go Forward One Page


modules at math.duke.edu

Copyright CCP and the author(s), 1998, 1999, 2000