Researchers’ algorithm designs soft robots that sense