Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2004
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2004

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

Search the Archive

Re: Condition , FullSimplify

  • To: mathgroup at smc.vnet.net
  • Subject: [mg53179] Re: Condition , FullSimplify
  • From: David Bailey <dave at Remove_Thisdbailey.co.uk>
  • Date: Tue, 28 Dec 2004 06:30:21 -0500 (EST)
  • References: <cqotbu$cj4$1@smc.vnet.net>
  • Sender: owner-wri-mathgroup at wolfram.com

sebastian.cohen at gmail.com wrote:
> Wolfram Staff,
> 
> I would like to know why the following class of statements don't work
> given
> 
> expr /; condition // FullSimplify
> 
> Although one may express them easily as
> 
> FullSimplify[expr,cond]
> 
> I find it useful and practical using the first notation.
> 
> Is there a way to tell Mathematica at the end expressions both the
> conditions and to fullsimplify without having to write the whole
> fullsimplify function?
> 
> Thanks in advance,
> 
> Sebastian Cohen S
> 
Hi,

It seems a little strange to invent a piece of syntax and then ask why 
Mathematica does not support it! If you really need this functionality, 
why not roll your own:

myFullSimplify[x_Condition]:=FullSimplify[x[[1]],x[[2]]];
myFullSimplify[x]:=FullSimplify[x]

With this definition you can write things like:

Sqrt[x^2] /; x > 0 // myFullSimplify

    x


I hope that helps,

David Bailey
dbaileyconsultancy.co.uk


  • Prev by Date: Re: including files
  • Next by Date: shuffling 10^8 numbers
  • Previous by thread: Re: Condition , FullSimplify
  • Next by thread: including files