They're designed to mimic the process of nyctinasty, which is how flowers tuck themselves in for bedtime.