Integrating over piecewise functions

In summary, if a function f(x) is piecewise smooth on an interval except at N-1 points, the integral of its derivative over that interval may require the use of multiple integrals, depending on the behavior of the derivative at the discontinuities. Additionally, if f(x) is piecewise smooth, then its derivative f'(x) is at least piecewise continuous, but may not necessarily be piecewise smooth.
  • #1
member 428835
given a function [itex]f(x)[/itex] that is piecewise smooth on interval [itex]-L<x<L[/itex] except at [itex]N-1[/itex] points, is [itex]\int_{-L}^L f'(x)dx [/itex] legal or would i have to [tex]\sum_{i=1}^N \int_{x_i}^{x_{i+1}} f'(x)dx‎‎[/tex]
where [itex]x_{N+1}=L[/itex] and [itex]x_{1}=-L[/itex]

also, am i correct that if [itex]f(x)[/itex] is piecewise smooth, then [itex]f'(x)[/itex] is piecewise continuous but not necessarily piecewise smooth?

thanks in advance!
 
Physics news on Phys.org
  • #2
joshmccraney said:
given a function [itex]f(x)[/itex] that is piecewise smooth on interval [itex]-L<x<L[/itex] except at [itex]N-1[/itex] points, is [itex]\int_{-L}^L f'(x)dx [/itex] legal or would i have to [tex]\sum_{i=1}^N \int_{x_i}^{x_{i+1}} f'(x)dx‎‎[/tex]
where [itex]x_{N+1}=L[/itex] and [itex]x_{1}=-L[/itex]
The latter. Suppose for example that ##f(x) = |x|^{1/2}##. This is smooth (infinitely differentiable) everywhere except at ##x = 0##, and
$$f'(x) = \begin{cases}
\frac{1}{2|x|^{1/2}} & \textrm{ if }x > 0 \\
\frac{-1}{2|x|^{1/2}} & \textrm{ if }x < 0 \\
\end{cases}$$
As ##f'## is unbounded on ##[-L,L]##, it's necessary to use two (improper) integrals to integrate it:
$$\lim_{a \rightarrow 0^-} \int_{-L}^{a} f'(x) dx + \lim_{b \rightarrow 0^+}\int_{b}^{L} f'(x) dx$$
Both limits exist and the answers have opposite signs, so the result is 0.
also, am i correct that if [itex]f(x)[/itex] is piecewise smooth, then [itex]f'(x)[/itex] is piecewise continuous but not necessarily piecewise smooth?
Assuming "smooth" means infinitely differentiable, ##f'## will be piecewise smooth. If by "smooth" you merely mean (once) differentiable, then ##f'## is not necessarily even piecewise continuous.
 
  • #3
thanks for the reply. think i have it now.
 

1. What are piecewise functions?

Piecewise functions are functions that are defined by different formulas for different intervals or "pieces" of the input domain. This means that the function can have different rules for different parts of its domain, allowing for more flexibility in representing real-world situations.

2. How do you integrate over piecewise functions?

To integrate over a piecewise function, you must break the integral into smaller integrals that correspond to each piece of the function. You will then use the appropriate integration technique for each piece and add the resulting integrals together to get the final answer.

3. Can piecewise functions be integrated using the fundamental theorem of calculus?

Yes, piecewise functions can be integrated using the fundamental theorem of calculus as long as the function is continuous on each piece and has a well-defined derivative. This means that the function must have the same value from both the left and right side at the points where the pieces meet.

4. How do you handle discontinuities when integrating over piecewise functions?

If there is a discontinuity in the piecewise function, you will need to break the integral at that point and treat each piece separately. You may also need to use different integration techniques for each piece, depending on the type of discontinuity.

5. Are there any special cases to consider when integrating over piecewise functions?

Yes, there are some special cases to consider when integrating over piecewise functions. One example is when the pieces of the function have different domains, in which case you will need to adjust the limits of integration accordingly. Another case is when the function has a vertical asymptote, in which case you will need to split the integral into smaller intervals around the asymptote and use specific integration techniques for each piece.

Similar threads

Replies
16
Views
2K
Replies
7
Views
1K
Replies
4
Views
720
Replies
1
Views
902
  • Calculus
Replies
13
Views
1K
Replies
24
Views
2K
Replies
3
Views
957
Replies
3
Views
1K
Replies
3
Views
1K
Back
Top