LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Cylindrical coordinate system (CW3DGraph)

Hi, i'd like to know witch function (of CW3DGraph) I need to use if I want to plot a graph into a Cylindrical Coordinate System.
 
For a Cartesian Coordinate System I use :
 
          CA_VariantSet2DArray (&vArray, CAVT_DOUBLE, 180, 100, &Matrix);
          CW3DGraphLib_CWPlot3DPlot3DSimpleSurface (plotHandle, NULL, vArray, CA_DEFAULT_VAL);
 
I'd like to have a sample... if possible.
 
Thanks
0 Kudos
Message 1 of 3
(3,505 Views)
Hi mico,

You can change the coordinate system of the CWGraph3D Control by right clicking on it from your User Interface and selecting Properties.  In the Properties window, select the Plot tab, and then in the Style sub-tab, you can change the Coordinate system to Cylindrical.  Once you have done this, you can write to the CWGraph3D Control in the same manner that you do when using Cartesian coordinates.

The only difference from having the coordinate system set to Cartesian is that your data will be in (theta, z, r) format instead of (x, y, z) format.  There are a number of simple 3D graphing examples that ship with LabWindows/CVI.  These can be found by going to Help » Find Examples » Communicating with External Applications » ActiveX » General and selecting any of 3D projects which include 3DGraph.prj, 3DGraphAxis.prj, 3DGraphColorMap.prj, and 3DGraphContours.prj.  Most of these examples are setup to do Cartesian graphing, but can be easily modified to do cylindrical graphing using the steps outlined above.

Hope this helps!


0 Kudos
Message 2 of 3
(3,489 Views)
Hi Jonathan,
is it possible to change the axis to cylindrical representation too?

Babak

0 Kudos
Message 3 of 3
(3,460 Views)