Finding the area of a triangle with integration I want to compute the area of the triangle with vertices $(0,0), (1,0), (1,1)$ by parameterizing the line segments parallel to the hypotenuse of the triangle. For example, the length of the segment $(0,0), (1,1)$ is $\sqrt{2}$, and more generally, for any $0 \leq x \leq 1$, the line through $(x,0)$ with slope $1$ hits the other side of my triangle at the point $(1, 1-x)$, so the length of the line segment contained in my triangle is $\sqrt{ 2 \cdot (1-x)^2 } = \sqrt{2}(1-x)$. As $x$ ranges in $[0,1]$, I conclude that the area of my triangle is $$\int_0^1 \sqrt{2}(1-x)\,dx = \sqrt{2} \cdot \frac{1}{2}$$
But the area of my triangle is actually $1/2$. Where am I going wrong?
 A: Your attempt isn't so bad, but when you sweep the hypothenuse by $dx$, the elementary area that you cover isn't $l\,dx$ but $\dfrac l{\sqrt2}dx$ because you need to multiply the base by the height, not by the length.
Said differently, if you consider that you are sweeping perpendicularly to the hypothenuse, then the area is $l\,\dfrac{dx}{\sqrt2}$, because the motion in the perpendicular direction is smaller than in the horizontal direction.
Hence,
$$\int_0^1 \sqrt{2}(1-x)\frac1{\sqrt2}\,dx = \frac{1}{2}.$$
A: What you are doing wrong is you are solving the problem by handwaving instead of rigid mathematics.
There is no mathematical theorem that says that the area of a surface is the integral of line lengths of all lines that cover the surface.
The surface area of a shape under a function is the integral of that function, and in your case, the function is $f(x)=x$ on $[0,1]$, so the area is $$\int_0^1xdx=\frac12$$
What you were trying to do had no basis in theory, and thus did (unsurprisingly) not work.
A: Ok, as per what you have done ,  you are finding the area of triangle under the hypotenuse line by integrating the LENGTH of the hypotenuse.
this is wrong.
To find the area, you should integrate the line equation for the limits in $x$.
But , as per what you say, if you are using an arbitrary line passing through $x$    $ \forall  x \in (0,1)$ intersecting the other side (perpendicular side) at $(1,1-x)$ , 
then , the integration becomes slightly more,  shall I say , tedious.
In that case, as you move this line from $x=0$ to $x=1$ , the $y$ coordinates also change i.e you would have to consider y co-ordinate too as it varies from $y=0$  to  $y=(1-x) $ .
does that help ?
