title: How to read function from keyboard in Octave and use it later?
body: <p>I'm writing a script in Octave to calculate how will a ball bounce on a surface. But the surface is defined by a function that I have to read from user Input.
  I have a line:</p>
  <pre><code>funcInput = input(&quot;f(x,y) = &quot;, &quot;s&quot;)
  </code></pre>
  <p>that take what I write in terminal and save it as string to 'funcInput' variable. So far so good.<br/> Now I need to substitute 'x' and 'y' in this function with other variables I have in this script, and then calculate roots of this function. And I have no idea how to do it...</p>
  <p>Later I want to draw a surface so:</p>
  <pre><code>ezsurf(strcat('@(x, y) ', funcInput))
  </code></pre>
  <p>It produces an error</p>
  <pre><code>error: isinf: not defined for function handle
  </code></pre>
  <p>I guess this function does not take string as argument, cause when I do this:</p>
  <pre><code>ezsurf(@(x, y) (x.^2+y.^2)/10')
  </code></pre>
  <p>it works like a charm. So my question is: how can I make it work or what other way can I read function from user and use it later?</p>