Programming soft composite materials that can gradually fold up into a semicircle. (A) Schematic of a soft beam programmed to fold up under magnetic excitation. Although we illustrated this motion with only four shapes, there were a total of 100 distinct shapes throughout this motion. (B) Optimization results for the desired first derivative of the bending moment. Each plot represents the desired first derivative of the bending moment of the beam for one time frame. The frame number for each time frame is represented by the number at the Top. In the simulations, the time difference between each time frame is 0.01 s. The blue lines in the time frames represent the desired first derivative of the bending moment, and the dotted red lines represent the obtained first derivative of the bending moment created by the magnetic actuation. The x axis of each plot represents the length of the beam, which ranges from s = 0 to 7 mm. (C) The required magnetization profile, , and the magnetic field, , to achieve the desired time-varying shapes. This magnetization profile is along the predeformed straight beam (see Fig. S6 for a more quantitative representation for the magnetization profile). Using the coordinate system in A as a reference, the variables and in the magnetic field plot represent the x- and y-axis components of the magnetic field, respectively. (D) Snapshots of a single beam curling up under magnetic excitation. The yellow lines represent the corresponding desired time-varying shapes. (E) Four soft beams made of the programmable material are shown deforming into a reversible CMU logo under magnetic excitation. To visualize the logo better, we highlighted the final CMU shape with dotted red lines. (F) A jellyfish-like robot equipped with two soft tentacles made of the programmable soft composite material. The robot could propel itself on an oil–water interface by bending its tentacles back and forth under magnetic excitation. Additional parameters for this device can be found in S9. Parameters for Each Case and Table S1.