CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products []
Cesky English Deutsch
 Visitors: 5444 

CAD tip CAD tip # 8884:

Question CAD 
 %  platform  category 
Q - question

Sinusoid, hypotrochoid, guilloche and other parametric curves in AutoCAD.

A - answer With the free utility CADstudio 2DPlot you can easily use your AutoCAD to generate 2D curve from any mathematical function (XY) - ie. create a curve (2D polyline) representing results of the function. The function has to be defined as XY=f(U) - i.e. returning a (X Y) list as a result of one variable parameter.

On the homepage of 2DPlot you can find several examples of definitions of mathematical functions and specifying intervals of input values and precision of the resulting curve.

With parametrization you can use 2DPlot also for creating guilloches, strophoids, curves based on the hypotrochoide and epitrochoide functions, resp. on Farrel wheels.

General format of 2DPlot calls:

(2dplot fXY u-from u-to ustep)

Example - sinusoide (from -PI to PI, 100 steps):

(defun fSin(u)(list u (sin u)))
(2DPlot fSin (- pi) pi (/ (* 2 pi) 100))

or a parabolic curve (from -2 to 2, 200 steps):

(defun fParabola(u)(list u (* u u)))
(2DPlot fParabola -2.0 2.0 (/ 4.0 200))

The interactive command 2DPLOT offers several samples (sinusoid, catenary...). You can use the job #8) for interesting parametric Farrel wheel curves.

You can use 2DPlot as a replacement of the old tool FPLOT.LSP.

100% *  CAD 
28.10.2012    5271×  
Comments   Tell a friend
applies to: AutoCAD ·

See also:
Tip 9829:DrGrid - parametric grid for AutoCAD drawings.
Tip 9743:How to use XY coordinates from Excel as polyline vertices in AutoCAD?
Tip 9711:3DConstruct - converting a 3D mesh to a frame construct
Tip 9651:Convert a DWG 3D mesh model to an Inventor 3D solid part.
Tip 9625:How to color 3D topo surface model by slope?

Back   All CAD Tips All CAD tips&tricks

Strange Revit message "Square feet per foot". « | » The Ribbon does not have any tabs or panels currently loaded.

Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD:    OS:    Categ: 
Text:  FAQ glossary   

Increase your productivity with our set of BIM add-on functions for Autodesk Revit
CADstudio Revit Tools More info

Please use these tips at your own risk.
CAD Studio (Xanadu) is not responsible for possible problems that may occur as a result of using any of these tips.