Construct melodies utilizing the provided motif and adhere to the outlined musical structure.
X:1
L:1/16
M:4/4
K:D
['A2AG B2AG F2A2 d2f2 e2>d2', 'd6 [M:5/4] A2 d2>e2 f2ed e>ge<c (A4', 'f>af<d f>af<d e>ge<c A4 B>dB<G B>dB<G A>cA<F'  
X:1
L:1/16
M:4/4
K:D
 D/F/ | A2AG B2AG F2A2 d2f2 | e2>d2 c2Bc d2AF D2DF | A2AG B2AG F2A2 d2f2 | e2>d2 c2Bc d6 :: 
[M:5/4] A2 | d2>e2 f2ed e>ge<c (A4 A2)F | G2>A2 B2AG A>dA<F (D4 D2)DF | 
[M:4/4] A2AG B2AG F2A2 d2f2 | e2>d2 c2Bc d6 :: f>af<d f>af<d e>ge<c A4 | B>dB<G B>dB<G A>cA<F D4 | 
 f>af<d f>af<d e>ge<c A4 | B>dB<G B>dB<G A>cA<F D4 | d2>c2 d2e2 f4 a2>f2 | g>ag<e c2b>c d6 :|  