Keywords: ccx

Next: allocate Up: Allocation of the fields Previous: openfile Contents

### readinput

This subroutine reads the input and stores it in field inpc. Before storing, the following actions are performed:

- the blanks are deleted
- all characters are changed to uppercase except file names
- the comment lines are not stored
- the include statements are expanded

Furthermore, the number of sets are counted and stored in nset_, the number of lines in inpc are stored in nline. The variable nset_ is used for subsequent allocation purposes. Finally, the order in which inpc is to be read is stored in the fields ipoinp and inp. Indeed, some keyword cards cannot be interpreted before others were read, e.g. a material reference in a *SOLID SECTION card cannot be interpreted before the material definition in the *MATERIAl card was read. The order in which keyword cards must be read is defined in field nameref in subroutine keystart.f. Right now, it reads:

1. *RESTART,READ
2. *NODE
3. *ELEMENT
4. *NSET
5. *ELSET
6. *TRANSFORM
7. *MATERIAL
8. *ORIENTATION
9. *BEAM,SHELL,SOLID SECTION
10. *SURFACE
11. *TIE
12. everything else

This means that *RESTART,READ has to be read before all other cards, then comes *NODE etc. The way inpc is to be read is stored in the fields ipoinp and inp. The twodimensional field ipoinp consists of 2 columns and nentries rows, where nentries is the number of keyword cards listed in the list above, i.e. right now nentries=12. The first column of row i in field ipoinp contains a row number of field inp, for instance j1. Then, the first column of row j1 in field inp contains the line number of field inpc here reading for keyword i should start, the second column contains the line number where reading should end and the third column contains the line number in field inp where the reading information for keyword i continues, else it is zero. If it is zero the corresponding row number in inp is stored in the second column of row i in field ipoinp. This structure uniquely specifies in what order field inpc must be read. This is also illustrated in Figure 47

Figure 47: Reading the lines for keyword entry i

Next: allocate Up: Allocation of the fields Previous: openfile Contents