OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
cutcnt.F
Go to the documentation of this file.
1Copyright> OpenRadioss
2Copyright> Copyright (C) 1986-2025 Altair Engineering Inc.
3Copyright>
4Copyright> This program is free software: you can redistribute it and/or modify
5Copyright> it under the terms of the GNU Affero General Public License as published by
6Copyright> the Free Software Foundation, either version 3 of the License, or
7Copyright> (at your option) any later version.
8Copyright>
9Copyright> This program is distributed in the hope that it will be useful,
10Copyright> but WITHOUT ANY WARRANTY; without even the implied warranty of
11Copyright> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12Copyright> GNU Affero General Public License for more details.
13Copyright>
14Copyright> You should have received a copy of the GNU Affero General Public License
15Copyright> along with this program. If not, see <https://www.gnu.org/licenses/>.
16Copyright>
17Copyright>
18Copyright> Commercial Alternative: Altair Radioss Software
19Copyright>
20Copyright> As an alternative to this open-source version, Altair also offers Altair Radioss
21Copyright> software under a commercial license. Contact Altair to discuss further if the
22Copyright> commercial version may interest you: https://www.altair.com/radioss/.
23!||====================================================================
24!|| cutcnt ../engine/source/tools/sect/cutcnt.F
25!||--- called by ------------------------------------------------------
26!|| genani ../engine/source/output/anim/generate/genani.f
27!||--- uses -----------------------------------------------------
28!|| anim_mod ../common_source/modules/output/anim_mod.F
29!||====================================================================
30 SUBROUTINE cutcnt(ICUT,XCUT,IXS,XYZ0,D,LEN)
31C-----------------------------------------------
32C M o d u l e s
33C-----------------------------------------------
34 USE anim_mod
35C------------------------------------------
36C NUMBERING CUT ELEMS
37C-----------------------------------------------
38C I m p l i c i t T y p e s
39C-----------------------------------------------
40#include "implicit_f.inc"
41C-----------------------------------------------
42C C o m m o n B l o c k s
43C-----------------------------------------------
44#include "com04_c.inc"
45#include "scrcut_c.inc"
46C-----------------------------------------------
47C D u m m y A r g u m e n t s
48C-----------------------------------------------
49 my_real xcut(7,*),xyz0(3,*),d(3,*)
50 INTEGER ICUT(44,*),IXS(NIXS,*),LEN
51C-----------------------------------------------
52C L o c a l V a r i a b l e s
53C-----------------------------------------------
54 INTEGER IC,I,J,K,ITYP
55 my_real dist,dist0,distmin,distmax,dd,dx1,dy1,dz1,dx2,dy2,dz2,vnx,vny,vnz,x,y,z
56C-----------------------------------------------
57C S o u r c e L i n e s
58C-----------------------------------------------
59 len=0
60 DO ic=1,ncuts
61 ityp=icut(1,ic)
62 IF(ityp==1)THEN
63 dd=dtanim*xcut(7,ic)
64 xcut(1,ic)=xcut(1,ic)+dd*xcut(4,ic)
65 xcut(2,ic)=xcut(2,ic)+dd*xcut(5,ic)
66 xcut(3,ic)=xcut(3,ic)+dd*xcut(6,ic)
67 ELSEIF(ityp==3)THEN
68 xcut(1,ic)=xyz0(1,icut(2,ic))
69 xcut(2,ic)=xyz0(2,icut(2,ic))
70 xcut(3,ic)=xyz0(3,icut(2,ic))
71 dx1=xyz0(1,icut(3,ic))-xcut(1,ic)
72 dy1=xyz0(2,icut(3,ic))-xcut(2,ic)
73 dz1=xyz0(3,icut(3,ic))-xcut(3,ic)
74 dx2=xyz0(1,icut(4,ic))-xcut(1,ic)
75 dy2=xyz0(2,icut(4,ic))-xcut(2,ic)
76 dz2=xyz0(3,icut(4,ic))-xcut(3,ic)
77 vnx=dy1*dz2-dy2*dz1
78 vny=dz1*dx2-dz2*dx1
79 vnz=dx1*dy2-dx2*dy1
80 dd=sqrt(vnx**2+vny**2+vnz**2)
81 IF(dd>em10)THEN
82 xcut(4,ic)=vnx/dd
83 xcut(5,ic)=vny/dd
84 xcut(6,ic)=vnz/dd
85 ENDIF
86 ENDIF
87C
88 dist0=xcut(4,ic)*xcut(1,ic)+xcut(5,ic)*xcut(2,ic)+xcut(6,ic)*xcut(3,ic)
89 DO i=1,numels
90 distmin= ep30
91 distmax=-ep30
92 DO j=1,8
93 k=ixs(j+1,i)
94 x=xyz0(1,k)
95 y=xyz0(2,k)
96 z=xyz0(3,k)
97 IF(ityp==2)THEN
98 x=x-d(1,k)
99 y=y-d(2,k)
100 z=z-d(3,k)
101 ENDIF
102 dist=x*xcut(4,ic)+y*xcut(5,ic)+z*xcut(6,ic)-dist0
103 distmin=min(dist,distmin)
104 distmax=max(dist,distmax)
105 enddo!next J
106 IF(distmin*distmax<= zero)len=len+1
107 enddo!next I
108C
109 enddo!next IC
110 RETURN
111 END
#define my_real
Definition cppsort.cpp:32
subroutine cutcnt(icut, xcut, ixs, xyz0, d, len)
Definition cutcnt.F:31
subroutine genani(x, d, v, a, bufel, ixs, ixq, ixc, ixt, ixp, ixr, ixtg, swaft, smas, sxnorm, siad, iparg, pm, geo, ms, sinvert, cont, smater, icut, skew, xcut, fint, itab, sel2fa, fext, fopt, anin, lpby, npby, nstrf, rwbuf, nprw, tani, elbuf_tab, mat_param, dd_iad, weight, eani, ipart, cluster, iparts, ipartq, ipartc, ipartt, ipartp, ipartr, ipartur, iparttg, rby, swa4, tors, nom_opt, igrsurf, bufsf, idata, rdata, siadg, bufmat, bufgeo, kxx, ixx, ipartx, suix, sxusr, snfacptx, sixedge, sixfacet, sixsolid, snumx1, snumx2, snumx3, soffx1, soffx2, soffx3, smass1, smass2, smass3, sfunc1, sfunc2, sfunc3, kxsp, ixsp, nod2sp, ipartsp, spbuf, ixs10, ixs20, ixs16, vr, monvol, volmon, ipm, igeo, nodglob, iad_elem, fr_elem, fr_sec, fr_rby2, iad_rby2, fr_wall, iflow, rflow, fncont, ftcont, temp, thke, err_thk_sh4, err_thk_sh3, diag_sms, ipari, fncont2, dr, ale_connectivity, irbe2, irbe3, lrbe2, lrbe3, fr_rbe2, fr_rbe3m, iad_rbe2, dxancg, nod_pxfem, iel_pxfem, zi_ply, vgaz, fcontg, fncontg, ftcontg, fanreac, inod_crk, iel_crk, elcutc, iadc_crk, pdama2, res_sms, weight_md, nodglobxfe, nodedge, fcluster, mcluster, xfem_tab, w, nv46, ipartig3d, kxig3d, ixig3d, sig3dsolid, knot, wige, nercvois, nesdvois, lercvois, lesdvois, crkedge, indx_crk, xedge4n, xedge3n, stack, sph2sol, stifn, stifr, igrnod, h3d_data, subset, multi_fvm, knotlocpc, knotlocel, fcont_max, fncontp2, ftcontp2, glob_therm, drape_sh4n, drape_sh3n, drapeg, output)
Definition genani.F:239
#define min(a, b)
Definition macros.h:20
#define max(a, b)
Definition macros.h:21