# Pythagorea Toughie

I recently happened upon a game called pythagorea.

The idea is that you're given a 6x6 grid. You may click at any intersection to create a point and you may join any two points to create a line (that extends in both directions to the end of the grid). And then you're given various tasks to achieve.

Two puzzles stood out for me as being a little more tricky than the others. My solutions ended up being a little... inelegant. I wondered whether anyone would be able to do better.

The challenge then is to solve the puzzles with as few lines as possible (that's my arbitrary measure of elegance!).

Puzzle 1: Puzzle 2: Please indicate also the logic that you've used to know that your solution is correct.

• Puzzle 2 is apparently possible with just 10 lines. – Jens May 11 at 21:51
• @Jens, oh wow! That's waaaaay better than my solution! Neat theorem. With this particular puzzle, 9 will be enough then... – Dr Xorile May 11 at 22:09
• the strategy I've tended to appeal to was you use math the compute the coordinates of the answer, and exploit the fact that the coordinates are rational to construct the points I need. – greenturtle3141 May 12 at 1:38
• Blast you, @DrXorile! Now I have another time suck on my device! – shoover May 12 at 22:02
• But games aren't addictive or anything, right? – Dr Xorile May 12 at 22:05

A very ad-hoc solution to Puzzle 1 in nine lines (technically ten, because you have to extend one past the point you anchor it to): ((0,0) is the origin)

Draw a line from (-2,2) to (-1,-1). Mark (4/3,0). Draw a line from A to that point and mark its intersection with the opposite side of the triangle. Call it B.
Draw a line from (0,0) to (1,-2). Mark (3/2,-3). Draw a line through that point and (1,3), and mark (13/12,2). Call it C.
Draw a line from (0,-2) to (2,-1). Mark (3,-1/2). Draw a line through that point and (1,3), and mark (2,5/4). Draw a line through that point and (-1,1), and mark (0,13/12). Call it D.
BC and BD are the required other sides. As for Puzzle 2, let's adapt Jens's idea, but abuse some grid lines to cheapen the construction.

Our B line will be the one through (-1,0), which we don't even need to draw: its intersection points are (-1,0) and (0,1).
Our A line is the one through (0,-1). Draw it, and draw the line connecting the upper intersection to (-1,0). It intersects the y-axis at D.
Our C line is the one through (1,0). Draw it, and draw the line connecting the lower intersection to (0,1). It intersects the x-axis at E.
DE is our Pascal line, and two more lines (for a total of 7) give us the tangents! The Pascal line is in green, and there are no tangents because the lower one would be too close to the other lines (and the thicker lines cover for inaccurate drawing on mobile!)

EDIT: "You can save one more line."

Let's just skip straight to the Pascal line, which is the line from (-1,1) to (2,-1), and save four! • Puzzle 1 answer is not correct. All sides must have equal length – Dr Xorile May 12 at 22:13
• I just remembered this... Oops. Think I'm close to an actual solution, however. – AxiomaticSystem May 12 at 22:17
• Puzzle 2 is great. You can actually save one of the lines still – Dr Xorile May 12 at 22:19
• A line can be saved on Puzzle 1, but I'll leave that for later. – AxiomaticSystem May 13 at 0:31
• The solution to Puzzle 2 implies a potentially cheaper general method: rot13(Gur Cnfpny yvar pbeerfcbaqvat gb n cbvag vf gur yvar crecraqvphyne gb gur yvar sebz gur pragre gb gur cbvag guebhtu gur vairefr bs gur cbvag.) – AxiomaticSystem May 14 at 3:56