Re: Re: Full text of the current warning message(s)

• To: mathgroup at smc.vnet.net
• Subject: [mg33450] Re: Re: Full text of the current warning message(s)
• From: Vladimir Bondarenko <vvb at mail.strace.net>
• Date: Thu, 21 Mar 2002 09:28:20 -0500 (EST)
• Sender: owner-wri-mathgroup at wolfram.com

```Dear Mr Ersek,

Thank you very much for your prompt, almost immediate help.

Your solution looks very nice, and it *does* reproduce
all the required messages (none of them is lost).

However, it looks like that your piece of code also quoted
up to dozen warning messages which were absent at the
computation of the original input,

Integrate[ArcTan[1 - Sqrt[1 - z^(-1)]], {z, -1, 1}];

such as

# 1 (absent at the original computation)

Infinity::"indet": "Indeterminate expression 0 (- Infinity)encountered."

# 2 (absent at the original computation)

Solve::"tdep": "The equations appear to involve the variables to be solved \
for in an essentially non-algebraic way."

# 3 (absent at the original computation)

Solve::"ifun": "Inverse functions are being used by Solve, so some solutions
may not be found."

# 4 (absent at the original computation)

Infinity::"indet": "Indeterminate expression 0 Infinity encountered."

# 5 (absent at the original computation)

Power::"infy": "Infinite expression 1/0^2 encountered."

# 6 (absent at the original computation)

Power::"infy": "Infinite expression 1/0 encountered."

# 7 (absent at the original computation)

ArcTan::"indet": "Indeterminate expression ArcTan[0, 0] encountered."

etc

How could I cut off these spurious messages, and get only 4 warning
messages which came during the actual evaluation
(3 \$MaxExtraPrecision::"meprec", and 1 General::"stop") ?

Regards,

P.S.  Here is my input, cell by cell.

*****************************************************************************************

(* Cell # 1 *)

MyMessageList[_Integer] := Hold[];
\$ModifyMessage = True;
Unprotect[Message];

Message[args__] /; \$ModifyMessage :=
Block[{\$ModifyMessage},
If[MyMessageList[\$Line] === Hold[],
MyMessageList[\$Line] = Hold[Message[args];],
(*else*)
MyMessageList[\$Line] =
Insert[MyMessageList[\$Line], Unevaluated[Message[args]], {1, -2}]];
Message[args]];

Protect[Message];

..........................................................................

(* Cell # 2 *)

Integrate[ArcTan[1-Sqrt[1-z^(-1)]],{z,-1,1}];

..........................................................................

(* Cell # 3 *)

messgs = MyMessageList[6];

..........................................................................

(* Cell # 4 *)

ReleaseHold[messgs]

..........................................................................

```

• Prev by Date: Re: newbie question - plot
• Next by Date: RE: Rolling up some integers
• Previous by thread: RE: Full text of the current warning message(s)
• Next by thread: Re:Full text of the current warning message(s)