- /
-
Rubik's Cube
on 10 Oct 2021
- 50
- 91
- 1
- 0
- 279
n=reshape([0 dec2bin(1.5467695506668e+13)-'0']',5,9);
a=@(a,q,w,r,c)plot(alphaShape(a(:,1)+q,a(:,2)+w,a(:,3)+r),"FaceC",c);
o=ones(1,3);
for k=[o*0 o o*2;0:2 0:2 0:2;jet(9)']
b=k(1);
c=k(2);
d=k(3:5);
a(n(:,1:3),b,0,c,d)
hold on
a(n(:,7:9),0,b,c,k(5:-1:3))
a(n(:,4:6),c,b,2,d)
end
camlight
axis off