How do you call this kind of functions in english?

88 Views Asked by At

I have a couple of formulas that I would like to plot, but I can't find the much needed documentation for them because I don't know how to correctly name them in english .

This formulas assume that both $x$ and $y$ are independent variables ( free to vary ) and use basic functions such as the absolute value of something or simple trigonometric functions like $\mathbb{sin(x)}$ or $\mathbb{cos(x)}$; for example :

  • $|y|-|x|=tan(y)\times{\frac{-(sin(1/x))}{tan(1/y)}}$ preview
  • $|x|\times|y|=cos((cos(x) + sin(y))\times acos(x))$ preview

And by the way if you know a software or framework ( in lua, python, ... etc ), that is able to plot this kind of formulas in an interactive way ( where you have a GUI and you can input a formula on the fly ), please suggest one .

Thanks .

1

There are 1 best solutions below

4
On BEST ANSWER

You could call them 'level sets'. Imagine you have a function

$f(x,y) = |y| - |x| - \tan(y)\frac{-\sin(1/x)}{\tan(1/y)}$

then you're looking for the set of points where $f(x,y) = 0$.

In python:

import matplotlib.pyplot
import numpy as np

delta = 0.05
xrange = np.arange(-10.0, 10.0, delta)
yrange = np.arange(-10.0, 10.0, delta)
x, y = np.meshgrid(xrange,yrange)

f = np.absolute(y) - np.absolute(x) - np.tan(y)*(-np.sin(1/x)/np.tan(1/y))

matplotlib.pyplot.contour(x, y, f, [0])
matplotlib.pyplot.show()