animation of finite element models of metal forming processes

11
Compukrs & Srwcrures Vol. 58, No. 5, pp. 99-1001. 19% Copyright 0 1995 &vier Science Ltd Printed in Great Britain. All rights reserved BH> Pergamon 0045-7949@5MMl221-9 . 0045.7949/96 h5.00 + 0.00 ANIMATION OF FINITE ELEMENT MODELS OF METAL FORMING PROCESSES S. B. Petersen,? R. Balendra,? J. M. C. Rodrigues$ and P. A. F. Martins$ tuniversity of Strathclyde, Manufacturing and Engineering Management Division, 75 Montrose Street, Glasgow Gl lXJ, Scotland $Instituto Superior Tknico, Departamento de Engenharia Meclnica, Av. Rovisco Pais, 1096 Lisboa Codex, Portugal (Received 2 August 1994) Abstract-An interface program which makes it possible to animate finite element models of metal forming processes in an “Autodesk 3D Studio” environment is presented. The program converts typical finite element results files for a succession of deformation stages into an ASCII file suitable for loading into “3D Studio”. The interface presented processes two-dimensional models only; it requires that the models are discretized by linear rectangular elements and dies by linear two-noded elements. Conversion of mesh objects is based on the creation of triangular three-dimensional faces structured on a set of vertices which are defined by the node positions in the finite element result file. The program is written in FORTRAN and a glossary of terms and the source listing are included. For axisymmetric cases, guidelines are provided for generating three-dimensional effects. An elaborate example of the operational procedure is given. INTRODUCTION In recent years computer-aided engineering (CAE) techniques have been applied increasingly with great success in metal forming research. Numerical model- ing of metal forming processes using the finite element method has reduced the lead time and devel- opment costs associated with the manufacture of new components. However, in the majority of cases, the task of analyzing the results is still tedious, requiring considerable effort for the interpretation of a large number of graphical plots for various stages of deformation. Further, these plots are not always readily assimilated and important details in the pro- cess, such as dead metal zone formation and develop- ment of flaws, remain obscure even to experienced engineers. Therefore, post-processing of finite el- ement results plays an important role and develop- ments in post processing have paralleled the developments in computers. The performance of per- sonal computers has reached a level which makes animation, in this environment, a realistic tool in the research of metal forming processes. Animation can be seen as the third generation of post processing after the line printer output and the graphical plot. As it imparts motion to still images, it improves the understanding of material flow and makes computer aided detection of processing failures more reliable. Animation facilities for finite element (FE) analysis are already encountered in several commercial gen- eral purpose post-processing programs, but these can only be implemented on workstations. Given this background, the main objective of the reported work is to provide an interface which allows FE users to animate solutions in a personal computer environment by applying a professional animation program. The feasibility and flexibility of the solution, together with the high quality of the anima- tion, emphasizes the advantages of this approach. The interface program reads input data which are arranged in two different families with respect to the file structure. The first family relates to the descrip- tion of the FE mesh object and provides a list of the material node numbers and the corresponding co- ordinates, which is followed by a list of the nodal connections of each element in counter clockwise order. The linear rectangular element was chosen because of its popularity, but the program can be modified to include other mesh elements without difficulty. The second family requires a discretization, in counter-clockwise order, of the contour of the dies which are defined by using two noded linear elements. The file produced by the interface program from one or several FE output files is compatible with “3D Studio” by Autodesk [l], and editing of the loaded mesh objects, including the dies, is not necessary during animation. In the present form, the listing only covers anima- tion of two-dimensional FE models. It is expected that the interface will save engineers and researchers considerable time in introducing animation into their work. Modification of its main architecture is welcome, and can be done at two different levels: 991

Upload: luciopatricio

Post on 30-Dec-2015

27 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Animation of Finite Element Models of Metal Forming Processes

Compukrs & Srwcrures Vol. 58, No. 5, pp. 99-1001. 19% Copyright 0 1995 &vier Science Ltd

Printed in Great Britain. All rights reserved BH> Pergamon 0045-7949@5MMl221-9 . I

0045.7949/96 h5.00 + 0.00

ANIMATION OF FINITE ELEMENT MODELS OF METAL FORMING PROCESSES

S. B. Petersen,? R. Balendra,? J. M. C. Rodrigues$ and P. A. F. Martins$ tuniversity of Strathclyde, Manufacturing and Engineering Management Division, 75 Montrose Street,

Glasgow Gl lXJ, Scotland $Instituto Superior Tknico, Departamento de Engenharia Meclnica, Av. Rovisco Pais, 1096 Lisboa

Codex, Portugal

(Received 2 August 1994)

Abstract-An interface program which makes it possible to animate finite element models of metal forming processes in an “Autodesk 3D Studio” environment is presented. The program converts typical finite element results files for a succession of deformation stages into an ASCII file suitable for loading into “3D Studio”. The interface presented processes two-dimensional models only; it requires that the models are discretized by linear rectangular elements and dies by linear two-noded elements. Conversion of mesh objects is based on the creation of triangular three-dimensional faces structured on a set of vertices which are defined by the node positions in the finite element result file. The program is written in FORTRAN and a glossary of terms and the source listing are included. For axisymmetric cases, guidelines are provided for generating three-dimensional effects. An elaborate example of the operational procedure is given.

INTRODUCTION

In recent years computer-aided engineering (CAE) techniques have been applied increasingly with great success in metal forming research. Numerical model- ing of metal forming processes using the finite element method has reduced the lead time and devel- opment costs associated with the manufacture of new components. However, in the majority of cases, the task of analyzing the results is still tedious, requiring considerable effort for the interpretation of a large number of graphical plots for various stages of deformation. Further, these plots are not always readily assimilated and important details in the pro- cess, such as dead metal zone formation and develop- ment of flaws, remain obscure even to experienced engineers. Therefore, post-processing of finite el- ement results plays an important role and develop- ments in post processing have paralleled the developments in computers. The performance of per- sonal computers has reached a level which makes animation, in this environment, a realistic tool in the research of metal forming processes. Animation can be seen as the third generation of post processing after the line printer output and the graphical plot. As it imparts motion to still images, it improves the understanding of material flow and makes computer aided detection of processing failures more reliable.

Animation facilities for finite element (FE) analysis are already encountered in several commercial gen- eral purpose post-processing programs, but these can only be implemented on workstations.

Given this background, the main objective of the reported work is to provide an interface which allows FE users to animate solutions in a personal computer environment by applying a professional animation program. The feasibility and flexibility of the solution, together with the high quality of the anima- tion, emphasizes the advantages of this approach.

The interface program reads input data which are arranged in two different families with respect to the file structure. The first family relates to the descrip- tion of the FE mesh object and provides a list of the material node numbers and the corresponding co- ordinates, which is followed by a list of the nodal connections of each element in counter clockwise order. The linear rectangular element was chosen because of its popularity, but the program can be modified to include other mesh elements without difficulty.

The second family requires a discretization, in counter-clockwise order, of the contour of the dies which are defined by using two noded linear elements.

The file produced by the interface program from one or several FE output files is compatible with “3D Studio” by Autodesk [l], and editing of the loaded mesh objects, including the dies, is not necessary during animation.

