HTML Diff
0 added 0 removed
Original 2026-01-01
Modified 2026-02-21
1 <p>One of the essential topics for teaching modeling skills is geometry. Unlike other branches of mathematics, it is visually representable and intuitive for everyone. Let us recall the basic concepts we will deal with. The<strong>coordinate plane</strong>is the plane that the coordinates system uses.</p>
1 <p>One of the essential topics for teaching modeling skills is geometry. Unlike other branches of mathematics, it is visually representable and intuitive for everyone. Let us recall the basic concepts we will deal with. The<strong>coordinate plane</strong>is the plane that the coordinates system uses.</p>
2 <p><strong>Coordinates</strong>are a set of two lines intersecting at right angles. If the coordinate system is Cartesian, it has called numeric axes:</p>
2 <p><strong>Coordinates</strong>are a set of two lines intersecting at right angles. If the coordinate system is Cartesian, it has called numeric axes:</p>
3 <p>We can place a<strong>point</strong>- the simplest primitive on a plane. We determine its position by two coordinates, written like this:</p>
3 <p>We can place a<strong>point</strong>- the simplest primitive on a plane. We determine its position by two coordinates, written like this:</p>
4 <p>The first number is the coordinate on the x axis, and the second is on the y axis. In the code, it can be represented as a tuple consisting of two elements:</p>
4 <p>The first number is the coordinate on the x axis, and the second is on the y axis. In the code, it can be represented as a tuple consisting of two elements:</p>
5 <p>It is already enough to perform various operations. For example, to find a symmetric point relative to the x-axis, it is enough to invert the second number - to change the sign to the opposite:</p>
5 <p>It is already enough to perform various operations. For example, to find a symmetric point relative to the x-axis, it is enough to invert the second number - to change the sign to the opposite:</p>
6 <p>Look how to represent it in code:</p>
6 <p>Look how to represent it in code:</p>
7 <p>Sometimes, we need to find a point between two other points and the middle of the segment. We calculate this point by searching for the arithmetic mean of coordinates. That is, the x coordinate of the median point is equal to (x1 + x2) / 2, and the y coordinate is (y1 + y2) / 2:</p>
7 <p>Sometimes, we need to find a point between two other points and the middle of the segment. We calculate this point by searching for the arithmetic mean of coordinates. That is, the x coordinate of the median point is equal to (x1 + x2) / 2, and the y coordinate is (y1 + y2) / 2:</p>
8 <p>There are a lot of similar operations in geometry. When we speak about code organization, it is logical to put all functions related to the operations with points in the points module.</p>
8 <p>There are a lot of similar operations in geometry. When we speak about code organization, it is logical to put all functions related to the operations with points in the points module.</p>
9 <p>In turn, we can combine the points into segments, defining each segment by a pair of points - opposite ends of the segment. Also, we can represent a segment in code similarly to a point in the form of a tuple of two elements:</p>
9 <p>In turn, we can combine the points into segments, defining each segment by a pair of points - opposite ends of the segment. Also, we can represent a segment in code similarly to a point in the form of a tuple of two elements:</p>
10  
10