zfind discussion

For scripts to aid with computation or simulation in cellular automata.
wildmyron
Posts: 1544
Joined: August 9th, 2013, 12:45 am
Location: Western Australia

Re: zfind discussion

Post by wildmyron » October 23rd, 2020, 11:02 pm

LaundryPizza03 wrote:
October 23rd, 2020, 7:38 pm
For some reason ntzfind requires some extra padding when doing knight searches:
These comments from Sokwe when the horizontal offset feature was originally introduced are still relevant. https://conwaylife.com/forums/viewtopic ... 891#p35891

It's not possible to see the other phases of the partial but at least one of them would take up the full width of 5 in the second search.
The 5S project (Smallest Spaceships Supporting Specific Speeds) is now maintained by AforAmpere. The latest collection is hosted on GitHub and contains well over 1,000,000 spaceships.

Semi-active here - recovering from a severe case of LWTDS.

User avatar
May13
Posts: 787
Joined: March 11th, 2021, 8:33 am

Re: zfind discussion

Post by May13 » April 23rd, 2021, 6:17 am

When I tried to find a c/3 diagonal spaceship in B3678/S34678 (Day and Night), ntzfind gives it:

Code: Select all

$  ./ntzfind B3678/S34678 p3 k1 x1 w8
ntzfind 3.0 by "zdr", Matthias Merzenich, Aidan Pierce, and Tomas Rokicki, 24 February 2018
- ./ntzfind B3678/S34678 p3 k1 x1 w8
Rule: B3678/S34678
Period: 3
Offset: 1
Width:  8
Symmetry: asymmetric
Horizontal offset: 1
Phase 0 has width 7
Depth limit: 2000
Stop search if a ship is found.
Starting search

..o.....
oooo....
.o.oo...
.o..oo..
..ooo...
....o...
Length: 16
Spaceship found. (1)

Current depth: 2001
Calculations: 32183
CPU time: 0.046000 seconds
Search terminated: spaceship found.
But ntzfind refuses to return a spaceship in B3ai/S2ae3aijr4aiw:

Code: Select all

$  ./ntzfind B3ai/S2ae3aijr4aiw p3 k1 x1 w10
ntzfind 3.0 by "zdr", Matthias Merzenich, Aidan Pierce, and Tomas Rokicki, 24 February 2018
- ./ntzfind B3ai/S2ae3aijr4aiw p3 k1 x1 w10
Rule: B3ai/S2ae3aijr4aiw
Period: 3
Offset: 1
Width:  10
Symmetry: asymmetric
Horizontal offset: 1
Phase 0 has width 9
Depth limit: 2000
Stop search if a ship is found.
Starting search
.o....o...
Length: 2
Search complete: 0 spaceships found.
Calculations: 10803
CPU time: 0.078000 seconds
Though I have this spaceship:

Code: Select all

x = 4, y = 4, rule = B3ai/S2ae3aijr4aiw
3o$o2bo$obo$bo!
[[ TRACK -1/3 -1/3 ]]
Bug or feature?
I'm using Cygwin.
The latest version of hex-gliders.db have 668 gliders from OT hexagonal rules. Let's find more!
My CA (13 rules)
My scripts: new-glider.py v0.2 (new version), nbsearch2a.py, collector.py v0.3

Sokwe
Moderator
Posts: 2677
Joined: July 9th, 2009, 2:44 pm

Re: zfind discussion

Post by Sokwe » April 28th, 2021, 8:00 am

May13 wrote:
April 23rd, 2021, 6:17 am
ntzfind refuses to return a spaceship in B3ai/S2ae3aijr4aiw...

Though I have this spaceship:

Code: Select all

x = 4, y = 4, rule = B3ai/S2ae3aijr4aiw
3o$o2bo$obo$bo!
[[ TRACK -1/3 -1/3 ]]
Bug or feature?
I'm using Cygwin.
It appears to be a bug of some sort. I believe the problem is in lookAhead(), because if I modify lookAhead() to always return true, then it finds that ship as well as others such as the following:

Code: Select all

x = 5, y = 16, rule = B3ai/S2ae3aijr4aiw
o$2o$b2o3$b3o$o2bo$bobo2$b2o$b3o$b3o2$2bo$2b2o$3b2o!
It's been long enough that I don't really remember how I implemented the horizontal shift, and I was never a fan of the feature in zfind, so I'm not really inclined to hunt this bug down at the moment.
-Matthias Merzenich

