Hello,
I am new to Octave. I am taking a signals analysis class this semester that
requires the use of MATLAB. Since I can only use it when I am at the school
computers, and I am not at school most of the time, I downloaded Octave to
use when working on homework. I encountered an error when inputing code from
my book. Here is what happened:
octave-3.0.5:2> dt = 1/100;
octave-3.0.5:3> tt = -1 : dt : 1;
octave-3.0.5:4> Fo =
2;
octave-3.0.5:5> xx = 300*real( exp( j*(2*pi*Fo(tt - 0.75) ) ) );
xx = 300*real( exp( j*(2*pi*Fo*(tt - 0.75) ) ) );
see my change ?
what you have is 2*pi*f(k)
what you want is 2*pi*f*t
Doug
error: expecting integer index, found -1.750000
error: evaluating binary operator `*' near line 5, column 28
error: evaluating binary operator `*' near line 5, column 22
error: evaluating argument list element number 1
error: evaluating argument list element number 1
error: evaluating binary operator `*' near line 5, column 9
error: evaluating assignment _expression_ near line 5, column 4
Am I doing something wrong, or does my book have incorrect syntax in it? I
have tried a few code samples from my book, and all have had errors similar
to this. Any help would be great. Thanks.
Josh
--
View this message in context:
http://old.nabble.com/New-to-Octave-tp27301513p27301513.htmlSent from the Octave - General mailing list archive at
Nabble.com.
_______________________________________________
Help-octave mailing list
address@hiddenhttps://www-old.cae.wisc.edu/mailman/listinfo/help-octave