Showing posts with label integral. Show all posts
Showing posts with label integral. Show all posts

Saturday, January 4, 2014

On integrating and finally integrating

I wish I could explain how satisfying it is to finally learn the concepts of integration in calculus. For years I have seen how people would represent calculus with a picture of a curved function with the area under it shaded, and for the life of me, I could not figure out how they would calculate that. Now I know. The relative simplicity of the process has a ring of truth, and symmetry, and beauty that threw me back to discovering geometrical theorems in high school.

Well, here it goes: Integrals as I understood them.

Imagine you have a formula that is continuous at least for a given interval [a,b]. I chose again x2 in the closed interval form 1 to 2. I already tried to find the area under that curve in my post on Sigma.

By using 10 rectangles of width 1/5 and height x2, I was able to approximate the area under the curve to be 2.28 square units an underestimation of the true area. However, I posted that I could get better approximations if my rectangles had been infinitely small.

To get those better approximations I need to improve the sum I used before, pictured to the right. And in order to do that, I would need to convert it into a Riemman Sum.

The toughest part of doing integration is to set up the correct Riemman Sum for the purposes intended. I struggled so hard with this part that I want to give you this video to follow just in case I mess up. Here is the general formula for a Riemman Sum:

Since I am doing a right Riemman Sum, I will use this version of the formula. Where a and b are the interval of my function, and n represents the times I will be cutting that interview. A right Riemman sum will give me an overestimate of the area under the curve, which will complement the underestimate of 2.28 I got

 

The first thing you need to do to set up a Riemman sum is deciding what your interval is (in this case is from 0 to 2) and then decide how wide you want your divisions within that interval to be. I want my intervals to be 1/5 units wide, but that is not important right now, just remember there are ten 1/5 divisions from the interval 0 to 2. Then for the height of my rectangles I chose to evaluate the function x2 on the right hand side of those intervals. With those steps selected then I follow the x2 rules for Riemman Sums.

A Riemman Sum is the addition of the formula I want to evaluate (x2) at the specific cuts I made. The first point on my interval is a=0 and the last point is b=2. I want to divide that interval in n cuts of a certain size. The formula for the cut size is:

Now here is the formula for the height of my rectangles.

So putting all the steps together here is the formula for my Riemman Sum

And that is actually the hard part, for me at least. The rest is arithmetic.

So the answer I got was: 8/3 + 4/n + 4/3n2

But what does that mean? Remember when I said I wanted the width of my rectangles to be 1/5 units and that it meant I would get 10 segments from interval 0 to 2? Well, if you substitute n=10. The area under the curve it gives me is 3.08 square units.

Now since this is a right Riemman sum I know it is an overestimate. My last attempt in the Sigma post was equivalent to a left Riemman sum which gave me an underestimate of 2.28.

If I take the average of these two numbers I should be able to get a better estimate of the area under the curve: (3.08 + 2.28)/2 = 2.68.

And 2.68 is very close to the true area under the curve which is approximately 2.667. Now, how can we get there?

Well supposed that instead of splitting my interval of this Riemman sum into 10 pieces I split it into 100, n=100, what happens then? We get 2.708 instead of 3.08. And what if n=10,000, that would make our rectangles very, very small, we then get 2.670! That is very, very close to 2.667

And what if n=infinity?

Then the n in this formula 8/3 + 4/n + 4/3n2 would be so small (and therefore the width of the rectangles would be also so small) that the only effect relevant in 8/3, and guess what 8/3 comes down to: 2.667 approximately.

 

And what did we just do? We just took a limit.


Whoah! What?!!

Yes, we took the limit of our formula to get the true area under the curve. And that my friends is called integration.

To integrate is to do the following:

To take the limit of the Riemman Sum you are working on as n approaches infinity.

In fact the definite integral is a normally written as a variation of the formula above.

The elongated S just means, take the limit of the sum of f(x) times the change of x from the interval from a to be, as that change of x gets infinetly small.

And there you have it. Integration via the sum of infinite rectangles.

This one was a tough one and there are some considerations to this integrations stuff, but you can review them here.

Let me know what you think in the comments.

 

Wednesday, April 24, 2013

The two questions of Calculus

At last on day 113, I dive in into Calculus. What I write bellow is my interpretation of what I have read me researched. If you are using this post as reference, I suggest you double check my statements. I am by no means a reference source on calculus, just another student trying to learn it.
 
Calculus, from what I have learned far, seems to be the study of change. It deals mostly with two major subjects differentiation and integration. If fact I finds some sources that specifically reference differential calculus versus integral calculus.
 
If I use Professor Edward Burger's approach to explain calculus from one his Thinkwell videos, then calculus is the mathematical discipline created to answer two mayor questions: What is the instantaneous velocity of an object? And What is the area or volume of an exotically-shaped object? The first question is in the realm of diffential calculus and the second belongs to integral calculus.
 
All courses I am reviewing right now, start with differential calculus.
 
In differential calculus I read that the original question that started the discipline was finding the slope of tangent line of a curve. I found this surprising because I remember drawing or working with tangent lines and alopes back in intermediate school geometry. However, when I read deeper I was blown away with the reason the slope of a tangent was such a problem.
 
A tangent is a line that intersects an object, like a circle or a curve, at one (and only one) point. That's the rub. Way back in my geometry class, I learned that you needed at least two points to make a line. The difference between this two point will give us the rise and run of the line, which is its slope. So how can Impossibly find the slope of a tangent line to a curve if a tangent is only one point? The answer, learn calculus. The short answer, and the heart of all calculus it seems, is to find another point in the curve that is sooooooooooooooo close to the first point that the distance between them is infinitesimal and therefore negligible.
In The chart opposite, as point point B in the curve get closer and closer to point A that is also in the curve, the line that passes through them looks more and more like the tangent of the curve.
 
Now imagine the curve actually represents a car's velocity traveling on a straight line. Then point A is we're the car is at time x. In algebra we can find the average velocity between A and B1 by subtracting the miles traveled by the time taken to travel those miles. However, how can I find the exact velocity (Instantaneous velocity) of the car at point A? If I make the time interval between A and B small enough as to make close to an instant, then I can Algebraically compute an approximation of instantaneous velocity.
 
In integral calculus, the questions searched are a little different.
 
What is the area of an exotic shape? And from what I have studied, exotic shapes just mean shapes other than the ones we have formulas for. We have formulas for squares, circles, triangles, cubes, spheres, pyramids and if my memory doesn't fail me, cones. I bet we also have formulas for many other shapes, but how about the area of the shape in the chart below.
 
How do we measure this shape's area?
 
Well, we could inscribe it in a grid of squares of a given size and count the squares that the shape fills.That would give us an approximation of the area we are looking for.
If we start to make the squares smaller and smaller, more of the shape is inscribed within it.
We can repeat the process of making the squares smaller and smaller, to get better approximations. If we make those squares infinitely small, the value of the area of the shape will be so close to its real area that the difference would be negligible.
 
Therefore, the previous act of getting the tangent of the curve and now the act of getting the area of an exotic shape, relied on the same procedure to get answered. We used infinitesimally small numbers. In fact, I have run across various references to calculus as infinitesimal calculus. If we want to make the jump from algebra, which can only give us approximations of the answers to these questions, to calculus , where we can get the exact answers we are looking for, we must go through Limits.
 
And so must I, next time.
 
What do to think?