3D logic