1118 days ago by pub

Calculate the surface integral of the scalar function $f=x+y+z$ on the triangle with vertices A(1,0,0), B(0,1,0) and C(0,0,1).

We need to calculate $\iint_S \, f \,dS$

Solution: We need a function for the triangle. The triangle lies on the plane passing through A, B and C:

The normal vector to this plane is: $\vec n = \overrightarrow {AB} \times \overrightarrow {AC} = \left| {\begin{array}{*{20}{c}} {\vec i}&{\vec j}&{\vec k}\\ { - 1}&1&0\\ { - 1}&0&1 \end{array}} \right| = \vec i + \vec j + \vec k=<1,1,1>$

Using A and $\vec n$, the equation of the plane is $(x-1)+(y-0)+(z-0)=0$ or ${x+y+z=1}$ or explicitly $ \boxed{\color{red}{S:\,z=1-x-y}}$

Notice that the function $f$ has a constant value of 1 on this plane.

The triangle itself is an equilateral triangle with side length $a=\sqrt{2}$ so with area $A=\frac{\sqrt{3}}{4} \cdot a^2=\frac{\sqrt{3}}{2}$

So we expect the surface integral to be $\iint_S\,{f(x,y,z)}\,dS=\iint_S{1}dS =1 \cdot \text{Area of Triangle}=\frac{\sqrt{3}}{2}$

We have an explicit form for the surface $S:\,z=1-x-y$ so we will use the formula:

$\iint_S\,{f(x,y,z)}\,dS=\iint_{D_{xy}}\,{f(x,y,z(x,y))}\sqrt{(\frac{\partial z}{\partial x})^2+(\frac{\partial z}{\partial x})^2+1}\,dxdy$ where

$f(x,y,z(x,y))=x+y+(1-x-y)=1$, $\frac{\partial z}{\partial x}=-1$, $\frac{\partial z}{\partial y}=-1$ so $\sqrt{(\frac{\partial z}{\partial x})^2+(\frac{\partial z}{\partial x})^2+1}=\sqrt{3}$.

$D_{xy}$ is the projection of the triangle onto the x0y plane so is a triangle with vertices (0,0), (1,0) and (0,1).

The equation of the line passing through (1,0) and (0,1) is $y=-x+1$.

So $D_{xy}$ has $y \in [0,-x+1]$ and $x \in [0,1]$

Finally: $\iint_S\,{f(x,y,z)}\,dS=\int_0^1(\int_0^{-x+1} \,\sqrt 3\,dy)dx=\sqrt 3 \int_0^1y \bigg|_0^{-x+1}dx=\sqrt 3 \int_0^1(-x+1)dx=\sqrt 3 (\frac{{ - {x^2}}}{2} + x)   \bigg|_0^1  =\boxed{ \frac{{\sqrt 3 }}{2}} $

var ('x y z') plane1=implicit_plot3d(x+y+z==1,(x,0,1),(y,0,1),(z,0,1),color='red', opacity=.7) Dxy=polygon(([0,0,0],[1,0,0],[0,1,0]),color='purple',opacity=.5) tx=text3d("x",(0.5,0,0)) ty=text3d("y",(1,0.5,0)) tline=text3d("y=-x+1",(0.6,0.6,0), color='green') show(plane1+Dxy+tx+ty+tline, figsize=4) 

Not seeing image above? Click here: 3d

To use the SOLVER, we parameterize the surface with 2 parameters.

Work particular to this problem: 

== The equation of the plane going through the 3 points is: x+y+z=1 or z=1-x-y. Remember to parameterize an explicit function z=f(x,y), we set x=u, y=v and z=f(u,v)

