Your examples are pretty simple, are you trying to make a generic 'fraction'
or is there only a certain set of values you can accept?
I'd be thinking about 1/(2^n) fractions as an approximation...
Considering that you only have an 8bit number to start with, this means you
can only go from 0255... this is probably an exploitable limitation.
Ben
"Iqbal" <(EMail Removed)> wrote in message
news:(EMail Removed) oups.com...
> Hi all,
>
> I need to do arithmetic using fractions eg. adding +1/4 of an 8 bit
> value to another 8 bit value or subtracting
> 1/16 of an 8 bit value from another 8 bit value.
>
> Can anyone tell me how I can do this in VHDL or point me in the right
> direction ?
>
> Thanks
>
