Lybniz project is a simple function graph plotter in Python on GTK.
Lybniz allows to plot up to three functions on one graph. It needs no installation - simply one Python script.
What's New in This Release:
· 1.3.1 contained a silly mistake, made when I upped the version number just prior to releasing. This fixes it. There are no other changes.
Enter functions in Python syntax with x as the dependent variable. Press the Plot button to see the graph.
Constants and functions of the math module are available.
x**3 - 2 * x
2 * cos(x)
e ** (x / -5) * sin(x)
xMin, xMax, yMin, yMax define the boundaries of the range on the abszissa and ordinate to be displayed.
To zoom in, activate the Zoom In tool button. It divides the range boundaries by half. Zoom out does the opposite. To closer inspect a specific section, drag the mouse cursor over an area. After release of the button the area thus marked will be displayed.
The scale automatically adjusts as you zoom in and out. To switch between decimal and radian styles, use Graph -> Scale Style -> Decimal or Graph -> Scale Style –> Radians
If you wish to use a custom scale select Graph -> Scale Style -> Custom. You can then use the xScale, yScale entries to input the intervals at which marks are displayed on the respective axis.
They can also be stated as expressions.
xMin = pi * -2
xMax = pi * 2
xScale = pi / 2
To save the graph in PNG format choose File -> Save.
Using Graph -> Evaluate you get a dialog box that allows input of an x value and calculates y values.
Operators and Functions.
Expressions are entered in python syntax. The following operators can be used.
Note: multiplication is not implied (use "2*x" not "2x")
+, -, *, /
Plus, minus, multiply, divide
Integer divide. (eg 3/2 = 1)
Raise to the power of
Lybniz has all the math functions of the python standard library available.
These are documented at Python Library Reference - Math.
There are also a few extra functions that may be useful.
Factorial of x (or x!). Note: only works with positive integers
The constants pi and e can be used.
If you liked this article, subscribe to the feed by clicking the image below to keep informed about new contents of the blog: