Skip to main content

Timeline for Replacing Tan[x] with Sin[x]/Cos[x]

Current License: CC BY-SA 3.0

6 events
when toggle format what by license comment
Apr 13, 2017 at 12:55 history edited CommunityBot
replaced http://mathematica.stackexchange.com/ with https://mathematica.stackexchange.com/
Dec 13, 2015 at 5:50 comment added JungHwan Min @march. Oh, I didn't realize that! Defer simply does not evaluate the expression altogether, so you cannot apply simplifications inside it; it may not be useful in some cases.
Dec 13, 2015 at 5:40 comment added J. M.'s missing motivation With respect to Defer[]: it renders whatever it's enclosing inert to evaluation, up until you copy and paste it into another cell. So, Defer[Sin[x]/Cos[x]] will give Sin[x]/Cos[x] as output, but if you copy this output into a new cell and evaluate, you get Tan[x]. In contrast, trying the same experiment with HoldForm[] will not give Tan[x]; you need ReleaseHold[] for that. (It admittedly is all becoming a bit confusing at this point.)
Dec 13, 2015 at 5:34 history edited march CC BY-SA 3.0
added 42 characters in body
Dec 13, 2015 at 5:32 comment added march @JHM. It depends, I think. The nice thing about Inactivate here is that you can continue to use all of Mathematica's simplification functions (like Simplify) on the expression. The only thing that changes is the fact that Tan, Sin, and Cos are essentially treated as non-built-in symbols. (That said, I've never used Defer, so I don't know its power.)
Dec 13, 2015 at 5:27 history answered march CC BY-SA 3.0