MarylandManipulator.world
Go to the documentation of this file.
1 
2 [CONSTANTS]
3 
4 % INPUT PARAMETERS
5 
6 theta1_min:= pi/3+0.2
7 theta1_max:= theta1_min
8 
9 theta2_min:= pi/3
10 theta2_max:= theta2_min
11 
12 theta3_min:= pi/3-0.2
13 theta3_max:= theta3_min
14 
15 % PARAMETERS OF THE PLATFORM
16 
17 % radius of the circunference inscribing the base triangle
18 r_b:=1
19 
20 % angles from the center of the base to the legs anchor points
21 beta1_b:=0
22 beta2_b:=beta1_b+(2*pi/3)
23 beta3_b:=beta2_b+(2*pi/3)
24 
25 % radius of the circunference inscribing the platform triangle
26 r_p:=1
27 
28 % angles from the center of the platform to the legs anchor points
29 beta1_p:=0
30 beta2_p:=beta1_p+(2*pi/3)
31 beta3_p:=beta2_p+(2*pi/3)
32 
33 % Length of the bottom part of each leg
34 lenght_A:=1
35 
36 % Length of the upper part of each leg (i.e., the long bar of the 4 bar)
37 length_B:=1
38 
39 % Length of the short bar forming the 4 bars in the upper part of each leg
40 length_B1:=0.1
41 
42 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
43 % nothing to be modified behond this point
44 
45 % Anchor points of the legs in the base
46 x1_b:=r_b*cos(beta1_b)
47 y1_b:=r_b*sin(beta1_b)
48 
49 x2_b:=r_b*cos(beta2_b)
50 y2_b:=r_b*sin(beta2_b)
51 
52 x3_b:=r_b*cos(beta3_b)
53 y3_b:=r_b*sin(beta3_b)
54 
55 % Tangent vectors to the sphere inscribing the base triangle at the
56 % leg anchor points
57 alpha1_b:=beta1_b+pi/2
58 alpha2_b:=beta2_b+pi/2
59 alpha3_b:=beta3_b+pi/2
60 
61 % Anchor points of the legs in the platform
62 x1_p:=r_p*cos(beta1_p)
63 y1_p:=r_p*sin(beta1_p)
64 
65 x2_p:=r_p*cos(beta2_p)
66 y2_p:=r_p*sin(beta2_p)
67 
68 x3_p:=r_p*cos(beta3_p)
69 y3_p:=r_p*sin(beta3_p)
70 
71 % Tangent vectors to the sphere inscribing the plotform triangle at the
72 % leg anchor points
73 alpha1_p:=beta1_p+pi/2
74 alpha2_p:=beta2_p+pi/2
75 alpha3_p:=beta3_p+pi/2
76 
77 % radius of the bars used in the representation. The bars for the
78 % base/platform are 1.5 times this radius
79 rb:=0.025
80 
81 
82 [LINKS]
83 
84 base : 0.5*red
85  % One sphere at each vertex of the triangle
86  sphere rb*1.5 (x1_b,y1_b,0)
87  sphere rb*1.5 (x2_b,y2_b,0)
88  sphere rb*1.5 (x3_b,y3_b,0)
89 
90  % Three bars forming the triangle
91  cylinder rb*1.5 (x1_b,y1_b,0)(x2_b,y2_b,0)
92  cylinder rb*1.5 (x1_b,y1_b,0)(x3_b,y3_b,0)
93  cylinder rb*1.5 (x2_b,y2_b,0)(x3_b,y3_b,0)
94 
95  % Part of the revolute joint with the first leg fixed at the base
96  cylinder rb (x1_b-length_B1*cos(alpha1_b),y1_b-length_B1*sin(alpha1_b),0)
97  (x1_b-0.5*length_B1*cos(alpha1_b),y1_b-0.5*length_B1*sin(alpha1_b),0)
98  sphere rb (x1_b-length_B1*cos(alpha1_b),y1_b-length_B1*sin(alpha1_b),0)
99  cylinder rb (x1_b+0.5*length_B1*cos(alpha1_b),y1_b+0.5*length_B1*sin(alpha1_b),0)
100  (x1_b+ length_B1*cos(alpha1_b),y1_b+ length_B1*sin(alpha1_b),0)
101  sphere rb (x1_b+ length_B1*cos(alpha1_b),y1_b+ length_B1*sin(alpha1_b),0)
102 
103  % Part of the revolute joint with the second leg fixed at the base
104  cylinder rb (x2_b-length_B1*cos(alpha2_b),y2_b-length_B1*sin(alpha2_b),0)
105  (x2_b-0.5*length_B1*cos(alpha2_b),y2_b-0.5*length_B1*sin(alpha2_b),0)
106  sphere rb (x2_b-length_B1*cos(alpha2_b),y2_b-length_B1*sin(alpha2_b),0)
107  cylinder rb (x2_b+0.5*length_B1*cos(alpha2_b),y2_b+0.5*length_B1*sin(alpha2_b),0)
108  (x2_b+ length_B1*cos(alpha2_b),y2_b+ length_B1*sin(alpha2_b),0)
109  sphere rb (x2_b+ length_B1*cos(alpha2_b),y2_b+ length_B1*sin(alpha2_b),0)
110 
111  % Part of the revolute joint with the third leg fixed at the base
112  cylinder rb (x3_b-length_B1*cos(alpha3_b),y3_b-length_B1*sin(alpha3_b),0)
113  (x3_b-0.5*length_B1*cos(alpha3_b),y3_b-0.5*length_B1*sin(alpha3_b),0)
114  sphere rb (x3_b-length_B1*cos(alpha3_b),y3_b-length_B1*sin(alpha3_b),0)
115  cylinder rb (x3_b+0.5*length_B1*cos(alpha3_b),y3_b+0.5*length_B1*sin(alpha3_b),0)
116  (x3_b+ length_B1*cos(alpha3_b),y3_b+ length_B1*sin(alpha3_b),0)
117  sphere rb (x3_b+ length_B1*cos(alpha3_b),y3_b+ length_B1*sin(alpha3_b),0)
118 
119 
120 platform: 0.5*green
121  sphere rb*1.5 (x1_p,y1_p,0)
122  sphere rb*1.5 (x2_p,y2_p,0)
123  sphere rb*1.5 (x3_p,y3_p,0)
124  cylinder rb*1.5 (x1_p,y1_p,0)(x2_p,y2_p,0)
125  cylinder rb*1.5 (x1_p,y1_p,0)(x3_p,y3_p,0)
126  cylinder rb*1.5 (x2_p,y2_p,0)(x3_p,y3_p,0)
127 
128  cylinder rb (x1_p-0.5*length_B1*cos(alpha1_p),y1_p-0.5*length_B1*sin(alpha1_p),0)
129  (x1_p+0.5*length_B1*cos(alpha1_p),y1_p+0.5*length_B1*sin(alpha1_p),0)
130 
131  cylinder rb (x2_p-0.5*length_B1*cos(alpha2_p),y2_p-0.5*length_B1*sin(alpha2_p),0)
132  (x2_p+0.5*length_B1*cos(alpha2_p),y2_p+0.5*length_B1*sin(alpha2_p),0)
133 
134  cylinder rb (x3_p-0.5*length_B1*cos(alpha3_p),y3_p-0.5*length_B1*sin(alpha3_p),0)
135  (x3_p+0.5*length_B1*cos(alpha3_p),y3_p+0.5*length_B1*sin(alpha3_p),0)
136 
137 
138 leg1_a: cylinder rb (0,0,0) (0,0,lenght_A)
139 
140  cylinder rb (-0.5*length_B1,0,0)
141  (+0.5*length_B1,0,0)
142  cylinder rb (-0.5*length_B1,0,lenght_A)
143  (+0.5*length_B1,0,lenght_A)
144 
145 
146 leg1_b1: 0.75*white
147  cylinder rb (0,0,0) (0.5*length_B1,0,0)
148  cylinder rb (1.5*length_B1,0,0) (2*length_B1,0,0)
149 
150  cylinder rb (0,0,-length_B1) (0,0,-0.5*length_B1)
151  sphere rb (0,0,-length_B1)
152 
153  cylinder rb (0,0,0.5*length_B1) (0,0,length_B1)
154  sphere rb (0,0, length_B1)
155 
156  cylinder rb (2*length_B1,0,-length_B1) (2*length_B1,0,-0.5*length_B1)
157  sphere rb (2*length_B1,0,-length_B1)
158 
159  cylinder rb (2*length_B1,0,0.5*length_B1) (2*length_B1,0,length_B1)
160  sphere rb (2*length_B1,0, length_B1)
161 
162 leg1_b2: 0.25*white
163  cylinder rb (0,0,0)
164  (length_B,0,0)
165  cylinder rb (0,0,-0.5*length_B1)
166  (0,0, 0.5*length_B1)
167 
168  cylinder rb (length_B,0, 0.5*length_B1)
169  (length_B,0, length_B1)
170  sphere rb (length_B,0, length_B1)
171  cylinder rb (length_B,0,-0.5*length_B1)
172  (length_B,0, -length_B1)
173  sphere rb (length_B,0, -length_B1)
174 
175 leg1_b3: 0.25*white
176  cylinder rb (0,0,0)
177  (length_B,0,0)
178  cylinder rb (0,0,-0.5*length_B1)
179  (0,0, 0.5*length_B1)
180  cylinder rb (length_B,0, 0.5*length_B1)
181  (length_B,0, length_B1)
182  sphere rb (length_B,0, length_B1)
183  cylinder rb (length_B,0,-0.5*length_B1)
184  (length_B,0, -length_B1)
185  sphere rb (length_B,0, -length_B1)
186 
187 leg1_b4: 0.75*white
188  cylinder rb (0,0,0)
189  (0.5*length_B1,0,0)
190  cylinder rb (1.5*length_B1,0,0)
191  ( 2*length_B1,0,0)
192  cylinder rb (0,0,-0.5*length_B1)
193  (0,0, 0.5*length_B1)
194  cylinder rb (2*length_B1,0,-0.5*length_B1)
195  (2*length_B1,0, 0.5*length_B1)
196 
197 leg2_a: cylinder rb (0,0,0) (0,0,lenght_A)
198  cylinder rb (-0.5*length_B1,0,0)
199  (+0.5*length_B1,0,0)
200  cylinder rb (-0.5*length_B1,0,lenght_A)
201  (+ 0.5*length_B1,0,lenght_A)
202 
203 
204 leg2_b1: 0.75*white
205  cylinder rb (0,0,0) (0.5*length_B1,0,0)
206  cylinder rb (1.5*length_B1,0,0) (2*length_B1,0,0)
207 
208  cylinder rb (0,0,-length_B1) (0,0,-0.5*length_B1)
209  sphere rb (0,0,-length_B1)
210  cylinder rb (0,0,0.5*length_B1) (0,0,length_B1)
211  sphere rb (0,0, length_B1)
212  cylinder rb (2*length_B1,0,-length_B1) (2*length_B1,0,-0.5*length_B1)
213  sphere rb (2*length_B1,0,-length_B1)
214  cylinder rb (2*length_B1,0,0.5*length_B1) (2*length_B1,0,length_B1)
215  sphere rb (2*length_B1,0, length_B1)
216 
217 leg2_b2: 0.25*white
218  cylinder rb (0,0,0)
219  (length_B,0,0)
220  cylinder rb (0,0,-0.5*length_B1)
221  (0,0, 0.5*length_B1)
222 
223  cylinder rb (length_B,0, 0.5*length_B1)
224  (length_B,0, length_B1)
225  sphere rb (length_B,0, length_B1)
226  cylinder rb (length_B,0,-0.5*length_B1)
227  (length_B,0, -length_B1)
228  sphere rb (length_B,0, -length_B1)
229 
230 leg2_b3: 0.25*white
231  cylinder rb (0,0,0)
232  (length_B,0,0)
233  cylinder rb (0,0,-0.5*length_B1)
234  (0,0, 0.5*length_B1)
235 
236  cylinder rb (length_B,0, 0.5*length_B1)
237  (length_B,0, length_B1)
238  sphere rb (length_B,0, length_B1)
239  cylinder rb (length_B,0,-0.5*length_B1)
240  (length_B,0, -length_B1)
241  sphere rb (length_B,0, -length_B1)
242 
243 leg2_b4: 0.75*white
244  cylinder rb (0,0,0)
245  (0.5*length_B1,0,0)
246  cylinder rb (1.5*length_B1,0,0)
247  ( 2*length_B1,0,0)
248 
249  cylinder rb (0,0,-0.5*length_B1)
250  (0,0, 0.5*length_B1)
251  cylinder rb (2*length_B1,0,-0.5*length_B1)
252  (2*length_B1,0, 0.5*length_B1)
253 
254 
255 leg3_a: cylinder rb (0,0,0) (0,0,lenght_A)
256 
257  cylinder rb (-0.5*length_B1,0,0)
258  (+0.5*length_B1,0,0)
259  cylinder rb (-0.5*length_B1,0,lenght_A)
260  (+0.5*length_B1,0,lenght_A)
261 
262 
263 leg3_b1: 0.75*white
264  cylinder rb (0,0,0) (0.5*length_B1,0,0)
265  cylinder rb (1.5*length_B1,0,0) (2*length_B1,0,0)
266 
267  cylinder rb (0,0,-length_B1) (0,0,-0.5*length_B1)
268  sphere rb (0,0,-length_B1)
269  cylinder rb (0,0,0.5*length_B1) (0,0,length_B1)
270  sphere rb (0,0, length_B1)
271  cylinder rb (2*length_B1,0,-length_B1) (2*length_B1,0,-0.5*length_B1)
272  sphere rb (2*length_B1,0,-length_B1)
273  cylinder rb (2*length_B1,0,0.5*length_B1) (2*length_B1,0,length_B1)
274  sphere rb (2*length_B1,0, length_B1)
275 
276 leg3_b2: 0.25*white
277  cylinder rb (0,0,0)
278  (length_B,0,0)
279  cylinder rb (0,0,-0.5*length_B1)
280  (0,0, 0.5*length_B1)
281 
282  cylinder rb (length_B,0, 0.5*length_B1)
283  (length_B,0, length_B1)
284  sphere rb (length_B,0, length_B1)
285  cylinder rb (length_B,0,-0.5*length_B1)
286  (length_B,0, -length_B1)
287  sphere rb (length_B,0, -length_B1)
288 
289 leg3_b3: 0.25*white
290  cylinder rb (0,0,-0.5*length_B1)
291  (0,0, 0.5*length_B1)
292  cylinder rb (length_B,0, 0.5*length_B1)
293  (length_B,0, length_B1)
294 
295  cylinder rb (0,0,0)
296  (length_B,0,0)
297  sphere rb (length_B,0, length_B1)
298  cylinder rb (length_B,0,-0.5*length_B1)
299  (length_B,0, -length_B1)
300  sphere rb (length_B,0, -length_B1)
301 
302 leg3_b4: 0.75*white
303  cylinder rb (0,0,-0.5*length_B1)
304  (0,0, 0.5*length_B1)
305  cylinder rb (0,0,0)
306  (0.5*length_B1,0,0)
307  cylinder rb (1.5*length_B1,0,0)
308  ( 2*length_B1,0,0)
309  cylinder rb (2*length_B1,0,-0.5*length_B1)
310  (2*length_B1,0, 0.5*length_B1)
311 
312 [JOINTS]
313 %---------------------------------------------------------
314 
315 revolute: base (x1_b,y1_b,0)+(cos(alpha1_b),sin(alpha1_b),0)
316  leg1_a (0,0,0)+(1,0,0)
317  range [theta1_min,theta1_max] +(cos(beta1_b),sin(beta1_b),0) +(0,-1,0)
318 
319 revolute: leg1_a (0,0,lenght_A)+(1,0,0)
320  leg1_b1 (length_B1,0,0)+(1,0,0)
321 
322 revolute: leg1_b1 (0,0,0)+(0,0,1)
323  leg1_b2 (0,0,0)+(0,0,1)
324  range [-pi/2,pi/2] +(0,1,0) +(1,0,0)
325 
326 revolute: leg1_b1 (2*length_B1,0,0)+(0,0,1)
327  leg1_b3 (0,0,0)+(0,0,1)
328 
329 revolute: leg1_b2 (length_B,0,0)+(0,0,1)
330  leg1_b4 (0,0,0)+(0,0,1)
331 
332 revolute: leg1_b3 (length_B,0,0)+(0,0,1)
333  leg1_b4 (2*length_B1,0,0)+(0,0,1)
334 
335 revolute: leg1_b4 (length_B1,0,0)+(1,0,0)
336  platform (x1_p,y1_p,0)+(cos(alpha1_p),sin(alpha1_p),0)
337 
338 %---------------------------------------------------------
339 
340 revolute: base (x2_b,y2_b,0)+(cos(alpha2_b),sin(alpha2_b),0)
341  leg2_a (0,0,0)+(1,0,0)
342  range [theta2_min,theta2_max] +(cos(beta2_b),sin(beta2_b),0) +(0,-1,0)
343 
344 revolute: leg2_a (0,0,lenght_A)+(1,0,0)
345  leg2_b1 (length_B1,0,0)+(1,0,0)
346 
347 revolute: leg2_b1 (0,0,0)+(0,0,1)
348  leg2_b2 (0,0,0)+(0,0,1)
349  range [-pi/2,pi/2] +(0,1,0) +(1,0,0)
350 
351 revolute: leg2_b1 (2*length_B1,0,0)+(0,0,1)
352  leg2_b3 (0,0,0)+(0,0,1)
353 
354 revolute: leg2_b2 (length_B,0,0)+(0,0,1)
355  leg2_b4 (0,0,0)+(0,0,1)
356 
357 revolute: leg2_b3 (length_B,0,0)+(0,0,1)
358  leg2_b4 (2*length_B1,0,0)+(0,0,1)
359 
360 revolute: leg2_b4 (length_B1,0,0)+(1,0,0)
361  platform (x2_p,y2_p,0)+(cos(alpha2_p),sin(alpha2_p),0)
362 
363 %---------------------------------------------------------
364 
365 revolute: base (x3_b,y3_b,0)+(cos(alpha3_b),sin(alpha3_b),0)
366  leg3_a (0,0,0)+(1,0,0)
367  range [theta3_min,theta3_max] +(cos(beta3_b),sin(beta3_b),0) +(0,-1,0)
368 
369 revolute: leg3_a (0,0,lenght_A)+(1,0,0)
370  leg3_b1 (length_B1,0,0)+(1,0,0)
371 
372 revolute: leg3_b1 (0,0,0)+(0,0,1)
373  leg3_b2 (0,0,0)+(0,0,1)
374  range [-pi/2,pi/2] +(0,1,0) +(1,0,0)
375 
376 revolute: leg3_b1 (2*length_B1,0,0)+(0,0,1)
377  leg3_b3 (0,0,0)+(0,0,1)
378 
379 revolute: leg3_b2 (length_B,0,0)+(0,0,1)
380  leg3_b4 (0,0,0)+(0,0,1)
381 
382 revolute: leg3_b3 (length_B,0,0)+(0,0,1)
383  leg3_b4 (2*length_B1,0,0)+(0,0,1)
384 
385 revolute: leg3_b4 (length_B1,0,0)+(1,0,0)
386  platform (x3_p,y3_p,0)+(cos(alpha3_p),sin(alpha3_p),0)
387 
388 %---------------------------------------------------------
389 %fix: base platform Tz(1)
390