Hi,
ralpt3748752_qejwhe has left the following comment at Model a planetary
gear set in 3D using BRL-CAD
https://www.google-melange.com/gci/task/view/google/gci2014/6464160023969792:
How to write a script?
I wrote the code - finding centers coordinate gear teeth.
Here it is:
from math import *
R = float(input('input R:'))
n = int(input('input the number of tooths:'))
X, Y = (str(input('input center gear x y')).split(' '))
a = 0
########
coord = []
for r in range(n):
x, y, a = str(round(sin(radians(a)) * R + float(X),2)),
str(round(cos(radians(a)) * R + float(Y),2)), a + (360 // n)
coord.append(str(x)+' '+str(y))
print(coord)
How to do it from a script that creates the teeth with these coordinates?
Greetings,
The Google Open Source Programs Team
---
You are receiving this message because you are subscribed to Model a
planetary gear set in 3D using BRL-CAD.
To stop receiving these messages, go to:
https://www.google-melange.com/gci/task/view/google/gci2014/6464160023969792.
------------------------------------------------------------------------------
Dive into the World of Parallel Programming! The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net
_______________________________________________
BRL-CAD Tracker mailing list
brlcad-tracker@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/brlcad-tracker