Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Altera_Forum
Honored Contributor I
741 Views

lpm divider output binary format

Is there an easy way to determine or predict the output fixed-point binary format of the lpm_divide function based on the formats of the inputs? I know if multiplying a Qm.n number (e.g. Q16.8 which has 16 integer bits & 8 fractional bits) by a Qp.q number, the output will be Q(m+p).(n+q), e.g. multiplying Q16.8 by Q4.8 will yield a Q20.16 output. For the divider, I used a numerator of Q24.8 and denomiator Q8.8 and it yielded a quotient in Q32.0 and remainder in Q8.8, but I had to determine that by trial & error. Someone know an easier way to know the formats in advance? 

Thanks, GMM
0 Kudos
0 Replies
Reply