# Is it possible to represent every shape as a function?

If I draw any kind of shape on a piece of paper (possible discontinuous), would it be theoretically possible to represent the shape in a mathematical function?

• Sure as long as you're ok with it being parametric Apr 6, 2018 at 17:58
• Any shape you can draw on a paper you can also describe in $x,y$ coordinates. Then you code color into $f(x,y)$. Apr 6, 2018 at 17:58
• If you mean a function $y = f(x).$ Every $x$ value will have at most one $y$ value. And the graph of this function must pass the vertical line test. But, if you want a parametric curve. $(x,y) = (f(t), g(t))$ Then yes, it can be done that way. Apr 6, 2018 at 18:01
• Theoretically, yes, because at every time $t$, your pen is at some point $(x(t),y(t))$ on the paper. But most likely you cant represent the functions $x(t),y(t)$ using elementary functions Apr 6, 2018 at 18:01
• Oh, yes! I forgot! Should I edit and change the question? -Doug M Apr 6, 2018 at 18:06

You have to be careful here. By definition, a function has one possible output for any given input. So if you want your function defined as some $y = f(x)$, then no not every shape can be written as a function. Any shape that has two points directly above each other (relative to the x-axis) cannot be written as a function, even a piecewise one.
However, if you are defining "a function" as any parametric curve $(x,y) = (f(s),g(s))$, then yes this can be done for any shape that can be drawn without lifting your pencil off of the paper. Simply define your parameter $s$ to run along the same path your pencil moves and your $f$ and $g$ are therefore well-defined too.
• @ShuvoSarker That would be valid too technically. But you would have to describe the shape as a piecewise parametric curve. So for each continuous curve, you write $(x_i,y_i) = (f_i(s),g_i(s))$, and you have $i = 1,...,n$ with $n$ distinct curves. Apr 6, 2018 at 18:11
For example, there's no function whose graph is a circle but the equation $$x^2+y^2=1$$ gives a circle of radius 1.