In the present form, the listing only covers anima- tion of two-dimensional FE models. It is expected that the interface will save engineers and researchers considerable time in introducing animation into their work. Modification of its main architecture is welcome, and can be done at two different levels:

991

Page 2: Animation of Finite Element Models of Metal Forming Processes

992 S. B. Petersen et al.

(a) enlargement 1. the possible choice of discretization elements (the current program only supports linear, four noded rectangular elements for mesh objects and Lwo-noded linear elements for dies);

(b) inclusion of thr :e-dimensional animation for axisymmetrical cases.

Guidelines for the latter have been provided. However, for research ~1 trposes the two-dimensional solution is sufficient. :vhereas three-dimensional animation of processes wrth axisymmetric geometries is more relevant for e4:ls:ational/training purposes.

PROGRAMMhtG i ‘ONSIDERATIONS

Some basic requirendcn?., were taken into account in the design of the inrcr-C:z.ce. Besides being easy to use, it was decided thcl the post-processing must contain the following capabilities:

(a) entire post processing should be performed on personal computers;

(b) incorporation of ;nols in th: animation; (c) animation of me:,!, objects t:.<posed to remesh-

ing; (d) animation with borh wire irame and two col-

ored material-the latter irispirec’ ii:, the experimental work with plasticine;

(e) eventual three-di!ncnsion:il animation should be possible by si:q:le exte .:.:.:II of the two- dimensional model.

A commercially available program which enables the above is “3D Studio” by Autodesk.

“30 Studio ” background

Autodesk “3D Studio” is a three-dimensional modeling and animation application program for personal computers. Besides the basic facilities for animation, the program enables the assignment of a variety of surface textures and colors and is able to impart a metallic appearance to the imported objects. Further, cameras and lights used for professional animation can also be added.

Basically the purpose of the animation program is to create a file containing a series of calculated in-between positions and states for the FE meshes, usually only created for relatively large steps in time (to save storage disk space). Thereby a sufficient number of still-images are provided from which continuous movement of the dies and corresponding deformation of mesh objects can be generated.

Representation of geometrical objects in “3D Stu- dio” environment is based on the creation of numer- ous faces which together display the surface of the object. Each face consists of a triangle formed from three vertices; vertices are defined as points in the Cartesian space, forming the structure on whichfaces are built.

The “3D Studio” animation program is able to read files with ASCII format in which the mesh objects are described by individual vertex- and facelist [l]. Generally FE results files do not have this structure; therefore it is necessary to convert the

