help-octave
[Top][All Lists]
Advanced

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

fractional remainder


From: blah BLABBER
Subject: fractional remainder
Date: Sun, 25 Dec 2005 18:37:46 -0800 (PST)

Howdy folks,

Question: I am a new Octave user and cannot figure out how to grab the remainder of a fraction. For example, if I take 3/4 = 0.75, I just want to grab the 75.

Reason: I would like to check if the remainder is zero in order to determine if a number is odd or even. Any even number divided by 2 will have a remainder of 0, odd numbers will not. I am using this for loop control.

Problem: In Octave,  rem(3,4) gives 3. Obviously I do not understand this function. Can you please suggest the appropriate function to use.

Thanks.


Yahoo! for Good - Make a difference this year.
reply via email to

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