Export to GitHub

moodle-coordinate-question - AnswerFormat.wiki


| This is the documentation of the older coordinates question type, which is deprecated. Though the format of number and unit is almost the same, the format of coordinates is replaced by few boxes in the new formulas question type. | |:--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|

An answer is either a number or a coordinate, with an optional associated unit. The question itself should give a hint on what answer is expected.

Number

A number is simply a sequence of decimal digit with a decimal point.

42 3.14159 0.01 .69

It is also possible to input the scientific E notation that is commonly used in the calculator and computer. It may be useful when entering a large or small number.

1E3 (= 1000) 1.0E-3 (= 0.001) 123E-6 (= 0.000123)

Coordinate

A coordinate/vector is a list of number separated by a comma and optionally enclosed by round bracket, i.e. (x,y) or (x,y,z)

1,0 0,1 0.707, -0.707 1,0,0 0,1,0 (0,0,1) (3.2, 0, 0.5) (-3.3e3, 2.2e3, 1100)

Unit

For a given physical quantity, the unit name can be entered directly. 1. If a unit has base unit with an exponent, say area (m2), it should be entered as m^2. 1. If a unit has base unit with a negative exponent, say wavenumber (m-1), it should be entered as m^(-1). 1. If a unit is composed of few base unit, say velocity (m s-2), it should be entered as m s^(-2) with the base unit separated by the space representing multiplication of units. 1. For the negative exponent, you may also enter with a preceding division operator, say m/s^2 which is equivalent to m s^(-2). Note that only one such 'division' is allowed to avoid ambiguity of unit. 1. Note the bracket of coordinate is required when unit is present which is used to prevent ambiguity.

Examples of answers with unit:

1 m 0.1 m^2 20 m s^(-1) 400 kg m/s 100 kW (3,4) m (14, 14) m/s (0, -9.8) m/s^2 (100, 100) N