## Scalar Variables The GCE module is mostly used to calculate 2D plane geometric objects, while constraints and dimensions are applied to them. These data types inherently have vector representation. Parametric drawing assumes that geometry is linked with driving or variational numeric parameters. So it is impossible to do without another type, a **numeric variable** or a **scalar**. Their values are usually expressed using distance or angle measurement units. Variables of the following type can only be used in a parametric constraint system: - A numeric variable associated with a dimension, it is a **dimensional variable**. When resolved, a dimensional variable is equal to measured dimension value. Dimensional variable can be both an independent driving parameter of a sketch, or variational/measurement parameter. The use of variables for creating driving and variational dimensions is discussed in Item [Driving and Variational Dimensions](../../../TWO-DIMENSIONAL_DIMENSIONS/subsections/EN/Driving_and_Variational_Dimensions.md). - An auxiliary geometric constraint parameter, for example, a parameter that specifies where tangency points are for complex curves. You can find more details in **Auxiliary tangency parameter** Section, Item [Tangency](../../../TWO-DIMENSIONAL_LOGICAL_CONSTRAINTS/subsections/EN/Tangency.md). - A variable that is not associated with a geometric constraint or a dimension may be used in scalar linear or non-linear equations that establish relations between first values and other values. In GCE module API, a variable is represented by the var_item data type. You can create variables by calling ```cpp var_item GCE_AddVariable(GCE_system gSys, double val). ``` The function returns a descriptor of a scalar variable with the initial value **val**. The variable with this descriptor can be further used to determine dimensions, constraints, and equations. Any variable can be **dependent** or **independent.** A dependent variable is governed by measurement dimensions or constraints, and its value is calculated by the solver. An independent variable can't be modified by the solver, and its value is defined by the application. To make a variable independent, just call ```cpp constraint_item GCE_FixVariable(GCE_system gSys, var_item var), ``` that will create a driving parameter constraint and return the constraint descriptor that fixes its value. An independent variable can be varied by calling **GCE_ChangeDrivingDimension**() method. Driving parameter constraint together with other types of driving dimensions permits to create a parametric sketch; its geometry can be changed according to a user defined law by changing independent parameters. Creation of driving parameters and dimensions is described in Item [Driving and Variational Dimensions](../../../TWO-DIMENSIONAL_DIMENSIONS/subsections/EN/Driving_and_Variational_Dimensions.md).