3d_planespec

<< Click to Display Table of Contents >>

Navigation:  Sample Problems > Usage > 3D_domains >

3d_planespec

Previous pageReturn to chapter overviewNext page

{ 3D_PLANESPEC.PDE  

 

 This problem demonstrates the use of the PLANE generating function in

 3D domain specifications.

 

 We construct a hexahedron using two PLANE statements. One from explicit

 points and another from named points in the definitions section.

}

 

title 'PLANE surface generation'

 

coordinates

   cartesian3

 

variables

   Tp

 

select

   ngrid=5 { reduce mesh size for example }

 

definitions

   long = 1

   wide = 1

   K  = 1

   Q = 10*exp(-x^2-y^2-z^2)

  { define three points in the plane surface }

   bll = point(-1,-1,0)

   blr = point(1,-1,0.2)

   bul = point(-1,1,0.3)

 

initial values

   Tp = 0.

 

equations

   Tp:  div(k*grad(Tp)) + Q = 0

 

extrusion  

  { bottom surface using named points }

  surface 'bottom'  z = PLANE(bll,blr,bul)

  { top surface using explicit points }

  surface 'top'     z = PLANE((-1,-1,1), (1,-1,1.2), (1,1,2))

 

boundaries

  surface 1 value(Tp)=0

  surface 2 value(Tp)=0

 

  Region 1

      start(-wide,-wide)

        value(Tp) = 0

        line to (wide,-wide)

          to (wide,wide)

          to (-wide,wide)

          to close

monitors

  grid(x,z) on y=0

 

plots

  grid(x,y,z)   viewpoint(-7,-9,10)

  grid(x,z) on y=0

  contour(Tp) on y=0 as "ZX Temp"

  contour(Tp) on x=0 as "YZ Temp"

 

end