| 1 |
C Copyright(C) 1999-2020 National Technology & Engineering Solutions |
| 2 |
C of Sandia, LLC (NTESS). Under the terms of Contract DE-NA0003525 with |
| 3 |
C NTESS, the U.S. Government retains certain rights in this software. |
| 4 |
C |
| 5 |
C See packages/seacas/LICENSE for details |
| 6 |
|
| 7 |
C======================================================================= |
| 8 |
SUBROUTINE SMOGS3 (xscr, yscr, zscr, isbnd, x, y, z, numel, |
| 9 |
$ link, nlink, numnp, nscr) |
| 10 |
C======================================================================= |
| 11 |
|
| 12 |
C*********************************************************************** |
| 13 |
|
| 14 |
C SUBROUTINE SMOGS = MESH SMOOTHING BY LAPLACE-S USING GAUSS-SEIDEL |
| 15 |
|
| 16 |
C*********************************************************************** |
| 17 |
|
| 18 |
real x(*), y(*), z(*), xscr(*), yscr(*), zscr(*) |
| 19 |
integer numel, nlink, link(nlink, *) |
| 20 |
logical isbnd(*) |
| 21 |
integer nscr(*) |
| 22 |
integer map(3,8) |
| 23 |
|
| 24 |
data map /2,4,5, 3,1,6, 4,2,7, 1,3,8, |
| 25 |
$ 1,8,6, 2,5,7, 3,6,8, 4,7,5/ |
| 26 |
|
| 27 |
if (nlink .ne. 8) return |
| 28 |
do 20 iel = 1, numel |
| 29 |
do 10 ino = 1, nlink |
| 30 |
|
| 31 |
ni = link(ino, iel) |
| 32 |
if (.not. isbnd(ni)) then |
| 33 |
n1 = link( map(1, ino), iel) |
| 34 |
n2 = link( map(2, ino), iel) |
| 35 |
n3 = link( map(3, ino), iel) |
| 36 |
xscr(ni) = xscr(ni) + x(n1) + x(n2) + x(n3) |
| 37 |
yscr(ni) = yscr(ni) + y(n1) + y(n2) + y(n3) |
| 38 |
zscr(ni) = zscr(ni) + z(n1) + z(n2) + z(n3) |
| 39 |
nscr(ni) = nscr(ni) + 3 |
| 40 |
end if |
| 41 |
10 continue |
| 42 |
20 continue |
| 43 |
return |
| 44 |
end |