MathGroup Archive 2006

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: showing your work in mathematica

  • To: mathgroup at smc.vnet.net
  • Subject: [mg69834] Re: showing your work in mathematica
  • From: dimmechan at yahoo.com
  • Date: Mon, 25 Sep 2006 03:52:44 -0400 (EDT)
  • References: <ef4von$mjj$1@smc.vnet.net>

I do not know if this is relevant to you but here is one link:

http://library.wolfram.com/infocenter/MathSource/678/

Anyway Trace has some undocumentated in the Help Browser
options that might be interesting for you.

Execute tha following commands
(I have converted everything to Inputform)

Options[Trace]
(Information[Evaluate[#1[[1]]]] & ) /@ %;

TraceInternal is one of them

Information[TraceInternal]
"TraceInternal is an option for Trace and related functions which, if
True or False, specifies whether to trace evaluations of expressions
generated internally by Mathematica. The intermediate Automatic setting
traces a selected set of internal
evaluations including Messages and sets or unsets of visible symbols."
Attributes[TraceInternal] = {Protected}

For example

Simplify[x^2 + 2*x + 1]
(1 + x)^2In[43]:=

Trace[Simplify[x^2 + 2*x + 1], TraceInternal -> True]
{{HoldForm[x^2 + 2*x + 1], HoldForm[1 + 2*x + x^2]},
HoldForm[Simplify[1 + 2*x + x^2]],  {HoldForm[$Assumptions],
HoldForm[True]}, {{HoldForm[N[300]], HoldForm[300.]},
HoldForm[Floor[300.]], HoldForm[300]},
  {{{{HoldForm[N[300]], HoldForm[300.]}, HoldForm[Mod[300., 1]],
HoldForm[0.]}, HoldForm[1000000*0.], HoldForm[0.]},
   HoldForm[Ceiling[0.]], HoldForm[0]}, {HoldForm[General::meprec],
   HoldForm["Internal precision limit $MaxExtraPrecision = `1` reached
while evaluating `2`."]},
  {HoldForm[Off[General::meprec]], {HoldForm[General::meprec],
    HoldForm["Internal precision limit $MaxExtraPrecision = `1` reached
while evaluating `2`."]}, HoldForm[Null]},
  {HoldForm[On[General::meprec]], {HoldForm[General::meprec],
    HoldForm[$Off["Internal precision limit $MaxExtraPrecision = `1`
reached while evaluating `2`."]]}, HoldForm[Null]},
  HoldForm[(1 + x)^2]}

Execute

Trace[FullSimplify[x^2 + 2*x + 1], TraceInternal -> True]

to see the difference.


Regards
Dimitris


  • Prev by Date: Re: DSolve fails with Telegraph equation
  • Next by Date: Re: Help: How to deal with this problem!
  • Previous by thread: RE: showing your work in mathematica
  • Next by thread: Re: showing your work in mathematica