Télécharger rota_imp.procedur

Retour à la liste

Numérotation des lignes :

  1. * ROTA_IMP PROCEDUR PV090527 25/06/11 21:15:11 12279
  2. 'DEBPROC' ROTA_IMP monmail*'MAILLAGE' angle*'FLOTTANT' poin1*'POINT' poin2*'POINT';
  3. *
  4. * impose une condition de rotation d'un angle angle autour d'un axe poin1 poin2
  5. *
  6. * Attention la raideur fabriquee depend de l'angle
  7. * Attention ne fonctionne pas si il y a des points sur l'axe de rotation
  8. *
  9.  
  10.  
  11. *
  12.  
  13. conf_ref = 'FORM';
  14. 'FORM' ('VIDE' CHPOINT);
  15. 'DEPL' monmail 'TOUR' angle poin1 poin2;
  16.  
  17. coorx = 'COOR' 1 monmail;
  18. coory = 'COOR' 2 monmail;
  19. coorz = 'COOR' 3 monmail;
  20.  
  21. 'FORM' conf_ref;
  22.  
  23. axe = poin2 'MOIN' poin1;
  24. axe = axe / ('NORM' axe);
  25. axex = 'COOR' 1 axe;
  26. axey = 'COOR' 2 axe;
  27. axez = 'COOR' 3 axe;
  28. poin1x = poin1 'COOR' 1;
  29. poin1y = poin1 'COOR' 2;
  30. poin1z = poin1 'COOR' 3;
  31.  
  32. * vecteur radial apres rotation
  33. coorx = coorx - poin1x;
  34. coory = coory - poin1y;
  35. coorz = coorz - poin1z;
  36.  
  37. * normale au vecteur radial et a l'axe de rotation
  38. norm1x = (axey * coorz) - (axez * coory);
  39. norm1y = (axez * coorx) - (axex * coorz);
  40. norm1z = (axex * coory) - (axey * coorx);
  41. normch = (norm1x 'NOMC' 'UX') et (norm1y 'NOMC' 'UY') et (norm1z 'NOMC' 'UZ');
  42.  
  43. * matrice de blocage dans la direction normale
  44. *rrota = 'BLOQ' monmail 'DIRE' normch;
  45. rrota = 'RELA' normch;
  46.  
  47. * coordonnees initiales
  48. coorx = 'COOR' 1 monmail;
  49. coory = 'COOR' 2 monmail;
  50. coorz = 'COOR' 3 monmail;
  51. coorx = coorx - poin1x;
  52. coory = coory - poin1y;
  53. coorz = coorz - poin1z;
  54. coorch = ((coorx 'NOMC' 'UX') et (coory 'NOMC' 'UY') et (coorz 'NOMC' 'UZ')) ;
  55.  
  56. * second membre
  57. lrota = rrota * (coorch * -1);
  58.  
  59. 'FINP' rrota lrota;
  60.  
  61.  
  62.  
  63.  

© Cast3M 2003 - Tous droits réservés.
Mentions légales