wiris allows us to work with geometric elements in the plane and in space (Euclidean geometry in the plane and in space) and, in particular, to display them graphically.
The first section is dedicated to the different types of geometric objects available. The second section focuses on the functions that permit the user to act on these objects. The graphical display of geometrical elements is discussed in the Graphics chapter (for plane geometry) and in the 3D Graphics chapter (for geometry in 3D space).
This section explains the geometrical figures that can be constructed.
points: command point
, Icon or
Constructs a point from coordinates a and b, for which function arguments are real numbers. Note that upon writing the expression (a,b) without the word point, we only have the sequence a and b. We have not defined a point. Some functions related to points are midpoint or colinear?.
For points in 3D space, the command point(a,b,c) constructs a point from coordinates a, b and c, just as for a point on the plane.
|
lines: command line
, Icon
Allows us to create a line. The different arguments it can take are:
- two points on the line (we can use the icon
),
- a point and a direction vector,
- an equation for the line, or
- a point and a real number (the slope of the line).
If r is a line, then slope(r), point(r) and vector(r) return the slope of the line, a point on the line and a direction vector of the line, respectively. To study other functions that can also be used to build a line, see parallel, perpendicular and bisector.
In the case of lines in 3D space, the following arguments are accepted:
- two points on the line (we can use the icon
)
- a point and a direction vector,
- two equations (of secant planes).
|
segments: command segment
, Icon
Allows us to create a segment. The different arguments it can take are:
- the segment endpoints (use the icon
),
- a point and a direction vector.
Some functions related to segments are length or midpoint.
|
planes: command plane
, Icon
This allows us to create a plane. The different arguments it can take are:
- three points (use the icon
),
- a point and a direction vector (perpendicular to the plane),
- a point and two vectors,
- a linear equation.
Some functions related to planes are parallel, perpendicular or bisector.
|
circumferences: command circumference or cfr
, Icon , or
This allows us to create a circle. The different arguments it can take are:
- a point (center point of the circumference) and a real number (its radius), using the icon
,
- three unaligned points (representing points on the circumference), using the icon
,
- two points (the center point and a point on the circumference, respectively) using the icon
,
- the equation of the circumference.
If c is a circle, then center(c) and radius(c) return the centre and the radius of the circle, respectively. If P is a point on the circumference c, then tangent_line(c,P) the tangent line to c through point P.
|
conic sections: command conic
, Icon
This allows us to create a conic. The different arguments it can take are:
- five points (pertaining to the conic), using the icon
,
- the equation of the conic.
The commands ellipse, hyperbola and parabola allow us to construct conics from the fundamental elements of a conic such as the focus, the vertex and the focal distance. For a detailed description of the many components used to construct these elements, see the section Reference. Some functions related to conics are center, vertex, focus, directrix, semimajor_axis, semiminor_axis or focal_semidistance.
|
triangles: command triangle
, Icon
This function is used to construct a triangle, using the vertices as arguments. It is also possible to use the icon . The command equilateral_triangle allows us, as its name suggests, to create an equilateral triangle.
|
polygons (or polygonals): command polygon or polygonal
, Icon or
Generates the polygon (or the polygonal), which results from joining the points that are entered as arguments. Remember that a polygon is a closed plane, while polygonals are segments that join a set of points, and in general they are open figures and not flat.
|
polyhedras: command polyhedra
, Icon or
Generates the regular polyhedron with n faces. Some functions related to the polyhedra are tetrahedron, cube, octahedron, dodecahedron, icosahedron, polyhedra_cylinder_with_lids, polyhedra_cylinder, polyhedra_cone_with_lid, polyhedra_cone, polyhedra_sphere or polyhedra_thorus.
|
As arguments, the geometrical functions accept geometrical figures, which are generally constructed using the functions described in the previous section, but they also directly accept the equation of the figure as an argument. The latter feature is used repeatedly in this section.
Geometric study
distance: command distance
Calculates the distance between two points, a point and a line or a point and a circumference.
In 3D space, it is also possible to calculate the distance between two non-secant planes, between a non-secant line and plane or between a point and a plane.
|
midpoint: command midpoint
Calculates the midpoint between two given points, on the segment formed by the two points. The command midpoint accepts two points or a segment as an argument. For the latter, it calculates the midpoint of the segment's endpoints.
|
perpendicular bisector: command perpendicular_bisector
Calculates the perpendicular bisector of a segment, i.e. the line perpendicular to the segment that passes through its midpoint. It can also be defined as the set of points which are equidistant to the endpoints of the segment.
This command accepts a segment or two points as an argument, and it calculates the perpendicular bisector of the segment formed by those points. It is also possible to use a triangle and the number of the side for which the perpendicular bisector is required.
More information on circumcenter or circumradius.
|
bisector: Icon or
, command bisector
We can calculate the bisector of the following objects:
- two secant lines,
- three unaligned points (thus, defining an angle).
- and an angle of a triangle.
More information on incenter or inradius.
For the case of geometry in 3D space, it is possible to calculate the bisector of two intersecting planes.
|
height: command height
Calculates the height corresponding to the ith vertex of the triangle, i.e. the line that passes through the vertex and that is perpendicular to the opposite side. This command accepts, as arguments, a triangle and the vertex number for which the user wishes to calculate the height.
More information on orthocenter.
|
median line: command median_line
This calculates the line from the triangle vertex to the midpoint of the opposite side. This command accepts as arguments a triangle and the vertex number for which the user wishes to calculate the median.
More information on barycenter.
|
area: command area
This calculates the area of a figure, received as an argument, on the basis that the figure is closed (triangle, polygon, circumference or ellipse).
More information on oriented_area.
|
perimeter: command perimeter
This calculates the perimeter of a closed figure (triangle, polygon or circumference), which is received as an argument.
|
angle: command angle
This calculates the minor angle defined for two lines or two vectors (planes if working in 3D space). In the first case, it returns a value between 0 and
π/2 and in the second case between
0 and
π.
If F is a
Triangle, Polygon or Polygonal then the command angle(F,i) calculates the angle corresponding to its ith vertex.
More information on oriented_angle.
For work in 3D space, the function is named angle3d and it can also be applied to planes. It is also possible to use the command geometry_status to learn how to simplify this command.
|
intersect: Icon
, command intersect
This returns a list of the elements that form the intersection of two figures, received as arguments.
|
parallel: Icon or
, command parallel
This function accepts a line or segment as the first argument and a point as the second argument. Accordingly, it finds the line parallel to the first argument that passes through the point. More information on parallel?.
When working in 3D space, the function can be applied to a plane just as it is applied to a line or segment in two dimensional space.
|
perpendicular: Icon or
, command perpendicular
This function accepts a line or segment as the first argument and a point as the second argument. Accordingly, it finds the line perpendicular to the first argument that passes through the point. More information on perpendicular?.
When working in 3D space, the function can be applied to a plane just as when working in two dimensional space.
|
Transformations
wiris allows us to calculate and display the transformation of a Figure by way of plane movement. Transformations can also be applied to a list of figures and the result is the list that corresponds to applying the transformation to each of the figures in the list.
symmetry: command symmetry
Axial or radial symmetry can be calculated for a given figure. In the former case, the command symmetry takes as arguments the line that acts as axis of symmetry and the figure. In the case of radial symmetry, the arguments are the centre of symmetry and the figure.
|
translation: command translation
Given a vector and a figure, the translation of the figure can be calculated with respect to the vector.
|
rotation: command rotation
Given point P, real number a and figure F, this calculates the centre of rotation P and anglea of figure F. The real number is interpreted as an angle in radians. To work with degrees, use the icon .
|
|