User avatar
ihatecorderships
Posts: 309
Joined: April 11th, 2021, 12:54 pm
Location: Falls Church, VA

Re: zfind discussion

Post by ihatecorderships » May 14th, 2021, 3:46 pm

Is there a precompiled windows version of it?
-- Kalan Warusa
Don't drink and drive, think and derive.

User avatar
yujh
Posts: 3068
Joined: February 27th, 2020, 11:23 pm
Location: I'm not sure where I am, so please tell me if you know
Contact:

Re: zfind discussion

Post by yujh » May 14th, 2021, 9:15 pm

ntzfind-win-precompiled.rar
Not compiled by me
(82.05 KiB) Downloaded 124 times
ihatecorderships wrote:
May 14th, 2021, 3:46 pm
Is there a precompiled windows version of it?
Rule modifier

B34kz5e7c8/S23-a4ityz5k
b2n3-q5y6cn7s23-k4c8
B3-kq6cn8/S2-i3-a4ciyz8
B3-kq4z5e7c8/S2-ci3-a4ciq5ek6eik7

Bored of Conway's Game of Life? Try Pedestrian Life -- not pedestrian at all!

lemon41625
Posts: 351
Joined: January 24th, 2020, 7:39 am
Location: 小红点 (if you know where that is)

Re: zfind discussion

Post by lemon41625 » April 10th, 2024, 10:49 pm

If I'm not wrong, zfind is able to search for knightships. Does anyone know how the gfind search space is modified in order to allow for these searches?

I was working on implementing oblique / diagonal searches for cfind (unfortunately oblique searches don't work yet), so I'm curious to see how this is implemented in zfind.
Download CAViewer: https://github.com/jedlimlx/Cellular-Automaton-Viewer

Supports:
BSFKL, Extended Generations, Regenerating Generations, Naive Rules, R1 Moore, R2 Cross and R2 Von Neumann INT
And some others...

User avatar
LaundryPizza03
Posts: 2323
Joined: December 15th, 2017, 12:05 am
Location: Unidentified location "https://en.wikipedia.org/wiki/Texas"

Re: zfind discussion

Post by LaundryPizza03 » April 11th, 2024, 12:08 am

lemon41625 wrote:
April 10th, 2024, 10:49 pm
If I'm not wrong, zfind is able to search for knightships. Does anyone know how the gfind search space is modified in order to allow for these searches?

I was working on implementing oblique / diagonal searches for cfind (unfortunately oblique searches don't work yet), so I'm curious to see how this is implemented in zfind.
zfind searches along the orthogonal direction for knightships. You can find this beginning at line 579 of ntzfind.cpp ("#ifdef KNIGHT"). Paul Tooke's gfind mod includes an implementation of the same, which was used to find the p5 knightship in B3578/S235.

Code: Select all

x = 4, y = 3, rule = B3-q4z5y/S234k5j
2b2o$b2o$2o!
LaundryPizza03 at Wikipedia

Sokwe
Moderator
Posts: 2677
Joined: July 9th, 2009, 2:44 pm

Re: zfind discussion

Post by Sokwe » April 11th, 2024, 1:34 am

lemon41625 wrote:
April 10th, 2024, 10:49 pm
If I'm not wrong, zfind is able to search for knightships. Does anyone know how the gfind search space is modified in order to allow for these searches?

I was working on implementing oblique / diagonal searches for cfind (unfortunately oblique searches don't work yet), so I'm curious to see how this is implemented in zfind.
It wasn't particularly clever. When your partial result contains rows A, B, and X, and you're searching for row C such that

Code: Select all

AAAA   evolves into
BBBB ---------------> XXXX
CCCC
just shift row X horizontally by one cell before searching for row C.

As discussed above, I made some mistake in implementing LookAhead() with the horizontal shift. Ultimately, zfind's width limitations meant that this feature was mostly useless anyway, so I removed it. Other programs like ikpx2, LSSS, LLSSS, and even gfind are better. As LaundryPizza03 mentioned above, you're probably better off looking at Paul Tooke's modification of gfind, rather than whatever I wrote for zfind. I think it's the same basic idea.
-Matthias Merzenich

Post Reply