OpenRadioss 2025.1.11
OpenRadioss project
Loading...
Searching...
No Matches
inori2.F File Reference
#include "implicit_f.inc"
#include "units_c.inc"

Go to the source code of this file.

Functions/Subroutines

subroutine inori2 (irect, isg, nel, nint, noint, ym1, ym2, zm1, zm2, ye, ze)

Function/Subroutine Documentation

◆ inori2()

subroutine inori2 ( integer, dimension(4,*) irect,
integer isg,
integer nel,
integer nint,
integer noint,
ym1,
ym2,
zm1,
zm2,
ye,
ze )

Definition at line 31 of file inori2.F.

34C-----------------------------------------------
35C D e s c r i p t i o n
36C-----------------------------------------------
37C INIT INTERFACE : CHECK ORIENTATION
38C reverse segment connectivity if needed
39C-----------------------------------------------
40C I m p l i c i t T y p e s
41C-----------------------------------------------
42#include "implicit_f.inc"
43C-----------------------------------------------
44C C o m m o n B l o c k s
45C-----------------------------------------------
46#include "units_c.inc"
47C-----------------------------------------------
48C D u m m y A r g u m e n t s
49C-----------------------------------------------
50 INTEGER ISG, NEL, NINT, NOINT
51 INTEGER IRECT(4,*)
52 my_real ym1, ym2, zm1, zm2,ye(4) ,ze(4)
53C-----------------------------------------------
54C L o c a l V a r i a b l e s
55C-----------------------------------------------
56 INTEGER IR
57 my_real n2, n3, ym, zm, dds
58C-----------------------------------------------
59C E x t e r n a l F u n c t i o n s
60C-----------------------------------------------
61 IF(nel==0) RETURN ! NO ELEM CONNECTED TO CURRENT SEGMENT
62 !segment vector p1->p2
63 n2= zm2-zm1
64 n3= ym1-ym2
65 !elem centroid
66 ym= fourth*(ye(1)+ye(2)+ye(3)+ye(4))
67 zm= fourth*(ze(1)+ze(2)+ze(3)+ze(4))
68 !dot product
69 dds=n2*(ym-ym1)+ n3*(zm-zm1)
70 IF(dds >= zero)THEN
71 !switch the segment connectivity to get outward normal
72 ir=irect(1,isg)
73 irect(1,isg)=irect(2,isg)
74 irect(2,isg)=ir
75 IF(nint>0) WRITE (iout,1100) isg, noint
76 IF(nint<0) WRITE (iout,1200) isg, noint
77 ENDIF
78 RETURN
79C-----------------------------------------------
80 1100 FORMAT(' NODE CONNECTIVITY OF SECONDARY SEGMENT',i5,' OF INTERFACE',i10,' REVERSED')
81 1200 FORMAT(' NODE CONNECTIVITY OF MAIN SEGMENT',i5,' OF INTERFACE',i10,' REVERSED')
#define my_real
Definition cppsort.cpp:32