Compute face metrics.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(face_object), | intent(inout) | :: | self | Face. |
||
| type(vector), | intent(in) | :: | pt1 | Point 1 of face. |
||
| type(vector), | intent(in) | :: | pt2 | Point 2 of face. |
||
| type(vector), | intent(in) | :: | pt3 | Point 3 of face. |
||
| type(vector), | intent(in) | :: | pt4 | Point 4 of face. |
||
| real(kind=R8P), | intent(in) | :: | signd | Sign of direction along normal coordinate. |
elemental subroutine compute_metrics(self, pt1, pt2, pt3, pt4, signd)
!< Compute face metrics.
class(face_object), intent(inout) :: self !< Face.
type(vector), intent(in) :: pt1 !< Point 1 of face.
type(vector), intent(in) :: pt2 !< Point 2 of face.
type(vector), intent(in) :: pt3 !< Point 3 of face.
type(vector), intent(in) :: pt4 !< Point 4 of face.
real(R8P), intent(in) :: signd !< Sign of direction along normal coordinate.
self%normal = self%normal%face_normal4(pt1 = pt1, pt2 = pt2, pt3 = pt3, pt4 = pt4) * signd
self%area = self%normal%normL2()
call self%normal%normalize
endsubroutine compute_metrics