Changed from Matlab to Octave