Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.

I'm trying to get this expression to display as typed instead of evaluating the 1/1.121.

SetAttributes[TraditionalForm, NHoldAll];
TraditionalForm[(17.517*CuS^2 - 12.081*CuS + 54.875)/(1.121)]

After reading the documentation I would have thought NHoldAll would have stopped this but it doesn't seem to.

share|improve this question

1 Answer 1

up vote 4 down vote accepted

The correct attribute to set would be HoldAll, but modifying built-in functions like this (setting attributes that affect evaluation) is very likely to break things.

Instead, use HoldForm:

TraditionalForm@HoldForm[(17.517*CuS^2 - 12.081*CuS + 54.875)/(1.121)]

Mathematica graphics

share|improve this answer
    
Much appreciated. –  Cam Mar 5 '13 at 22:49

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.