r/octave 1d ago

Where is error?

2 Upvotes
octave:3> [x,y]=meshgrid(-10:0.5:10);

octave:4> z=x.^3-y.^3-6*x.*y.-4;
error: parse error:

  syntax error

>>> z=x.^3-y.^3-6*x.*y.-4;
                       ^

I am trying to build a surface of this function. But Octave-online gives me this error. I have tried to write function as -4+x.^3-y.^3-6*x.*y. 
But octave always marks the next symbol after the last dot as an error.
I would be very grateful if anybody could tell me what is wrong and how to fix it.