manpagez: man pages & more
info mathgl
Home | html | info | man
[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

9.2.2 Transformation (Python)

Method on mglGraph (Python): void SetFunc (const char *EqX=NULL, const char *EqY=NULL, const char *EqZ=NULL)

Sets the transformation formulas for curvilinear coordinate. Each string should contain mathematical expression for real coordinate depending on internal coordinates x, y, z. For example, the cylindrical coordinates are introduced as SetFunc("x*cos(y)", "x*sin(y)", "z");. For removing of formulas the corresponding parameter should be NULL. Using transformation formulas will slightly slowing the program, i.e. SetFunc(NULL, NULL, NULL) is faster than SetFunc("x", "y", "z"). See section mglFormula class.

Method on mglGraph (Python): void Ternary (bool tern)

The function sets to draws Ternary plot. This special plot is for 3 dependent coordinates (components) a, b, c so that a+b+c=1. MathGL uses only 2 independent coordinates a=x and b=y since it is enough to plot everything. At this third coordinate z act as another parameter to produce contour lines, surfaces and so on. See section Ternary plot sample, for sample code and picture.


© manpagez.com 2000-2026
Individual documents may contain additional copyright information.