|
|
"alphaQuad" <alp### [at] earthlinknet> wrote:
> The Volume of pyramid is [area of the pyramid's base] X [height] X
> [1/3], and is expressed in cubic units.
> from: [http://www.aaamath.com/B/geo79_x6.htm]
also given 4 3d points, volume of the tetrahedron =
This can be rewritten as a dot and cross product, yielding
V = \frac { |(\mathbf{d}-\mathbf{a}) \cdot
((\mathbf{d}-\mathbf{b}) \times (\mathbf{d}-\mathbf{c}))| } {6}.
http://en.wikipedia.org/wiki/Tetrahedron
OMG LOL!!!!!!!
tested
alias pyramid_area {
; (4 3d pnts)
return $calc($abs($dotprod($subv($4,$1), $&
$cross($subv($4,$2), $subv($4,$3)))) / 6)
}
POV
#macro pyramid_area(A,B,C,D)
vdot(D-A,vcross(D-B,D-C)) / 6
#end
Post a reply to this message
|
|