MathGroup Archive 2000

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

Search the Archive

Re: 1/Trig function - help

  • To: mathgroup at
  • Subject: [mg24271] Re: 1/Trig function - help
  • From: "David Bailey" <db at>
  • Date: Wed, 5 Jul 2000 23:10:55 -0400 (EDT)
  • Organization: University of Salford, Salford, Manchester, UK
  • References: <8jteta$>
  • Sender: owner-wri-mathgroup at

<zhl67 at> wrote in message news:8jteta$iic at
> Hello,
> For some reason I wish the trigonometric functions to the power of -1
> not automatically evaluated to some other trig functions. For instance,
> I wish the out put of
> In[1]:= Sin[x]^(-1)
> remain unchanged or appears as
>            1
> Out[1]:=-------
>         Sin[x]
> but NOT Csc[x]. Is there any cost efficient way to do this? Adding
> rules to Power function might do(I only wish this feature for certain
> argumentx x), but it slows down the Power function at the same time.

The problem is that Mathematica always applies these 'simplifications' to
any output it generates. One answer is to use a set of replacement rules of
the form Csc[x_]->1/sin[x] (etc. for other trig functions you want to
eliminate). Because 'sin' is spelled in lower case it will not be recognised
by Mathematica and simplified back to the undesired form.

You can always use another set of replacement rules to replace sin by Sin
etc. if you want to process the result further.

I would not have thought 'cost efficiency' was relevant here.

David Bailey
Salford Software

  • Prev by Date: Re: 1/Trig function - help
  • Next by Date: Re: Using Block instead of Module?
  • Previous by thread: Re: 1/Trig function - help
  • Next by thread: RE: Re: 1/Trig function - help