[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
script failure with 2.1.50
From: |
daron |
Subject: |
script failure with 2.1.50 |
Date: |
Tue, 17 Feb 2004 00:55:13 -0600 |
User-agent: |
Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.6) Gecko/20040206 |
Hi all,
Using FreeBSD 4.9 ( octave was compiled from the ports collection), this
simple script fails :
#! /usr/local/bin/octave -q
Ew = 1.0;
# Generate vector of trigger periods
Tp = linspace(100*Ew, 0.1*Ew, 2048);
# Calculate fraction: missed events = 1 - (EventRate/TriggerRate)
# and trigger rates
for i = 1:length(Tp)
f(i) = 1.0 - ((ceil(Ew/Tp(i)) - (Ew/Tp(i)))*Tp(i) + Ew)^-1/(Tp(i)^-1);
Tr(i) = 1.0/Tp(i);
endfor
plot(Tr, f);
pause();
The error message is :
./ideal.m: line 4: Ew: command not found
./ideal.m: line 7: syntax error near unexpected token `('
./ideal.m: line 7: `Tp = linspace(100*Ew, 0.1*Ew, 2048);'
Could someone please shed some light on a possible cause/fix ? The
script works fine with an older octave version ( 2.1.34, I believe ) on
a Linux machine.
Thanks,
-- dc
-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.
Octave's home on the web: http://www.octave.org
How to fund new projects: http://www.octave.org/funding.html
Subscription information: http://www.octave.org/archive.html
-------------------------------------------------------------
- script failure with 2.1.50,
daron <=