release
Evaluate integrals
Syntax
Description
Examples
Unevaluated Integral
Define a symbolic call to an integral without evaluating it. Set the 'Hold'
option to true when defining the integral using the int
function.
syms x F = int(cos(x),'Hold',true)
F =
Use release
to evaluate the integral by ignoring the 'Hold'
option.
G = release(F)
G =
Unevaluated Integral and Integration by Parts
Find the integral of .
Define the integral without evaluating it by setting the Hold
option to true
.
syms x g(y) F = int(x*exp(x),Hold=true)
F =
You can apply integration by parts to F
by using the integrateByParts
function. Use exp(x)
as the differential to be integrated.
G = integrateByParts(F,exp(x))
G =
To evaluate the integral in G
, use the release
function to ignore the Hold
option.
Gcalc = release(G)
Gcalc =
Compare the result to the integration result returned by int
without setting the Hold
option.
Fcalc = int(x*exp(x))
Fcalc =
Integration by Substitution
Find the integral of using integration by substitution.
Define the integral without evaluating it by setting the 'Hold'
option to true
.
syms x t F = int(cos(log(x)),'Hold',true)
F =
Substitute the expression log(x)
with t
.
G = changeIntegrationVariable(F,log(x),t)
G =
To evaluate the integral in G
, use the release
function to ignore the 'Hold'
option.
H = release(G)
H =
Restore log(x)
in place of t
.
H = simplify(subs(H,t,log(x)))
H =
Compare the result to the integration result returned by int
without setting the 'Hold'
option to true
.
Fcalc = int(cos(log(x)))
Fcalc =
Input Arguments
expr
— Expression containing integrals
symbolic expression | symbolic function | symbolic vector | symbolic matrix
Expression containing integrals, specified as a symbolic expression, function, vector, or matrix.
Version History
Introduced in R2019b
See Also
Comando MATLAB
Hai fatto clic su un collegamento che corrisponde a questo comando MATLAB:
Esegui il comando inserendolo nella finestra di comando MATLAB. I browser web non supportano i comandi MATLAB.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)