Question: Error, mismatched or missing bracket/operator-----unknown error

Hi, everyone! I am a new user to maple and I need to import some code I have found from a paper, just so I can manupluate some of the variables. However when I have copied and pasted my code, I keep getting the error Error, mismatched or missing bracket/operator.  I did check online and it seems to be a bracket missing but I have copied without errors from the source. 

I have attached a picture and did a copy paste of the code that is giving me an error below. 

Thanks for your help 

x[1] := l[1]*sin(theta(t));
y[1] := -l[1]*cos(theta(t));

x[2] := -l[2]*sin(theta(t));
y[2] := l[2]*cos(theta(t));
R[1] := vector(2, [x[1], y[1]]);
R[2] := vector(2, [x[2], y[2]]);
'R[1]'':=map(diff,R[1],t):

 

Please Wait...