I 1 Fig. 1. Wire frame model with dies from investigation of the radial extrusion process [31.

Page 3: Animation of Finite Element Models of Metal Forming Processes

Animation of finite element models 993

Fig. 2. Chequered-pattern model.

information using an interface program. The anima- tion file (.FLI or .FLC) created by “3D Studio” is compatible with ANIMATOR by Autodesk and MEDIA PLAYER for WINDOWS by Microsoft. “3D Studio” requires, as a minimum, a 386 processor with math co-processor and 4 Mb of RAM. Experi- ence suggests that, for the animation of FE simulation of two-dimensional problems which contain approxi- mately 500 elements, a more realistic choice would be a state of the art 486 processor with 16 Mb of RAM.

Two -dimensional interface program

Since standard FE result files always include a definition of nodal points using x- and y-coordinates which is similar to the vertex definition necessary for the ASCII file, only facelist has to be created. In practical terms this means a simple conversion of the linear rectangular elements into triangular faces and obscuring the diagonals in the element/square formed by two triangles.

The FORTRAN program listed in Appendix II consists of a main program with several subroutines. In subroutine INPUT, the program reads the FE results files (FEMx OUT) from the disc. Codes for the mesh model and die animation are computed in the subroutines WIRE and PATTERN depending on choice of animation model. The output file (PLAST3DS.ASC) to be read by “3D Studio” is, as previously mentioned, in ASCII format.

Running the interface program will give the follow- ing options:

(1) Choice between wire frame model (Fig. 1) and chequered-pattern model (Fig. 2).

(2) Creation of mirror image for horizontal symmetry cases (vertical symmetry is default). Symmetry lines must be coincident with a coordinate axis.

(3) Selective or sequential file reading procedure; the latter is convenient when several successive FE files corresponding to identical jumps in deformation (time) are to be processed.

Initial testing and development was done with simple models, such as compression tests. Later work included more complex bulk metal forming processes, as seen in Fig. 1. The analysis was preformed using PLAST2 FE program [2] and the examples were taken from ongoing research work [3,4] in which the animation has played an important role in under- standing process mechanics.

One of the advantages of the presented solution is the ease with which the FE result file is processed to enable the animation; the technique is illustrated in the following example.

EXAMPLE

Considering that the majority of users may not have knowledge of animation techniques, an exten- sive example of the whole operational procedure is provided in order to ease the introduction to anima- tion. Terms and commands specific for “3D Studio”

Page 4: Animation of Finite Element Models of Metal Forming Processes

994 S. B. Petersen et al.

Fig. 3. Flow diagram for files utilized during preparation of an animation scene.

will be used; to enhance understanding, these are written in italics.

In Fig. 1, a model consisting of a two-dimensional axisymmetric geometry is shown. Originally, only one quarter of the model containing 420 elements was analyzed. Further, three physical constraints (tools) were specified; a mandrel, a container and a punch. The animation procedure, for which a flow diagram is provided in Fig. 3, is as follows:

(1) Create FE output files (FEMx.OUT) with for- mat as an Appendix III for successive 10% defor- mation, in order to provide sufficient intermediate positions and states of the mesh object (e.g. one output file for each additional 10% height reduction in a simple compression test).

(2) Run PLAST3DS and select animation model. Horizontal symmetry was assumed in this example and the files were read sequentially to save time. Note that occasionally when a large number of FE output files has been processed into the same PLAST3DSASC file, the memory capacity can be exceeded for loading into “3D Studio”. If this is the case split PLAST3DSASC into two files by repro- cessing the FE output files.

(3) Start up “3D Studio” and loud PLAST3DS.ASC while in 30 Editor mode; it is mandatory to save the information immediately in binary .3DS format. If several PLAST3DS.ASC ex- ist, begin by making individual transformation to .3DS format and subsequently merge the files into the first .3DS file.

(4) Change from program to keyframer mode in which the animation will be made. Choose the X/Y (front) view. Before beginning the animation it is necessary to hide all objects, apart from the initial (including dies). Do display/hide/by name and choose all other objects than the initial. Under time/total frames set the total number of frames (still images) appropriately using:

t Morphing is a term taken from metamorphosis, which means to change physical shape or form-usually through supernatural means [2].

total frames = A x (no.FEM files - 1) (1)

where 15 < A < 30 will result in space for the calcu- lation of 14-29 intermediate positions and states in between two loaded FE mesh objects.

(5) Enter TRACKinfo, which provides a global view for planning the animation, by picking the initial mesh in the front (X/Y) view. Add morph? keys at every Ath frame leaving A -1 empty frames between two morph keys. The default parent object is the initial mesh object.

Using KEYinfo pick the first morph key. Once inside KEYinfo increase Key # number by one. To change the morph to object click the morph window and choose the mesh object which succeeds the initial mesh object. Proceed in this way to morph all the remaining mesh objects to the initial mesh object.

If horizontal symmetry was not chosen during the interface procedure, add position keys at frames previously provided with a morph key. Press the position button and change the parent object to the one which follows the initial mesh object. Write down the x and y position. Proceed to next parent object until all positions of parent objects have been identified.

Change parent object to the initial mesh object and increase Key number by one. Input the previously observed x and y position of the object to be morphed at this frame (position key). Repeat the procedure until all object positions have been assigned. This rearrangement is necessary as “3D Studio” allocates a definition point for each object at the average point of the object’s x and y extremity coordinates. Other- wise random movement of an asymmetrical object can occur during animation due to changes of the definition point.

After exiting TRACKinfo, everything is ready for the creation (rendering) of the animation file.

(6) Repeat step 5 for each moving die. (7) Choose renderer/render and pick the front

(X/Y) view to make the renderer menu appear. To create the animation file use rendering to disk. Having chosen the output file name the rendering begins.

Clearly the time necessary for rendering the anima- tion file will depend on the complexity of the FE model and on the number of files supplied for the range of deformation to be animated. For the pre- sented case, animation of 150 frames took approxi- mately 45 min to process using the proposed hardware.

Three-dimensional interface program

If required, the two-dimensional interface program may be enhanced to include three-dimensional ani- mation of axisymmetric geometries. Among several possible strategies authors suggest the “cheese

Page 5: Animation of Finite Element Models of Metal Forming Processes

Animation of finite element models 995

Fig. 4. Three-dimensional “cheese” model of the case shown in Figs 1 and 2.

model” solution illustrated in Fig. 4, where a single image from a three-dimensional animation of the case presented in Figs 1 and 2 is shown. This solution

allows the viewer to observe the material flow and development of external, as well as eventual internal geometries, simultaneously. Information about the operational sequence can also be obtained. In practi- cal terms, such an extension in the animation requires programming modifications in the subroutines WIRE and PATTERN.

One programming policy is to create two cut- surfaces and subsequently build the necessary sur- faces between these to make the model look solid. The algorithm to create the cut-surface parallel to the X-Y plane is included in the listing of the two-dimen- sional program. The new cut surface, which is located at a given angle in the X-Z plane, can be defined by rotating the first cut-surface. To form the surfaces between the two cuts, it is recommended to create a set of vertex frames from the boundary nodes of the original FE mesh. Equally distributed between the two cut surfaces, in terms of rotation, the vertex frames will form, two by two, the structure on which the three-dimensional faces are to be built. The same procedure is applied for the dies.

CONCLUSIONS

The software described has been proven to be computationally efficient for interfacing FE results files of metal forming processes with the Autodesk “3D Studio” animation program; the program is easy to implement and use. The listing refers only to

two-dimensional models using linear rectangular el- ements; the same scheme can be extended to other elements and to three-dimensional models.

The resulting animation is of high quality; further enhancements can be achieved through the use of graphical boards and display terminals with high resolution. In comparison to FE animation produced using commercially-available software which runs on workstations, the proposed solution has the major advantage of being cheap to implement, with no reduction in the quality of the animation.

Since the work described above was developed in a personal computer environment, the animation results files with standard industry formats .FLC and .FLI can be incorporated in the multimedia packages available for these computers and used either in research or for education/training purposes.

REFERENCES

1. Autodesk Inc., Autodesk 30 Studio Release 2 Manual (1992).

2. P. A. F. Martins, J. M. C. Rodrigues and M. J. M. Barata Marques, Numerical and experimental simu- lation of cold forging processes. XIiI Seminririo Na- cional de Forjamento, UFRGS, Porto Alegre Brazil (1993).

3. M. Arentoft, S. B. Petersen, J. M. C. Rodrigues, P. A. F. Martins. R. Balendra and T. Wanheim. Review of the research on the iniection foraing of tubular materials. J. Mater. Proc. Tech. 52, 4cG71 (1995).

4. S. B. Petersen. J. M. C. Rodriaues and P. A. F. Martins. Extended formability limits -for tubular components through combined injection forming/upsetting-a finite element analysis. J. Engng Manuf. 209, 107-l 14 (1995).

Page 6: Animation of Finite Element Models of Metal Forming Processes

996 S. B. Petersen et al.

APPENDIX A: GLORRARY OF PROGRAM VARIABLES

The first set of variables establish current array dimen- sioning. Users may change some of these variables to match the size of their FE model and the memory available in the computer.

MPOIN maximum number of nodal points in the FE- model.

MELEM maximum number of elements in the FE-model MDIES maximum number of dies in the FE-model. MDPOI maximum number of nodal points allowed for

describing one die in the FE-model.

The second set of variables stores the geometrical infor- mation of both the animation and FE model. Attention must be focused on variable NFACES; due to limitations in “3D Studio”, this value should never exceed 64.000. NDIES number of dies in the considered FE result file.

NDPOI number of nodal points describing the con- sidered die.

NELEM number of elements in the considered FE result file.

NPOIN number of nodal points in the considered FE result file.

NVERTEXnumber of generated vertexes for an object.

NFACES number of generated faces for an object.

The last set of variables groups some of the more important remaining variables.

COORD

LNODS

DIEDF COLOR

coordinates x and y of each nodal point in the FE result file. connections for each linear rectangular element in the FE result file. die definition stored in array form. stores the color code of the previously examined elements of the FE-mesh.

1 2 c 3 I c 5 c 6 c 7 c 8 c 9 c

10 c 11 c 12 c 13 c 14 c 15 c 16 c 17 c 18 c 19 c 2OC 21 c 22 c 23 C 21 c 25C 26C 27 C 28C

APPENDIX B: COMPUTER PROGRAM

mxuu PusT3rs

ImICIT ImLR PRms1ai (A-R,oq

3D STUDIO INTERFACE

FOR

HETAL PORllIWG

PIUITE BLBWEUT ANALYSIS

FllIS PRUGRAH CREATES ASCII PO@lAT ScBlRS FRC4 YW-DIWlSIUlAL AXIS-CAL FMTS W IKMLS TO BS ARIHATSD USING AJTGiWS 3D STODIO.

Rote: This version only wpports 4 node elements.

s. 8. PRTBPSRR P. A. P. MRTIIS . . . . 12/5

InSTITwYO StlPmOR mnIc0 LImA, SmOGAL

29

M 31 32 C 33 c 34 c 35 c 36 C 37 :. c 39 c MC 41 42 13 c 44 c 15 c 46 17 c 4a c 49 c 50 51 52 C 53 c 51 c 55 MC 57 c MC 59 64 61 c 62 C 63 C 61 65 C 66 c 67 C 68 69 70 71 72 13 71 75 76 77 70 79 80 C a1 c a2 c 83 a4 a5 c 86 C

DIllBpIDl OlORD(2,lOW),UlOIkS(4,.lOO), 1 2

~~XRDF(9,(7tr3w),

--------_~__~~_~____________I________________________

NAImmAn --__~__~~~~~_~__~___~~~~_____~_______________________________

WRITS (6,lOOO)

*** choose arhtion lode1

IiWS (6400) RKAD (54 IwimL

*** Stap if 0

IF (In0DRL.E!l.O) SFOP

*** Inquire horizontal qnetry

RITE (6,3@30) WAD (5,*) InOizII

*** Stop if 0

IF (IRORIZ.Bp.0) SlVP

*** Chose file reading procedure

PITB (6,tCKQ) RRAD (s,*) IFPliw

*** Stop if 0

IF (1FPrKx.&p.0) SYOP

CALL DIWW (WOIN,MLBII,H0IE,NDFQI) IF (Ilt3DRL.Bp.l) TRE4

CALL HIRE (HFOIN,llliLXN,WIRS,l!DFOI, 1 ~,IJIODS,RDPOI,DIEDF,llDIi$ 2 IFPKc,IRORIX)

RLSBIP (IlmDSL.R4.2) TRRn CALL PAYTKPJI (HPOIll,HJL%,HDIRS,wwOI,

1 CWRD,LWO~,RDPOI,DIRDF,UDIRS, 2 IFPRE,IRORIz,COLOR)

EL% SrnP

RNDIF

*** The Prcqran stopped norwlly ( RNTER=erit)

WRITE (6,WQ) READ

*** Input/output data formats a7 c

88 1003 KHAT (60(/),79(‘-‘) I / I a9 1 7X,’ 30 STUDIO INTERFACE’,//, 90 2 7X.’ F 0 V./I. 91 3 7x;’ II R T A L F 0 R II I II G’,//, 92 I 7X,’ FINITE ELEMENT ARALYSIS’,/, 93 5 79(‘-1)) 91 c

95 m WT (Ill, % 1 7X,‘SKLECT AnIMTIcSl mDsL’,/,

97 2 7X,’ 1. wire franc w&l W’,/, 98 3 7X,’ 2. Pattern lode1 (2D)‘,//, 99 6 7X,‘fOR STOP AlUAYs: O’,/,

1M) 7 7X.’ Ci!OICR : ‘) 101 3@30 FOEAT ( 10: 1 7x, m YO0 u:w RExmTAL SYwTRY’,/, 103 2 7X.’ 1. iw.l 104 3 71;’ 2. YRS’,/, 105 I 71,’ CROICR : ‘) 106 4OOO FOIWT ( 107 1 7X,‘SELKT FILE UUDIBG F¶WEDUW,/, 108 2 7X,’ 1. Selective’,/, 109 110

3 7X,’ 2. Sequential’,/, I 7X.’ CmxCS : ‘)

111 5Km miaus (I/, 112 1 71,’ ASCII FILK : PLAST3l&ASC’,/, 113 3 71,’ SOWS rmLY CWTKD’,/, ilk I 71,’ IX DIRK¶ORY : c:\3w\Dl&RS’,

115 6 II, 116 7 71,’ PRESS WXR YQ BXIT : ‘) 117 c 118 SKI 119

Page 7: Animation of Finite Element Models of Metal Forming Processes

Animation of finite element models 991

120 121 122 c 123 124 c 125 c 126 c 127 C 12s 129 130 131 132 c 133 134 135 136 137 138 139 140 141 c 142 143 c 144 c 145 c 146 147 148 149 c

1% c 151 c 152 153 154 155 c 156 C 157 c 158 loo 159 c 160 c 161 C 162 163 164 165 ;: ,’

lb7 168 169 170 171 172 C 173 c 174 c 175 176 177 178 179 180 181 182 183 c 184 c 185 c 186 187 188 189 190 191 c 192 C 193 c 194 195 196 197 198 199 200 201 c 202 c 203 C 204 c 205 C 206 207 208 c 209 c 210 c

SDSRJUTIIIE DII(BI (wpOIlI,HELUI,IIDI,Ig,SDmI)

II4PLICIT WWLE FflECISIoll (A-w-1)

TIIIS .%@RDDTIYE O%FAIIlS TUB PXIWH DIMKllSIC4IS OF llle PRIIICIPAL ARRAYS

Hm1n=1000 HELpw=SCKJ nDIES=9 mmI=300

RWM ESD

SDI!RODTINE UIRE (Hl%IIi,%LEIl,HDIES,UDFOI, 1 ~,lAlDl’&,iiDIQI,DIEDF,NDIES, 2 1PPRcc,1nDR12)

IIIPLICIT MDSLB PRECISION (A-E,D-a) _______________________~_~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

TSIS SUKiWJTINB BOILDS A UIRE FPJJIE WIIL

DIUMSIOR CO3RD(2,WPOIN),IJlODS(4,RELE4l), 1 IIDFOI(WDIES),DIeDP(WDIES,(7t2’~1))

CRARACTER PILEWT*25

+** open output file

FILE0JT=‘C:\3DS2\IiMGES\‘//‘PLAST3DS.ASC’ OPEJI (DNIT=12,PILE=PILmDT,STATDS=‘DMK@I’)

WRITE (12,2@30)

*** Initialization for file reading prccedure

CciiTINDE

*** Selective file reading

IF (IFPKC.EQ.1) TIM WRITE (6,lMw)) READ (5,*) IFILE

IF (IFILE.BQ.0) TIM CLOSE (12) RETDRW

ENDIF ISFILE =IFILB IEFILE =IFILE IFILESTP=IFILE

**+ Sequential file read&

ELSEIF (IFPRCC.eQ.2) TNBB WRITE f6.11WI REM) is;*) IsFILE WRITE (6,lMo) RF,AD (5,*) IEFILE WRITE (6,1300) READ (5,*) IFILBSTP

WDIP

*** Reading input

W 6W IFILE=ISFILE,IEFILE,IFILESTP IREAD=IREADtl CALL INPUT (IFILE,IPOIN,RELUl,

I w0In,l(eLm,w~,t0mI,nDIFs, 1 ~RD,IJKOS,RDmI,DIKDF)

*** Writinq output

IF (IFIU.LE.9) TIIM WRITE (12,210o) IFILS

ELSEIF (IFILE.LE.99) TIM WRITE (12,220O) IFILE

ELSE

PITE (12,230O) IFILB WDIF

*** Sirinq the w&l

he* Vertical synetry line only

IiVERTBX=2*NmIIl NFACES =I*llBLB

*** Borizontel sywtry line

211 212 213 214 215 216 C 217 c 218 c 219 C 220C 221 222 223 224 225 226 227 110 22a c 229 c 230 c 231 232 233 234 235 236 120 237 C 238 C 239 C 240 241 c 242 c 243 C 244 245 246 247 248 249 130 25OC 251 c 252 C 253 254 255 2% 257 25a 140 259 200 26QC 261 C 262 C 263 C 264 C 265 266 267 268 269 270 271 272 273 274 275 210 276 C 277 C 278 C 279 280 281 2112 283 284 285 286 287 28s 22Q 289 c 290 c 291 c 292 293 C 294 c 295 c 296 297 2% 299 300 Ml

IF (IUDRIZ.eP.2) m MVERTEI=4*IKOIS IPACES =I*IlELBII

mIF PIT! (12,300O) RERTBX,lIF~

be* Vertex list

“e 1’st quadrant

WRITE (12,310O) w ii0 Imu=l,wpoIS

Ivmnx=Imu-l aapDT =cccw,~rn~n~ CoolMz =acm(2,ImuI) WRITE (12,32fM) IVERTEX,CCORDX,O3ORDI

K4lTItUlE

**’ 2’nd quedrant

In 120 ImIJl=1,nmIN Iv~x=nmIwImIn-l acmx =-l.+aci+iql,ImIn) CoDpDz =awz,Imn) h’RITE (12,3200) IVEp.TlX,KORDX,CCORDI

COnrIlmB

*et If borirontel synetry line

IF (IaORIZ.eQ.1) m 200

*** 3’rd quadrent

m 130 ImIN=l,nmIw IvmTux=2enmIStImIn-l CtmRDx =-l.*a0m(l,Imxn) aaw =-l.a4tD(2,ImIIq WRITE (12,320o) I~,cooRDX,CCORDI

OMFIIIUE

*** 41th quadrant

m 140 ImIw=l,wFoIn IVERTex=3*IlmI*ImIN-l CooRDx =awRD(l,ImIS) mORDa =-i.ao~~(2,ImIn) VllITE (12,3Mo) ~,mOPDX,C

CQl?miDK 03UFINLQ

*** Face list

*** 1’st quadrant

WRITE (12,4OC@) m 210 IEL~~I=~,YBLW

IFACE =IEl#l IFACE2 =liIILMtIBLBI-1

IvEIiTaX1=IJ0lql,Is)-l IVEli?BX2=LKWIE(2,IM)-1 IVEIi’fEX3=IKU(3,ISLH)-1 IvmTEx4=lJ0Is(4,IELRI)-1 WRITE (12,IlW) IFACKl,IvBR?EXl,IY2,IvERT~X3 YRITE (12,003) IFACE2,UERTKX3,IMRnX4,IIIpRTBX1

CONTINUE

*** 2’nd quedraat

m 220 IELX4l=1,YELM IFACE =24KMtIELBkl IFACR2 =3WLBltIgLBI-1 IvXRmxl=mRtum(l,Iwl)-1 IVERm2=mIRtuoDs(2,Im)-1 IVmmx3~Int~(3,Im)-1 IVmx4=lmnltuoDs(4,Im)-1 VRle (12,410o) I?m,~,Ixl,ImBx4 HRIVE (12,410o) IPACK2,IVBTRX4,IWRTH3,IV~X2

amVIlmm

*** If borirontal qmetq line

IF (IEGW.BQ.1) COXO 300

l ** 3’rd quadrant

m 2~ mu=l,mtm IPml =4-I-l IPAm =wm#t1m1 IVKTEXl=~~(l,Im)-1 IwmX2=2mmtlJ.m(2,Im)-1 IVBRTBX3=2WKWtuoS(3,1~)-1

Page 8: Animation of Finite Element Models of Metal Forming Processes

998

302 303 304 305 230 306 C 307 c 308 c 309 310 311 312 313 314 315 316 317 318 240 319 300 320 C 321 C 322 C 323 324 325 326 327 C 328 C 329 C 330 c 331 c 332 333 334 c 335 c 336 C 337 338 339 340 341 c 342 c 343 c 344 345 c 346 C 347 c 348 349 350 351 352 353 354 355 356 357 310 358 359 L 360 C 361 362 363 364 365 366 367 368 369 320 370 c 371 c 372 C 373 374 c 375 c 376 C 377 378 379 380 381 382 383 384

385 330 386 387 c 388 C 389 390 391 392

IVERTEX4=2*NmINt~(4,IELFJl)-1 WRITE (12,4100) IFACRl,IVERTEXl,IVERTEXZ,IVERTEX3 WRITE (12,410o) IPACR2,IVERTEX3,IVERTBX4,IVERTEXl

CCHTIHUE

*‘* l’th quadrant

W 240 IELEII=l,NELM IPACE =6*NELB(rIELF#-1 IPACE -7*NELRUtIELEW-1 IVERTEX1=3*WPOIN%!iODS( l,IELW)-1 IVERTEX2=3*NmINtL(2,IELBl)-1 IVERTEX3=3*NIQINtLNODS(3,IELEIl)-1 IVERTEX4=3*NmINMODSnons(l,IeLBI)-1 WRITE (12,410o) IPACCB1,IVRRTEX2,IVERTRTEXl,IVKRTEX4 WRITE 112.41001 IPACE2.IVRRTEX4.IVERTEX3.IVRRTEX2

CGilTIWUE CONTINUE

*** DIES

W 500 JDIES=l,NDIES LDIF.S=1000*JDIFSiIPILE WRITE (12,240O) LDIES NPlwKrnI(JDIRS)

*** Sizing the model (DIES)

*** Vertical synnetry line only

NVERTEX=4*NF’N NFACES =Z*NFTU

*** Uorizontal synwtry line

IF (IHORIZ.EQ.2) THEN NVERTEX=S*NPM NFACES =4*NFl0

ERDIF

*** Vertex list (DIES)

WRITE (12,300O) NVERTEX,NPACES

IVERTEX=O IQ 310 IPTO=l,NPm

IFml =2*1Pm IVERTEX=IPm-1 CCORDX =DIEDF(JDIES,IPMl-1) mORDZ =DIRDF(JDIES,IPml) WRITE (12,320O) IVEIiTEX,CWRUX,COORDZ IVERTEX=IPN-1tNF’N WRITE (12,320O) IVERTEX,COORDX,aX)RDZ

CuiiwUE

Dl 320 IPm=1,NFlu IPml =2*1Pm IVERTEX=IFKI-lrZ*W KORDX =-l.~DIEUP(JDIES,IPl-1) c(oRDZ =DIRDF(JDIEs,IpTo1) WRITE (12,3Mo) IVBRTEX,co3RDX,CCORDZ IVERTEX=IFl’O-1+3*NP WRITE (12,320O) IVRRTEX,COORDX,CC0RDZ

CONTINUE

*** If horizontal syuetry line

IF (IUORIZ.EQ.l) GOTO 400

w 330 IPm=1,wm IPSO1 =2*1F?O IVERTEX=IP’IO-lt4t CCORDX =-l.*DIRDF(JDIES,IPNl-1) KORDZ =-l.*DIRDF(JDIFS,IFlQl) WRITE (12,320o) IVERTEX,COORDX,CWRDZ IVERTEX=IPlO-ltS*NFlYJ WRITE (12,320o) IVRRl’EX,CMIRDX,CZ

CONTINUE

**t I’th quadrant

w 340 IPm=l,NPm IFml -2’IPm IVEAEX=IFIO-lt6’HF’N CUORDX =DIEDF(JDIES,IF’IOl-1)

S. B. Petersen et al.

393 394 395 396 397 340 398 400 399 c 400 c 401 c 402 c 403 c 404 405 406 407 408 409 410 411 412 413 414 415 410 416 C 417 c 418 C 419 420 421 422 423 424 425 426 427 428 429 420 430 c 431 c 432 C 433 434 c 435 c 436 C 431 438 439 440 441 442 443 444 445 446 447 430 448 c 449 c 450 c 451 452 453 454 455 456 457 458 459 460 461 440 462 500 463 6M1 464 C 465 C 466 C 467 468 C 469 C 470 c 471 472 C 473 c 474 c 475 1wo 476 1100 477 12wl 478 1300 479 c 480 ZMX) 481 2100 482 2xN) 483 2300

