Design melodies following the assigned musical pattern while integrating the provided thematic element.
X:1
L:1/8
M:4/4
K:G
['e3 d']  
X:1
L:1/8
M:4/4
K:G
 F G | A3 B (FG) A2 | d2 A4 B2 | c2 B2 cd e2 | d6 d d | e3 d c2 d e | e3 d B2 G A | B2 d2 A2 (BA) | 
 G6 ||  