Fixed function. Added d-cube generator