integ(x*cos(x), x, [0,1])
1) Let's compute the integral: ∫01x·cos(x)dx
⇥For x·cos(x), we use integration by parts: ∫u1·v2'dx = u1·v2 -∫u1'·v2dx, with u1 = x and v2' = cos(x)
⇥So u1' is equal to 1
⇥1.1) Let's compute the integral v2': ∫cos(x)dx
⇥ⓘ Differentiating sin(x) gives cos(x), so sin(x) is an antiderivative of cos(x): ∫cos(x)dx = sin(x)
⇥ sin(x)
⇥1.2) Let's evaluate u1·v2 -∫u1'·v2dx: x·sin(x) -∫sin(x)dx
⇥ⓘ The derivative of cos(x) is -sin(x), so cos(x) is an antiderivative of -sin(x): -∫sin(x)dx = cos(x)
⇥ x·sin(x) + cos(x)
Then you can resume the integral computation:
ⅰ ∫x·cos(x)dx = x·sin(x) + cos(x)
▷ x·sin(x) + cos(x)
2) Let's evaluate for the interval [0, 1]: (1·sin(1) + cos(1)) -(0·sin(0) + cos(0))
ⓘ With a minus sign before parentheses, change the sign of every term inside: -(0·sin(0) + cos(0)) = 0·sin(0) -cos(0)
sin(1) + cos(1) + 0·sin(0) -cos(0)
ⓘ If a factor is zero, the product is zero: 0·sin(0) = 0■The cosine is the x-coordinate (horizontal axis) of the point reached on the unit circle after a rotation of 0 radians from the horizontal axis pointing to the right, this is a remarkable value: -cos(0) = -1
sin(1) + cos(1) + 0 -1
ⓘ Adding 0 changes nothing: 0 -1 = -1
sin(1) + cos(1) -1
▶Integral:   cos(1) + sin(1) -1
3) The numeric value of: cos(1) + sin(1) -1 equals:
ⓘ The cosine is the x-coordinate (horizontal axis) of the point reached on the unit circle after a rotation of 1 radians from the horizontal axis pointing to the right■The sine is the y-coordinate (vertical axis) of the point reached on the unit circle after a rotation of 1 radians from the horizontal axis pointing to the right
≈ 0.5403 + ≈ 0.8415 -1
≈ 1.3818 -1
▷ ≈ 0.3818