schreib Posted April 10, 2006 Share Posted April 10, 2006 I have NO knowledge of Vector Script. I am looking for someone to advise me or consult with OR even to hire to create a SINE wave using CAD. I am assuming there is no way to creat a SINE wave using typical Vector Works CAD itself -- only by using script. Any suggestions or leads to folks to create this is appreciated. Specifically, I need to create a sine wave with a 2 mm period and approx one mm amplitude that ends up EXACTLY 21 inches long. Brian Quote Link to comment
islandmon Posted April 10, 2006 Share Posted April 10, 2006 Same Curves as a Group then resized to 1mm: Quote Link to comment
NickB Posted April 11, 2006 Share Posted April 11, 2006 Hi islandmon, out of interest, would VectorScript be a good way to go about this? Is it possible to write a script to kind of wrap round a simple mathematical function and then get VectorWorks to plot it? I've wanted to do this on numerous occasions, but never really been able to work out if it was something that could be done simply with VectorScript. Regards, nick [ 04-11-2006, 04:36 PM: Message edited by: NickB ] Quote Link to comment
propstuff Posted April 11, 2006 Share Posted April 11, 2006 I have a script for sine waves and other math curves which I got from Vector Depot I seem to recall. Have a look there. N. Quote Link to comment
schreib Posted April 13, 2006 Author Share Posted April 13, 2006 quote: Originally posted by NickB: Hi islandmon, out of interest, would VectorScript be a good way to go about this? Is it possible to write a script to kind of wrap round a simple mathematical function and then get VectorWorks to plot it? I've wanted to do this on numerous occasions, but never really been able to work out if it was something that could be done simply with VectorScript. Regards, nick Yes your idea is more like what I was thinking of. . . my response to islandmon. . . "I am not much of a power user, sorry to say. I tried to use the cubic spline tool in the tool pallet for polylines as you suggested. I assume that is what you described but even after building a matrix of boxes as guides for snap-to points could not get it to make a good looking ACTUAL sine wave curve. I did not mention that the sine wave must be accurate too. It cannot just look like a sine wave or a cyclic wave. It must follow the mathematical / graphical point locations of a TRUE sine wave. Thus, I was expecting to see something that would lead me to using a sine wave function in Vectorscript if such a thing exists. I noticed the period in yours is not exactly 2.000 either. That also must be met. So, I need a 2 mm period x 1 mm amplitude(2 mm total amplitude) x exactly 533.4mm (21.00") long pure sine wave." any further suggestions are appreciated. Brian S. Quote Link to comment
islandmon Posted April 15, 2006 Share Posted April 15, 2006 This simple script will generate a Sinewave & duplicate it : _______________________________ PROCEDURE makeSineWave; {This script by EJ Armstrong is based on original 'makesin' by Mike Swift} VAR h :HANDLE; x,y,xdif,ydif,DX,DY,d,w :REAL; i,A,P,s,f :INTEGER; BEGIN d:=1; { amplitude/2 } x:=0; y:=0; A:=2; P:=2; s:=360; { curve segmentation multiple of 36 } f:=360/s; { wave frequency } w:=d*2; { wave period } xdif:=A/s; FOR i:=1 TO s DO BEGIN; x:=x+(d/s)*P; y:=d*sin(Deg2Rad((i)*f)); LineTo (x,y); END; FOR i:=1 TO 10 DO BEGIN {number of duplicates} Duplicate(w,0); {duplicate offset x,y } END; END; RUN(makeSineWave); 1 Quote Link to comment
SCParker Posted April 14, 2015 Share Posted April 14, 2015 Thanks Edward. This is very helpful as I'm writing an article about theater dimming and how sinewaves are involved. Scott Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.