title: calculate logarithm using VHDL
body: <p>I am trying to convert a value from linear notation to decibel notation on an FPGA.</p>
  
  <p>While the equation x_dB=10*log(x_lin)   is certainly well known, but I have been unable to implement it in VHDL.</p>
  
  <p>I have found some identities (with arctanh being the most common) which MAY be of use at <a href="http://en.wikipedia.org/wiki/Inverse_hyperbolic_function#Logarithmic_representation" rel="nofollow">http://en.wikipedia.org/wiki/Inverse_hyperbolic_function#Logarithmic_representation</a></p>
  
  <p>Since inverse hyperbolic functions are available through the COordinate Rotation DIgital Computer (CORDIC), this is seems easy enough--except the CORDIC has two inputs (X &amp; Y) as opposed to the single input required by a logarithm, and for that matter the hyperbolic arc tangent function!  How do I figure out what to use for the two input values (x &amp; y) given that I'm really trying to do is a log?</p>