Files
thor/thor.c
matthias wagner 643256c4dc rough outline
2023-07-13 22:15:31 +02:00

40 lines
1.1 KiB
C

#include <stdio.h>
#include <stdlib.h>
// run using gcc thor.c && ./a.out
struct pc_node {
struct pc_node* sides[6];
}
struct pc {
struct pc_node* head;
unsigned int n;
}
int main(int argc, char **argv){
if(argc != 2) {
printf("enter one argument for n");
return 1;
}
unsigned int n = atoi(argv[1]);
printf("claculating number y of rotaionally asymmetric polycubes with n = %u ...\n", n);
unsigned int y = rot_asy_pc(n);
printf("y = %u\n", y);
return 0;
}
unsigned int rot_asy_pc(n) {
// for all nodes
// for all sides of curr_node counting s
// is the position valid?:
// is the position already occupied?:
// curr_node.sides[s] == 1
// is there another node at the position (maybe space bitmap like in video)
// has the resulting pc already been generated? (lookup table: needs good key generation algorithm / another way to check for symmetries)
// => new pc found
// => increment counter
// opt. add to lookup table
// when done with one layer of n increment n and continue with pcs from lookup table
// => breadth first search
}