Design melodies following the assigned musical pattern while integrating the provided thematic element.
X:1
L:1/8
M:3/4
K:D
['d2 FG E>F D>F EG F2 A2', 'D2 F2 A>F G>G (3GFG'  
X:1
L:1/8
M:3/4
K:D
|: A | d2 FG E>F | D>F EG F2 | A2 B2 e>d | c>B AA/c/ B/d/c/e/ | d2 FG E>F | D>F EG F2 | A2 B2 e>d | 
 (3cBc d3 :: F | D2 F2 A>F | G>G (3GFG A>F | D2 F2 A>F | G>G (3GFG A>F | D2 F2 A>F | 
 G>G (3GFG A>A | d2 FG E>G | F/E/D/C/ D3 :|  