0
$\begingroup$

Mathematica display complex fractions like this,

enter image description here

the second x look smaller, I want it look like this, how can I get it in Mathematica?

enter image description here

$\endgroup$
1
  • $\begingroup$ Use Text instead of TraditionalForm $\endgroup$
    – bill s
    Commented Jul 25, 2014 at 2:41

2 Answers 2

1
$\begingroup$

Start with

HoldForm[1/(1 + 1/x)] // TraditionalForm

which produces the fraction box in reduced size.

reduced

Now open the output cell with Cmnd+Shift+e and add FractionBoxOptions->{AllowScriptLevelChange->False} at the end.

Cell[BoxData[
  FormBox[
    TagBox[
      FractionBox["1", 
        RowBox[{"1", "+", 
        FractionBox["1", "x"]}]],
      HoldForm], TraditionalForm]], "Output",
  FractionBoxOptions->{AllowScriptLevelChange->False}]

Close close the cell with Cmnd+Shift+e and you will see

full-size

Note. I think on Windows it is Ctrl+Shift+e

Another way is to use the Option Inspector. Select the output cell and make the following change in the Option Inspector.

option-inspector

$\endgroup$
1
$\begingroup$

Just an extended comment to the answer of m_goldberg.

Without changing the standard settings in Option Inspector:

fractionStyle = Style[#, DefaultOptions -> {FractionBoxOptions -> {AllowScriptLevelChange -> False}}] &;
HoldForm[1/(1 + 1/x)] // fractionStyle // TraditionalForm

An additional advantage using DefaultOptions is i.e. having a list of fractions, or any other bigger programming construct, fractionStyle is applied only once at the end (like TraditionalForm).

$\endgroup$

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