Created
May 28, 2020 11:48
-
-
Save PtrMan/56decbd00d321dff19b41463c31cf141 to your computer and use it in GitHub Desktop.
ONA experiments
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print("*motorbabbling=false") | |
#encode a field as a term | |
def encField(y,x): | |
name = str(y)+"Y"+str(x) | |
return "<f"+name+" --> F"+name+">" | |
# encode maze | |
for ix in range(10): | |
for iy in range(10): | |
print("<( "+encField(iy,ix)+" &/ ^pick ) =/> "+encField(iy,ix+1)+">. {1.0 0.98}") | |
print("<( "+encField(iy,ix)+" &/ ^pick ) =/> "+encField(iy+1,ix)+">. {1.0 0.98}") | |
print("") | |
# encode position where we are | |
print(encField(1,1)+". {1.0 0.98} :|:") | |
print("") | |
# give time to reason | |
for t in range(100*2): | |
print(encField(9,9)+"! :|:") | |
print("10") # give time to reason | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment