|
From: | Aziz YÜCELEN |
Subject: | I couldnt run function, I got error |
Date: | Wed, 7 Feb 2018 08:19:08 +0000 |
Hi I am new for octave software. I wrote a function in a file (file name is try3.m ) and ran
# try3.m file function find_point(x, modulo)
xeq1=(x^3)+x+1; xeq2 = mod(xeq1,modulo); for i=0:(modulo-1) yeq1=(i^2); yeq2=mod(yeq1,modulo); if (xeq2==yeq2) printf("results:x= %d icin y=%d \n",x,i); endif endfor endfunction
but I got this result:
>> try3
error: 'x' undefined near line 4 column 7 error: called from try3.m at line 4 column 5
what is wrong? And I want to call this function from cli but how?
Thanks. |
[Prev in Thread] | Current Thread | [Next in Thread] |