Forum Discussion
Altera_Forum
Honored Contributor
14 years agologarithm implementation
sir,
plz suggest me the method how can i implement logarithm(bbase 2) in vhdl??:( thnaks in advance.:)1 Reply
- Altera_Forum
Honored Contributor
Depending on your accuracy requirements, you could shift the input until it's between 0 and 1. Count the number of shifts to get the integer portion of the result. Then use a table lookup to find the fractional portion of the result.
Your accuracy will depend on the size of the table.