Class Log10


public class Log10
extends java.lang.Object
Helper for log10-related computations.
  • Field Summary

    Modifier and Type Field Description
    (package private) static double HUGE_NEGATIVE  
  • Constructor Summary

    Constructor Description
  • Method Summary

    Modifier and Type Method Description
    static double log10​(double val)
    Adjusted log10 to handle values less or equal to zero.
    static double pow10​(double value)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • log10

      public static double log10​(double val)
      Adjusted log10 to handle values less or equal to zero.

      The logarithm does not result in real numbers for arguments less or equal to zero, but the plot should still somehow handle such values without crashing. So anything ≤ 0 is mapped to a 'really big negative' number just for the sake of plotting.

      Note that in the JFreeChart has another interesting idea for modifying the log10 of values ≤ 10, resulting in a smooth plot for the full real argument range. Unfortunately that clobbers values like 1e-7, which might be a very real vacuum reading.

      val - value for which log10 should be calculated.
      an adjusted log10(val).
    • pow10

      public static double pow10​(double value)
      pow(10, value)