Alright, let's start by sketching the area, let's just superimpose each curve so we can see where they all intersect. First, let's just label the following:
`y = 3cos(4x) ->`Blue
`y = 3sin(8x)->`Red
`x = 0->`Green
`x = pi/8->`Orange
Based on this graph, we can clear out a lot of the extraneous parts of the graph, so that we only get the parts bounded by the curves:
So, we have two regions separated by the point of intersection between the red and blue curves. Another way to think of finding this area based on integrals is that we're going to subtract the area under the higher curve from the area of the lower curve. Notice that the curves switch between being higher and lower after intersecting.
In fact, the best--most general--way to think of this is to recognize that the area between the curves will be the integral of the absolute value of the difference between the functions taken over the domain determined by the curves `x = 0` and `x = pi/8`:
`A = int_0^(pi/8) |3cos(4x) - 3sin(8x)| dx`
So, how do you integrate the absolute value? We have to look at where the inside of the absolute value will be positive and when it will be negative. The easiest way to do this? Look at the graph! When the blue curve (`y = 3cos(4x)`) is above the red curve (`y = 3sin(8x)`), then the difference will be positive. When the red curve is above the blue, the difference will be negative.
So, our absolute value becomes two different things depending on whether or not we've reached the point of intersection. Before the point, we get:
`|3cos(4x) - 3sin(8x)| = 3cos(4x) - 3sin(8x)`
However, after the point of intersection, we get:
`|3cos(4x) - 3sin(8x)|=3sin(8x) - 3cos(4x)`
So, our equation becomes (if we let the x-value of the point of intersection be `a`):
`A = int_0^a 3cos(4x) - 3sin(8x) dx + int_a^(pi/8) 3sin(8x)-3cos(4x) dx`
In order to solve this completely, we need to find that value for `a`! In other words, we need to solve for the x-values for where the two functions are equal:
`3cos(4a) = 3sin(8a)`
Divide by 3:
`cos(4a) = sin(8a)`
Now, remember, we can convert from sine to cosine with the following identity:
Now, we can just set the expressions inside the sine equal to each other!
`pi/2-4a = 8a`
So, adding `4a`:
`pi/2 = 12a`
Now, we can divide by 12 to find `a`:
`a = pi/24`
There are other identities that will work here, but they yield either `a=pi/8` (which is trivial because we know the curves intersect there at `y=0` based on our graph) and `a=pi/24` (for which we just solved).
So, let's replace `a` in our integral:
`A = int_0^(pi/24)3cos(4x) - 3sin(8x) dx + int_(pi/24)^(pi/8) 3sin(8x) - 3cos(4x)dx`
Now, let's solve each integral independently by using standard trigonometric integrals (see link below):
`A = (3/4sin(4x) +3/8cos(8x))|_0^(pi/24) + (-3/8cos(8x) -3/4sin(4x))|_(pi/24)^(pi/8)`
Now, we can evaluate:
`A = 3/4sin(pi/6) + 3/8cos(pi/3) - 3/4sin(0) - 3/8cos(0) - 3/8cos(pi) - 3/4sin(pi/2) + 3/8cos(pi/3)+3/4sin(pi/6))`
We can actually fully evaluate these trigonometric functions because the sines and cosines of thirds and sixths of pi are easily found analytically:
`A = 3/4(1/2) + 3/8(1/2) - 0 - 3/8 + 3/8 - 3/4 +3/8*1/2+3/4*1/2`
Combining and simplifying, we get our area to be:
And there you have it! It's a long process of adding integrals together, but all you're doing is simply finding the difference in area between each curve and the x-axis (the difference in the integrals).
I hope that helps!