MxlRDZ =-1.*DIRDF(JDIES,IPIOl) URITE (12,320O) IVERTEX,CC0RDx,C%%DZ IVRRTEX’IPIO-lt7*N WRITE (12,320O) IVERTEX,COORDX,COORDZ

CONTINUE CONTINUE

*** Face list (DIES)

it* l’st quadrant

WRITE (12,400O) w 410 JDrnI=l,NFTO

IFACEl =JDmI-1 IvwrRxl=~mI-1 IVERTEXZ-JDmI IVERTEX3=NPKHJDmI IF (JDmI.EQ.HpTo) TEEN

IVERTEXZ-0 IVERTEX3=NeTO

EHDIF WRITE (12,420O) IFACE1,IVERTEX1,IVEREX2,IVERTEX3

CCiiTINUE

W 420 JDmI=l,NFTO IFACEl =RT’lOtJDmI-1 IVERTEX1=2*NPIC+JDmI-1 IVERTEX2=2*1CFl’CtJDkC! IVRRTEX3=3*NPTO+JDmI IF (JUmI.BQ.wpTo) TERN

IVERTEX2=2*NPN IVRRTEX3=3*NP’N

ERDIF WRITE (12,420O) IFACEl,IVRRTEX1,IVWTEX2,IVERTEX3

