[430] | 1 | <head> |
---|
| 2 | <title>ESAVE</title> |
---|
| 3 | <!-- Changed by: Hans Grote, 13-Sep-2000 --> |
---|
| 4 | <!-- Changed by: Werner Herr, 19-Jun-2002 --> |
---|
| 5 | <!-- Changed by: Hans Grote, 30-Sep-2002 --> |
---|
| 6 | </head> |
---|
| 7 | |
---|
| 8 | <body bgcolor="#ffffff"> |
---|
| 9 | |
---|
| 10 | <h1>ESAVE: Save Machine Imperfections and read back from file</h1> |
---|
| 11 | |
---|
| 12 | <br> |
---|
| 13 | <b>Writing errors to a file:</b> |
---|
| 14 | <br> |
---|
| 15 | This command saves a table of errors assigned to elements on a file, |
---|
| 16 | using a format which can be read in again to obtain the same results. |
---|
| 17 | This allows dumping the errors and reloading them after a new USE command. |
---|
| 18 | The range for these elements has to be specified. |
---|
| 19 | An error save is requested by the statement |
---|
| 20 | <pre> |
---|
| 21 | ESAVE,FILE=string; |
---|
| 22 | </pre> |
---|
| 23 | <font COLOR="#ff0000"> |
---|
| 24 | <pre> |
---|
| 25 | Example: |
---|
| 26 | |
---|
| 27 | SELECT,FLAG=ERROR,RANGE=range,CLASS=name,PATTERN=string; |
---|
| 28 | ESAVE,FILE=err.file; |
---|
| 29 | </pre> |
---|
| 30 | </font> |
---|
| 31 | and elements selected by the |
---|
| 32 | <a href="../Introduction/select.html">SELECT</a> command are saved to the file. |
---|
| 33 | <br> |
---|
| 34 | <br> |
---|
| 35 | To save the errors of all elements to a file, one can use: |
---|
| 36 | <font COLOR="#ff0000"> |
---|
| 37 | <br> |
---|
| 38 | <pre> |
---|
| 39 | SELECT,FLAG=ERROR,FULL; |
---|
| 40 | ESAVE,FILE=err.file; |
---|
| 41 | </pre> |
---|
| 42 | </font> |
---|
| 43 | <br> |
---|
| 44 | <br> |
---|
| 45 | <b>Please note: in case of field errors, the absolute errors are saved and not relative errors. </b> |
---|
| 46 | <br> |
---|
| 47 | <br> |
---|
| 48 | <br> |
---|
| 49 | <b>Setting errors from a table or file:</b> |
---|
| 50 | <br> |
---|
| 51 | To assign errors from a file is not a priori straightforward. |
---|
| 52 | It may be required to re-assign existing errors after a <b>USE</b> |
---|
| 53 | command was executed (which deletes all errors attached to a |
---|
| 54 | sequence). |
---|
| 55 | <br> |
---|
| 56 | Errors stored in the form of an internal table (<i>errtab</i>) can |
---|
| 57 | be directly attached to the |
---|
| 58 | appropriate positions in the sequence with the command: |
---|
| 59 | <pre> |
---|
| 60 | SETERR,TABLE=errtab; |
---|
| 61 | </pre> |
---|
| 62 | The table <i>errtab</i> can be generated internally or from |
---|
| 63 | an external file (<i>errfile</i>) with the generic command READMYTABLE. |
---|
| 64 | <br> |
---|
| 65 | The command sequence: |
---|
| 66 | <pre> |
---|
| 67 | READMYTABLE,file=errfile,table=errtab; |
---|
| 68 | SETERR,TABLE=errtab; |
---|
| 69 | </pre> |
---|
| 70 | reads the file <i>errfile</i> into the table <i>errtab</i> and |
---|
| 71 | the command SETERR attaches the errors to the elements in |
---|
| 72 | the active sequence. |
---|
| 73 | <br> |
---|
| 74 | The file <i>errfile</i> can be produced by a preceding ESAVE command |
---|
| 75 | or any other utility. It should follow the format of a file generated |
---|
| 76 | with ESAVE (see example program). |
---|
| 77 | <br> |
---|
| 78 | <b>Please note: </b> |
---|
| 79 | <br> |
---|
| 80 | 1. To assign correctly the errors from the file to the elements in the sequence, |
---|
| 81 | all elements must have individual names, otherwise an identification is not possible. |
---|
| 82 | Elements in the file not identified in the active sequence are ignored. |
---|
| 83 | <br> |
---|
| 84 | 2. Errors are assigned to ALL elements found in the file and the FLAG=ERROR is set. |
---|
| 85 | Therefore the number of elements selected corresponding to a command like: <br> |
---|
| 86 | SELECT, FLAG=ERROR,...;<br> |
---|
| 87 | can be different after the execution of SETERR. |
---|
| 88 | <br> |
---|
| 89 | <br> |
---|
| 90 | <br> |
---|
| 91 | <br> |
---|
| 92 | <address> |
---|
| 93 | <a href="http://consult.cern.ch/xwho/people/1808">Werner Herr</a> |
---|
| 94 | 18.6.2002 |
---|
| 95 | </address> |
---|
| 96 | |
---|
| 97 | </body> |
---|