Design melodies following the assigned musical pattern while integrating the provided thematic element.
X:1
L:1/8
Q:1/8=232
M:4/4
K:G
['GA (3(BBB)', 'B4 e^d e=f ef e=d cd cB'  
X:1
L:1/8
Q:1/8=232
M:4/4
K:G
|: D2 GA (3(BBB) Be | dB GA (3(BBB) Be | dA FG (3(AAA) AB | AG FE (3(DFA) d2 | D2 GA (3(BBB) Be | 
 dB GA (3(BBB) B^c | d^c de (3(fgf) (3(edc) | B2 d2 B4 :: e^d e=f ef e=d | cd cB AB c^c | 
 d^c de de d=c | Bc BA GA GF | E^G AB cd e2 | DF GA Bc d2 | ^cd fe d=c BA | G2 B2 G2 :|  