CGYTINUE

*** If horizontal synwtry line

IF (IEORIZ.EQ.1) GOPI 500

*** 3’rd quadrant

w 430 JDrnI=l,NFN IFACEl =2*NPlMJDmI-1 IVERTEXl=l*NF?OtJDmI-1 IVERTEX2=4*WI IVERTEX3=5*RPIOtJDmI IF (JomI.eQ.wm) TRW

IVRRTEXZ=I*NPIO IVF.RTEX3=5*NF’M

FJIDIF WRITE (12,420O) IFACEl,IVERTEXl,IVERTEX2,IVRRTEX3

CMTINUE

*** 4’th quadrant

W 440 JDmI=l,NPTU IFACEI =3*NPlC+JDmI-1 IVERTEX1=6*NPK%IDmI-1 IVERTEX2=6*NPTOtJDmI IVERTEX3=7*NFIOIJDmI IF (JDmI.EQ.HpM)) TREN

IVERTEX2=6*NPN IVERTEX3=7*NPN

MDIF WRITE (12,420O) IFACEl,IVERTEXl,IVERTEX2,IVERTEX3

O3HTINUE CCUTINUE

CONTINUE

*** Read next selective file

IF (IFPR~C.EQ.~) wm loo

*** Close output file

CLOSE (12)