== So: $\left\{ \begin{array}{l}x = u \\y = v\\z =1-u-v\end{array} \right.\,\,\,\,\,u \in [0,1 ] \,\,\,\,v \in [0,-u+1]$
(To get the intervals, we look at the vertices of the triangle in the u0v plane. They are V1==(u=1,v=0), V2=(u=0,v=1) and V3=(u=0,v=0). We draw this region. It is a triangle where v goes from 0 to the line joining V1 and V2, namely v=-u+1 and then u goes from 0 to 1.)

Hand Solution:

We now recalculate using the parameterized form. 

$\iint_S\,{f(x,y,z)}\,dS=\iint_{D_{xy}}\,{f(x,y,z(x,y))}$ $\left\| {d{{\vec S}_u} \times d{{\vec S}_v}} \right\| \,du\,dv$ where  $d{{\vec S}_u}=\,<\frac{\partial x}{\partial u},\frac{\partial y}{\partial u},\frac{\partial z}{\partial u }>$ and $d{{\vec S}_v}=\,<\frac{\partial x}{\partial v},\frac{\partial y}{\partial v},\frac{\partial z}{\partial v}>$

We have 

$d{{\vec S}_u}=\,\lt \frac{\partial x}{\partial u},\frac{\partial y}{\partial u},\frac{\partial z}{\partial u} \gt \,=\,\lt 1,0,-1\gt \,$ and $d{{\vec S}_v}=\,<\frac{\partial x}{\partial v},\frac{\partial y}{\partial v},\frac{\partial z}{\partial v}>\,=\,\lt 0,1,-1 \gt $

So ${d{{\vec S}_u} \times d{{\vec S}_v}} = \left| {\begin{array}{*{20}{c}} {\vec i}&{\vec j}&{\vec k}\\ 1&0&-1\\ 0&1&-1 \end{array}} \right| ={\vec i}+{\vec j}+{\vec k}$ and $\left\| {d{{\vec S}_u} \times d{{\vec S}_v}} \right\| \,=\sqrt{3}$.

We input the parametrization into the function $f(x,y,z)=x+y+z=u+v+1-u-v=1$

Finally $SA=\iint_SdS=\int_0^1 \int_0^{-u+1}\sqrt{3}\,dv \, du = \sqrt 3 \int_0^1y \bigg|_0^{-x+1}dx=\sqrt 3 \int_0^1(-x+1)dx=\sqrt 3 (\frac{{ - {x^2}}}{2} + x)   \bigg|_0^1  =\boxed{ \frac{{\sqrt 3 }}{2}} $

SOLVER: Our program follows the hand solution method. Everything in red requires something particular to your problem!

  1. Parameterize S and input as vector function. Requires parametrization - done above.
  2. Input f(x,y,z).
  3. Find the partials of S. 
  4. Find the vector product of the partials. Find the magnitude (intensity) of this vector.
  5. Substitute parameterization in f.
  6. Find the integrand.
  7. Find intervals of integration and integrate. Requires intervals of parametrization - done above.

Step 0: The program declares our variables. We are given variables (x,y,z). We need (u,v) as parameters.

var ('u v'); var('x y z') 
\newcommand{\Bold}[1]{\mathbf{#1}}\left(u, v\right)
\newcommand{\Bold}[1]{\mathbf{#1}}\left(x, y, z\right)
\newcommand{\Bold}[1]{\mathbf{#1}}\left(u, v\right)
\newcommand{\Bold}[1]{\mathbf{#1}}\left(x, y, z\right)

Step 1: We define $\vec S$, $\vec n$ and $\vec F$. Changes with problem; you must input your parametrization in Sf.

Sf=vector((u,v,1-u-v)) f=x+y+z 

Step 2: The program finds the partial derivatives.

Sprime_u=diff(Sf,u) view(Sprime_u) 
Sprime_v=diff(Sf,v) view(Sprime_v) 

Step 3: The program calculates $\left\| {d{{\vec S}_u} \times d{{\vec S}_v}} \right\|$

npar=Sprime_u.cross_product(Sprime_v) np=abs(npar) view(np) 

Step 4: The program defines a standard sage function for "change of variables" for a 2-variable parametrization (surface).

The program changes the variables of $f$.

def changevar(h, eqn, newvar1,newvar2): return h.substitute(eqn) 
f=changevar(f,x==Sf[0],u,v) f=changevar(f,y==Sf[1],u,v) f=changevar(f,z==Sf[2],u,v) view(f) 

Step 5: Then program finds the mixed product and multiplies it by the orientation from step 3.

Int=np*f view(Int) 

Step 6: The program computes the integral (flux). Changes with problem - we must put in our intervals of integration.

I=integral(integral(Int,(v,0,-u+1)),(u,0,1)) view(I) 
\newcommand{\Bold}[1]{\mathbf{#1}}\frac{1}{2} \, \sqrt{3}
\newcommand{\Bold}[1]{\mathbf{#1}}\frac{1}{2} \, \sqrt{3}

So: $\iint_S f \,dS =\frac{\sqrt{3}}{2} \approx 0.87$