This is documentation for Mathematica 3, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)
 Documentation / Mathematica / Built-in Functions / Programming / Debugging  /

  • TraceAbove is an option for Trace and related functions which specifies whether to include evaluation chains which contain the evaluation chain containing the pattern form sought.
  • TraceAbove -> True includes the first and last expressions in all evaluation chains within which the evaluation chain containing form occurs.
  • TraceAbove -> All includes all expressions in these evaluation chains.
  • TraceAbove -> backward , forward allows you to specify separately which expressions to include in the backward and forward directions.
  • Using TraceAbove, you can see the complete paths by which expressions matching form arose during an evaluation.
  • See the Mathematica book: Section 2.5.10.
  • See also: StackComplete.

    Further Examples

    Here is the recursive definition of the Fibonacci numbers.


    Here are the end conditions for the recursion.



    This shows all the ways that fib[2] is generated during the evaluation of fib[5].