*** Input/output data fonats

rnlwT (/,7X,’ IHWT FILE FEN?.CUT FOMAT ( 7X,’ START FILE NUHBER FQl?.CNT mFJUT ( 7X,’ END FILE HlMRR FEU?.OUT m#tAT ( 7X,’ FILE STEP

PORlUT (‘AUBIENT LIGBT COLOR: R&l CRBBY=l BLUE-l’) MmAT (/,‘liAwD U&J&T: “FEll’,Il,‘“‘) POWUT (/,‘NAHRD OglRC?: ‘FB’,Il,“‘) FORHAT (/,'UMED OEJECT: "W',IJ,'"')

: ‘)

j 1; : ‘)

Page 9: Animation of Finite Element Models of Metal Forming Processes

Animation of finite element models 999

484 2400 FUMAT (/,‘NAMD C&W?: ‘DIB’J4,“‘)

4a5 C 486 3Om FoRnAT (%I-IWH, vi,Rr1cBS: ‘.I& WBs: ‘.14)

487 3100 FiMAT (‘VMTBX LlST:‘) 488 3200 FOFJW (‘VBRTBX ‘,II,’ X: ‘J12.4, 409 1 ’ y: O.oMx)‘,’ a: ‘J12.4)

490 c 491 IOOU FOMT (‘PA0 LIST:‘) 492 4100 FQidUT (‘FACB ‘,II,‘: A: ‘,II,’ 8: ‘,I(,’ C: ‘,I(, 493 1 ’ An: 1 EC: 1 CA: O’,/, 494 2 ‘HATERIAL: WITS YIRBFFANE”‘) 495 4200 FORNAT (‘FACE ‘,II,‘: A: ‘,I(,’ B: ‘,I(,’ C: ‘,II, 496 1 ’ an: 1 Bc: 1 CA: l’,/, 497 2 ‘NATFRIAL: ‘BLUE YIRBFRME”)

498 c 499 RE!rDM

5GQ BND 501 502 503 504 SULlROUTINE PATTBRN (WaIW,UBLWlDIBs,HDPOI, 5.95 1 CWRD,LNW,IDPOI,DIBDF,llDIRS, 506 2 IFPRCC,IBoRI~,CUIJ3il)

M7 c 508 IWPLICIT WJBLE PRECISION (A-W-2) 509 C _______________________________________________ _~~~~_~~~~~__ --

510 c THIS SUWUTINE BUILDS A PAI’TBRN WDEL 511 C __________________________ _____ _ ____-_ ____ _______ -----_-------

512 DINBNSION aXIRD( 2,NFUIN) ,WKIDS(I,NELBI), 513 1 ND~I(~!DIRS),DIBDF(HDIES,(~~~WJ~I)), 514 2 COLIIR(NBLBI)

CRARACTER FILEWT*25 515 516 C 517 c 518 c 519 520 521 522 C 523 C 524 C 525 100 526 C 527 C 528 C 529 530 531 532 533 534 535 536 537 538 539 c 540 c 541 c 542 543 544 545 546 547 548 549 550 c 551 c 552 c 553 554 555 556 557 c 558 c 559 c 560 561 562 563 564 565 566 567 c 568 c 569 c 570 c 571 c 572 573

*A* Open output file

FILWUT=‘C:\3DS2\INAGBS\‘//‘PUST3DS.hSC’ OPEN (UliIT=l2,PILE=PILKYJT,STAlQS=‘UNWW) WRITE (12,2OKI)

*** Initialization for file reading procedure

CQNTINUE

*** Selective file reading

IF (IFPRCC.EQ.l) TEEN WRITE (6,lOOO) READ (5,*) IFILE

IF (IFILE.BQ.0) TEEN CLQSE (12) RETURN

BNDIF ISFILE =IFILE IEFILE =IPILE IFILE.STP=IFILE

*** Sequential file reading

ELSEIF (IFPRW.EQ.2) TREN URITE (6,llW) READ (5,‘) ISFILE WRITE (6,120o) READ (S,*) IEFILE WRITE (6,130o) READ (5,*) IPILESTP

FJIDIF

*** Reading input

M 300 IFILE=ISFILE,IEFILE,IFILeSTP CALL IWJT (IFILB,!&QIIW,llBLH,

1 nmIw,nBLE4l,wDIBs,HDmI,NDIBs, 2 CCW,MDS,NDmI,DIFDF)

*** Writing output

IF (IFILE.LE.9) TEEN YRITE (12,2100) IFILE

ELSEIF (IFILR.LE.99) TBEli RTtITR (12,220o) IFILE

ELSE WTE (12,230O) IFILE

R4lDIF

*** Siziq the lode1

*** Vertical syuetry line only

NWTEX=2*WPOIN NFACES =I*NBLPII

575 c 576 c 5n 578 579 580 581 c 582 C 503 c 534 585 c 586 C 587 c 588 589 590 591 592 593 594 110 595 c 596 C 597 c 598 599 600 601 602 603 120 604 c 605 c 6&C 607 M)a c bO9C 610 C 611 612 613 614 615 616 130 617 C 618 C 619 C 620 621 622 623 624 625 140 626 MO 627 C 628 C 629 C 630 631 c 632 C 633 C 634 635 636 637 638 639 640 641 642 C 643 C 644 C 645 646 647 648 649 650 651 652 653 201 654 202 655 6% 657 658 659 H)3 660 2Q5 661 662 663 664

*** Borirontal syaaetry line

IF (IBMIS.BQ.2) TBKH nVBRTRx=4’nmIli NFACES =8*WELW

FNDIF

*** vertex list

WRITE (12,3ooO) NWMBX,NFACEs

*** l’st quadrant

WRITE (12,310O) W 110 ImIN=l,llPDIN

IVBRTEX-ImIN-1 ClxwDx ~(1,IrnIlI) CWRDZ =aoRD(2,IFoIH) hWTE (12,32C@) IvBRTEX,UXlRDX,CWDZ

CONTINUE

W 120 ImIN=1,IIpoIN IVERTEX=NPOINtImIH-1 aoRDx =-l.*ozoRD(l,ImIn) COORDZ =ww2,ImIn) WRITE (12,3xX)) IVBRTEX,WRDX,COOE(DE

@UCINlM

*** If horizontal syaaatry line

IF (1EORIMQ.l) GOKJ MO

Do 130 IrnIN=l,HmIW IVBRTEx=2*llmIHImIn-1 m~t~x =-3 .*ozm(l,ImIr) CWJRJX =-l.wlRD(2,IWIll) WRITE (12 32v3) IV5zX Cc#Jx oY3mi

amPJE’ , I

w 140 ImIn=l,nmIn Iv~x=3wo~tImIw-l acmx =kwRD(l,ImIn) aaRDa =-l.Kcc%D(2,ImIl) WRITE (12,3200) IVBR?EX,CWDX,COORDE

CtXlTIiiUB @JNTINUE

*** Face list

WRITE (12,tCW~)

*** 1% qa&aat

Ill 210 IEL~=l,YELpII IFACE =IEL&l IFACE =llBLWIBw#-1

IVBRTEX3=LJW(3,IEWl)-1 IW.TEXI=IJ#%I4.IELBII)-1

*** Building chegwred pattern

IF (IELMQ.1) Gom 205 m 203 JBLBI=l,IELE#

ISlL4PJ=O

D3 202 IWDB=1,4 w 201 JlwDE=1,4

IF (uoDs(IrooE,IELw).ep.Lwow(Jroos,JE~)) TEEN ISBARX=ISuREt1

RNDIF CWTIiiUE

COWTHUs IF (ISJlARB.GB.2) TBKN

CuUlR(IBLBI)~uJR(JELBl)*(-1.) GDTO 205

BWDIF KdiTINUE CiWfINUB IF (coLoR(1BLtOl).B~.1.) TBBY

RITE (12,4100) IFACB~,I~BRTKX~,IVER?B~~,IVBR~BX~ WRITE (12,41&l) IFACB2,IVERTBX3,IVRRTXX4,IVBR?BX1

BLSBIF (COIOR(IBLIGl).UJ.-1.) m .____ .._ .___. -.... --.

665 WITL; ,12,42w) IFACE~,IWRTBX~,IVBRTBX~,IVBRTBX~ 574 c

