Next: Functions Up: The Language Previous: How to Leave

### Defaults for Parameters

1. Parameters that name an ID :

   ID is the name for a data object (point, line etc.).

   A complete ID consists of the number or the name of the part in which the object is, a type designation (= type cast) and a sentence number:

              [partnum|objecttype]recordnum

   or

              [partnum][objecttype]recordnum

   e.g.:

              [1|Point]10 ( = point 10 in part 1 )

   The number of the part is not necessary in case the object lies within the active part.

   Instead of the number of a part you may also put in the name of the part:

              CREATE PART BLW ... ; NA = part1 !
              CREATE LINEARDIM BTWP ... ; NA = length !
              ACTIVATE PART part2 !
              MODIFY NOMINALSIZE length2 ; [part1]length !

   The object type is not necessary in case the parameter accepts only one type or if the type is the first one in the internal list of the interpreter.

   As an alternative to this setting the name of an object may be put in.

   e.g.:

              CREATE POINT CAR ... ; NA = P1 !
              CREATE LINE PP P1 ; ... !

   In case small letters are absolutely necessary you have to put them into inverted commas:

              CREATE POINT CAR ... NA = "p1" !

   Another possibility of naming is the use of a number function.

   e.g.:

              CREATE CIRCLE CTRR IDCTRCIR(1); ... !

   A circle is created the center of which is the center of circle 1.

   With interactive inputs the common proceeding of naming of objects is however the identification of objects with the left mouse key in the graphics window. This input method is only necessary for answering macro questions (see chapter 'language modules only for macros').

   Some commands require in addition to the ID of the object statements on the position at which the object has been identified and the number of the graphics window in which the object has been identified. These statements are put in brackets and are placed behind the ID of the object.

   e.g.:

              CREATE LINEARDIM BTWR [LINE]1 (100,100;0) ...

   During the identification of line 1 the cursor had the position 100, 100 and 0 in the graphics window. As you can see from the example co-ordinate and window number are separated by a semicolon. If the object is a point, the co-ordinate may be left out being a superfluous information here.

   For programming macros the necessary pick information has to be added. However, it is not possible to calculate the co-ordinate as formula. In case the exact position is not known, you can put in extreme values.

   e.g.:

              CREATE LINEARDIM BTWR [LINE]1 (-1e10,0;0) ...

2. Parameters that name a co-ordinate

   A co-ordinate consists of a number for the x-position, a comma and a number for the y-position.

   The usual input for a co-ordinate during interactive work is the positioning at cursor position. For this purpose the second mouse key can be used. In case the user works with the pick radius the first mouse key is suitable for positioning.

   Formulae can be put in either for the x- and y-value or for the entire co-ordinate.

   e.g.:

              CREATE LINE PP XPNT(1),200 ; ...
              CREATE LINE PP 100,YPNT(2) + 10 ; ...
              CREATE LINE PP CADD( XYPNT(1) ; 100,100 ); ...
              CREATE LINE PP [VARIABLE]1 ; ...

   In example 1 the x-value of the starting point is the x-value of point 1.

   In example 3 a co-ordinate function is used to add the position of point 1 and the co-ordinates 100,100.

   In example 4 the starting point is calculated from the co-ordinate variable 1.

   co-ordinates are received by identification of a point found in the snap mode. The system adds maximally two object IDs to snap mode co-ordinates, which have been important for the selection of the co-ordinate.

   e.g.:

   The correct input for the identification of an intersection between line 1 and circle 2 is

              100,200 ( [LINE]1 , [CIRCLE]2 )

   The named objects are useful when the system works in the autoconstraint mode. In this case the found position constraints of newly created elements will be saved with the named objects. In this example the point would have the constraint point position on the lines twice.

3. Parameters set with real numbers

   Real numbers either are to be put in directly (e.g. 1,234, 1e3) or as number formula.

   For formulae the arithmetic operations addition (+), subtraction (-), multiplication (*) or division (/) may be used. In addition, brackets and parentheses are considered according to the mathematical rules. Self-defined number functions as well as number variables may be used when putting in real numbers.

   Any bracketed comparison of numbers, co-ordinates or texts is treated as a real number.

   e.g.:

              IF ( Index < 10 ) ...
                   ( 100,100 >= XYPNT(1) ) ...
                   ( [TEXT]1 <> "abc" ) ...
                   ( XPNT(2) = 10 ) ...

   One co-ordinate is larger than the second one, if the x- and the y-position of co-ordinate 1 are larger than the value of co-ordinate 2.

   When comparing texts the alphabetical order applies. The result of such a comparison is either 1 (condition applies) or 0.

4. Parameters set with integers

   Basically integers can be entered in the same way as real numbers. If formulae are concerned, they will be calculated with the interpreter and the result will then be passed to the processing modules. Formulae will not be saved (not even when using constructional constraints).

   Results of formulae or real numbers will be rounded to the next integer.

5. Parameters set with texts

   A text is any expression between inverted commas.

   e.g.:

              CREATE TEXT L "any text" ...

   As it is with number and co-ordinate inputs, functions and text variables may be used.

   z.B.:

              CREATE TEXT L TCAT( [TEXT]1 ; " Appendix" ) ...
                         CONVN2T( XPNT(1) ; 2 ) ...
                         [VARIABLE]3 ...
                         [TEXT]2 ...

   For example 1 the text to be created is calculated from the sequentially listed content from object text 1 and the constant text.

   In example 2 the x-position of point 1 is saved with two decimal places.

   Example 3 shows the naming of a text variable.

   As shown in example 4 a text can also be set with an ID or interactively with the identification of an existant text.

6. Parameters set with letters

   This type of parameter is rarely used. For example the parameter line identification LID=E or S or U (finite or semi- infinite or infinite) is such a parameter.

   These parameters can be set with the respective letter only.

Next: Functions Up: The Language Previous: How to Leave