Construct melodic segments by incorporating the provided motif with the designated musical pattern.
X:1
L:1/8
M:4/4
K:D
['A3 A BFAF DFAF EDB,D A3 B{d}', 'd2 fd'  
X:1
L:1/8
M:4/4
K:D
 A3 A BFAF | DFAF EDB,D | A3 B{d} BFAB | dBAF EDB,D :| d2 fd edfd | d2 fd B2 AB | d2 fd edfd | 
{e} dBAF EDB,D | d2 fd edfd | d2 fd B2 Ad | fded{e} dB B2 | dBAF EDB,D ||  