Page 10: Animation of Finite Element Models of Metal Forming Processes

1000 S. B. Petersen et al.

666 667 668 210 669 C 670 C 671 C 672 673 674 675 676 677 671 679 680 681 682 683 684 685 686 687 220 688 C 689 C 690 C 691 692 C 693 C 694 C 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 230 711 c 712 C 713 c 714 715 716 717 718 719 720 721 722 723 724

725 726 727 728 729 2W 730 3w 731 c 732 C 733 c 734 135 c 736 C 737 c 738 739 c 740 c 741 c 742 1wO 743 11w 744 1200 745 13MI 746 C 747 2wo 748 2100 749 2Mo 750 23cQ 751 c 752 3ooO 753 ml0 754 32w 755 I 756 C

WRITE (12,4200) IPACE2,IVERTEX3,IVBRTEX4,IVERTEX1 EI(DIF

COWTINUE

757 4MKl WI&AT (‘FACE LIST:‘) 758 4100 PoRluT (‘FACE ‘,II,‘: A: ‘.II.’ B: ‘<II.’ C: ‘.II. 759 1 ’ AB: 1 PC: 1 CA: l’,/, 760 2 ‘HATERIAL: ‘WRITE MATTE”‘) 761 42W FQFHAT (‘FACE ‘.14.‘: A: ‘.I(.’ B: ‘.I(.’ C: ‘.II.

Do 220 IELEN=l,NELM IPACE =2*NELRItIELEl4-1 IPACCE2 =3*NELWtIELlM-1 IVERTEXl=l(wIN+LMDS(1,IELBl4)-1 IVERTEX2=NFOINtWIODS(2,IELa+o-1 lVRRTEx3=NmwloDS( 3,IFJxl4)-1 IPESTEX~=NPO~U+LW~DS(~,I~IMI-~ coLoR(IELB()=-l.+COlOR(IELEli) IP (03LOR(IELKl4).EQ.l.) TBW

WRITE (12,41CQ) IFACCB1,IVKRTBX2,IVERTEXl,IVERTEX4 WRITE (12,410O) IFACE2,IVBRTEXP,IVBRFEX3,IVER?EX2

ELSEIF (CUlOR(IBL~).BQ.-1.) TBEN WRITE (12,42W) IFACE1,IVERTEX2,IVBRTEXl,IVERTEX4 WRITE (12,420O) IPACE2,IVKRTEX4,IVKRTEXJ,IVERTEX2

ENDIP CCNTINUE

’ hB: 1 Bc: 1 a: 1;,/, ’ 762 1 763 2 ‘RTERIAL: ‘RED MATTE”) 764 C 765 ReTURN 766 END 767 768 769 SUBRWTINE INPUT (IFILE,NFOIN,NBLBI, 770 1 HFOIN,HBW,HDIRS,l4DF0I,NDIES, 771 2 CCORD,LlK0S,NDIQI,DIEDF) 772 C 773 IHPLICIT WUBLE PRECISION (A-&O-a) 174 c ________________________~~~~~~_________----~~~~~______-------~

775 c THIS SUBROUTINE READS TIIE INPiJT DATA FILES 776 C ________________________-------________-----_--_______--------

777 DIHENSION CMRD(2,HWIN),LllODS(r,llEL04), 778 1 NDWI(WDIES),DIEDF(HDIES,(7t2~HDWI))

*** If horizontal symmetry line

IF (IBORIZ.EQ.l) GOTO 300

*** 3’rd quadrant

W 230 IELt%=l,NELER IPACE =4*NELBHtIRLW-1 IPACE =5*NELWtIELBI-1 IVBRTEX1=2%OINtLNOD5(l,IELB!4)-1 IVERTEX2=2~NF0INtLNODS(2,IELW)_1 Iv~EX3=2~wPoIwtl(3,1~~~-1 IVERTEX4=2*NPOINtW(4,IEL~)-1 COlM(IRLet)=-l.t(IELBl4) IF (coLoR(IE~ew).EQ.l.j Tmi

WRITE (12,410O) IFACE1,IVERTEXl,IVERTEX2,IVERTEX3 WRITE (12,410O) IFACCE2,IVERTEX3,IVERTRX4,IVERTEXl

ELSEIF (COLOP.(IELW).t!Q.-1.) TBFAI WRITE (12,420O) IFACCE1,IVERTEX1,IVERTEX2,IVERTEX3 WRITE (12,420O) IPACE2,IVERTEX3,IVEREX4,IVERTEX1

ENDIF CONTINUE

*** I’th quadrant

D3 240 IELEH=l,NELEII IPACE =6*NELBltIELEH-1 IFACE =7*NELEWtIELEH-1 IVFRTEX1=3*NlQINtLNoDS(l,IELEU)-1 IVERTEX2=3*HWINtLWODS(2,IELM)_1 IVeRTEX3=3*NFQINtLNoDSoDs(s,reLw)-1 IVERTEX4=3*NFUINtLNODS( 4,IELEH)-1 COUIR(IELWI=-l.*COUIRlIELWI IF (&LOR(IkLD4).EQ.l.~ TEEN’

WRITE (12,410O) IFACEl,IVKRTEX2,IVERTEX1,IVERTEX4 WRITE (12,410O) IPACE2,IVF.RTEX4,IVERTEX3,IVERTEX2

ELSEIF (CULOR(IELEH).EQ.-1.) TREN WRITE (12,420O) IFACE1,IVERTEX2,IVERTEX1,IVERTEX4 WRITE (12,4200) IFACE2,IVERTEX4,IVERTTeX),IVERTEX2

ENDIF mcIN!lE

CONTINUE

779 c 780 781 782 C 783 c 784 c 785 786 787 788 789 790 791 792 793 794 795 c 796 797 798 c 799 a00 801 C 802 c a03 c a04 a05 a06 loo 807 C 808 so9 c 810 c 811 C 812 al3

*** Read next selective file

IF (IFPRoc.EQ.1) GOTO 100

I0 200 IKLW=l,NELEW RRAD (ll,*) JELBI,WODS(l,JBLEl4),MDS(2,JELW),

814 1 LIKIDS(~,JBLBII),LIKIDS(I,JELBI)

al5 2oo 03NTINUE 816 c 817 c *** Read dies

818 c 819 READ (ll,*) NDIES 820 C a21 Do 300 IDIES=l,NDIES a22 RHD (ll,*) JDIES,NDFOI(JDIFS) 823 Nm=NDmI(JDIaS) a24 c 825 w 300 IFi”G=1.Nm

a** Close output file

CLOSE (12)

*** Input/output data for&s

FMT (/,7X,’ INWT FILE FtN?.WT : ‘)

FCMT ( 7X,’ STAR! FILK NUMBKR FH?.VJT : 'I FCRJIAT ( 7X,’ END FILE NUHBER FBw?.oDT : ‘)

F’%MT ( 7X,’ FILE STBP : ‘)

FoRMAT (‘AKBIBNT LIGET COLOR: RBD=l GREW=1 BLOE=l’i f#MF (/,‘NAHBD CIUBCT: ‘FB’,Il,“‘) WWUT (/,‘NMBD CBTEC?: ‘FBH’,I2,“‘) FoMAT (/,‘liMED OBIBCT: ‘FpII’,I3,‘“‘)

a26 827 a28 3w a29 c 830 c 831 c a32 a33 c 834 c a35 c 836 a37 a38 c a39 c 840 c a41 400 WRITE (6,200O) PILFMX a42 Cum (121

FOFMT (‘TRI-IIKSR, VBRTICRS: ‘,I(,’ FACE: ',II) FOWIAT (‘VBH’RX LIST:‘) FWNAT (‘VERTEX ‘,II,’ X: ‘,F12.4,

I ’ Y: O.oMx)‘,’ a: ‘,F12.4)

ski STOP

a44 c 845 c *** output data fonat

a46 c a47 1OW FOIUUT (

CRARACTER TITLE*80 CBAMCTER FILEAUX*l2,FILEIN*25,NSTP1*1,NSTP2*2,NSTP3*3

*** Input file

IF (IPILE.LE.9) TBEN WRITE (NSTPl,‘(Il)‘) IFILE FILEAUX=‘FEU’//NSTPl//‘.‘//‘GKS’

ELSEIF (IPILE.LE.99) TREN WRITE (NSTPZ,‘(IZ)‘) IFILE PILF,AUX=‘Pt%‘//NSTP2//‘.‘//‘GKS’

ELSE WRITE(NSTP3,‘(13)‘) IFILE FILEAUX=‘FE4’//NSTP3//‘.‘//‘GKS’

ENDIF

FILKIN=‘C:\ACAD\PLAF2D\‘//FILEAUX OPEll(!l!4IT=11,FILE=FILEI!4,STATUS=’@LB’,ERR=4OO)

READ (ll,‘(AaO)‘) TITLE READ (11,‘) NFQIN

*** Read coordinates

W loo IFOIN=l,I(POIN READ (Il.*) JPoIN,C~RP(l,JwIN),cooRorz,Jwrwl

CUKTlNUE

READ (11,‘) NELEH

*** Read topolcqy

1PIo1=2*1PI+J RPD (ll,*) DIEDF(JDIBS,IFlOl-1),DIKDF(JDIES,IPIOl)

CONTIINE

*** close current GKS file

CMSE (UNIT=ll)

t*t Reading of file complete

WRITE (6,lOW) FILEAUX RETURN

Page 11: Animation of Finite Element Models of Metal Forming Processes

Animation of finite element models 1001

848 1 7X,’ FILE READ : ‘,AlO) NODAL POINT 2

819 Zoo0 FWIAT I/, 850 1 7X,’ FILE WES tm EXIST : ‘,h12,/)

851 c no. OF eLWmS

852 RETURN Emlml’ 1 FIRST NODE SECCND mlDE THIRD NODE FODRTH NODE 853 END ELmtT 2

APPENDIX C: INPUT FILE

TITLE NO. OF lt3DAL FOIRTS NODAL WINY 1 X-WSITION Y-POSITION

NO. OF DIES DIE NO. 1 NO. OF WODAL POINTS X-POSITION (WODE 1) Y-WSITIOW (IIODE 1) X-POSITION (MDE 2)

DIE NO. 2