octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave 3.2.4 - Error Calculating Powers of 2


From: Jarno Rajahalme
Subject: Re: Octave 3.2.4 - Error Calculating Powers of 2
Date: Thu, 17 Mar 2011 16:31:42 +0200

You want to do this instead:

n=1:50; m=2.^n; disp(m)

  Jarno

On Mar 17, 2011, at 8:47 , ext Vickreman Chettiar wrote:

Hi.
 
  I have recently installed Octave, and I am trying to calculate the powers of two from 1 to 50 with the following code.
n=1:50; m=2^n; disp(m)
I keep getting the following error
error: for x^A, A must be square
and have not so far been able to perform the calculation in Octave.
 
  I see no reason why A has to be square, and I have checked the manual and confirmed that ^ is indeed the symbol for exponentiation. Am I doing something incorrectly, or is this a bug? How do I fix the problem?
 
I am using version 3.2.4 of Octave. My operating-system is the 64-bit version of Microsoft Windows 7 Professional Edition.
 
  Thank you and regards, Vickreman.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]