|
From: | Kai Torben Ohlhus |
Subject: | Re: Right shifting in octave |
Date: | Fri, 2 May 2014 11:10:55 +0200 |
Hey everyone,
I am writting a simple crc32 program in octave, i have a working program
written in c as a guideline/help. Right now i am stuck with the
rightshifting:
in c:
unsigned int crc = -85
unsigned int number = (crc >> 1);
The result is a really big number 2147483605. Basicly i get the same result
as if i put 0xFFFFFFFF instead of -85. And the program works.
In Octave i get a really small number -43:
crc = -85
a = bitshift(crc, -1)
How can i duplicate the big result from c in octave ?
--
View this message in context: http://octave.1599824.n4.nabble.com/Right-shifting-in-octave-tp4663871.html
Sent from the Octave - General mailing list archive at Nabble.com.
_______________________________________________
Help-octave mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/help-octave
[Prev in Thread] | Current Thread | [Next in Thread] |