IGNORED

# Clear for Action ported to Geneve

## Recommended Posts

FYI, this formula [DIST=((ABS(X1-X2)^2)+(ABS(Y1-Y2)^2))] matches CALL DISTANCE exactly.

here's a program from the TI99 that test the formula and compares with CALL DISTANCE.

90 CALL CLEAR
100 CALL SPRITE(#1,65,2,50,50,1,1)
105 CALL SPRITE(#2,75,2,60,60,_1,-1)
110 CALL DISTANCE(#1,#2,R)
120 CALL POSITION(#1,Y1,X1)
122 CALL POSITION(#2,Y2,X2)
127 D=((ABS(X1-X2)^2)+(ABS(Y1-Y2)^2))
130 DISPLAY AT(24,1):R
135 DISPLAY AT(23,1):D
140 GOTO 110

##### Share on other sites

The ABS function is not necessary since you are squaring the difference.

##### Share on other sites

13 minutes ago, Vorticon said:

The ABS function is not necessary since you are squaring the difference.

##### Share on other sites

Why? - Because in groups, for each element there is exactly one inverse element, so you can easily derive that the inverse of the inverse element is the element itself. The proof is left as an exercise.

• 1
• 1
##### Share on other sites

looks like I fixed the two problems that were found. now just test, test, test.

##### Share on other sites

11 hours ago, hloberg said:

looks like I fixed the two problems that were found. now just test, test, test.

Happy to help with the testing

##### Share on other sites

2 hours ago, Vorticon said:

Happy to help with the testing

i'll PM you.

##### Share on other sites

On 3/8/2023 at 6:22 PM, mizapf said:

Why? - Because in groups, for each element there is exactly one inverse element, so you can easily derive that the inverse of the inverse element is the element itself. The proof is left as an exercise.

funny, I was just teaching one of the kids this very thing a couple weeks ago and I totally forgot it. 😜

##### Share on other sites

It's a special fun to show students the proof why there is only one zero in a Boolean Algebra, and why not(not(A)) = A. You should see their faces. Most of them simply cannot imagine that there is something to prove at all.

• 1
• 1

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.