Robot algorithms