Sketcher Tutorial

This tutorial is work in progress!

Introduction
The Sketcher is a tool to generate 2D-objects for usage in parts design. The sketcher is different to traditional drawing tools. A way to show the difference is the construction of a triangle. A triangle is fully defined by 3 values, which can be any from the following list: side length, angle, height, area. The one exception is three angles, which will not define the size.

In order to construct a triangle from 3 length in the traditional way, the following has to be done:
 * draw the base line
 * make two circles with a radius given by the other two side lengths, or alternatively calculate the coordinates of the third vertex
 * draw the missing two sides from the endpooints of the base line to the crossing point of the two circles or the calculated vertex.



The Triangle page shows a collection of formulas to calculate the missing information in order to draw a triangle from the minimum specification. Those are needed, if the triangle has to be defined by precalculated coordinates.

The Sketcher is different. The formulas and helper constructions are not needed. Instead in the Sketcher an arbitrary triangle will be drawn with the polyline tool. The triangle needs to be closed. So for the last line a click is needed on the first created vertex. A point should be visible near the mouse pointer before clicking. Image??

This will make sure, that the last vertex is identical to the first one. The created triangle is flexible. A vertex can be selected by clicking on it, so it turns green. Then this vertex can be dragged around. The triangle may move or rotate and the sides may change their length.

Each lenght of the side is now easy defined by selecting it and then clicking on the length tool. A dialog opens and the wanted length can be put in. The picture below shows a triangle with side lengths of 35 mm, 27 mm and 25 mm.

These length-definitions are called constraints. Constraints are used to define a fixed design from the flexible geometric input. The sketcher provides all constraints needed to define any kind of tringle. Only the area can not be used to define one. Here is a list of cases:


 * One or two angles given: Two sides of the triangle needs to be selected. A click on [[Image:Constraint_InternalAngle.png|32px]] opens a dialog to define the angle.


 * Right triangle: Two sides of the triangle needs to be selected. A click on[[Image:Constraint_Perpendicular.png|32px]] sets a right angle between the two sides.


 * Equilateral: One side has to be set to a defined length. Then all sides needs to be selected. A click on[[Image:Constraint_EqualLength.png|32px]] defines two equal length constrains in order to give all sides the same length.


 * Isosceles triangle (two identical length) with given height: Select first the two vertices of the base line and last the symmetric vertex. A click on [[Image:Constraint_Symmetric.png|32px]] sets a symmetry between the three vertices. Then select the base line and the symmetry vertex and click the [[Image:Constraint_Length.png|32px]] length tool.

Fixing the triangle to a location. Align it.

More themes:

Profiles for solid parts
closed profiles no intersection of lines

Construction lines
helper lines to define more complex profiles

external Geometry
see link

More about Constraints
The sketcher does not know the triangle formulas from the wikipedia. Instead it sets up an equation system for the 2-dimensional coordinates based on the given constraints. This equations system is then solved numerically.

Traps with constraints