Specify and control how Mathematica formats its output, including rich text, equations and graphics.

learn more… | top users | synonyms

1
vote
1answer
36 views

TreeForm expression that will automatically spread nodes so labels do not overlap

My deeply and unevenly nested lists and equations generate a TreeForm image which is too small and compressed to use. Then we must expand it manually by grabbing the edge of the image, and sometimes ...
1
vote
1answer
30 views

How to update Print-out “in place”?

I want to run an exhaustive search algorithm that will take several hours to finish, so I'd like to have it execute Print statement periodically, showing the ...
0
votes
1answer
45 views

Forcing an integral to be solved in separate terms

Using Mathematica I want to solve an integral over a function that contains both determined and undetermined parts which looks like this: ...
1
vote
2answers
100 views

Stopping Mathematica from reordering expressions [duplicate]

I want Mathemtica to stop manipulating my polynomials! I mean, I want the output of Print[3 x + 5 + x^2] to be just $3x+5+x^2$, not $5+3x+x^2$ as Mathematica ...
0
votes
1answer
49 views

sorting of expression with complex parts

I have an expression: a + i*b + d + i*e + r = 0 Now I want Mathematica to sort this like: a + d + r + i(b + e) How can I ...
3
votes
1answer
68 views

Symbolic Output after numerical computation

I have a small question about the symbolic output. I started to write a program that generates the coordinates of n-dimensional polytopes by Wythoff construction. For crystallographic groups, all is ...
1
vote
2answers
43 views

How to eliminate (hide) output numbers in a slide show

I am creating a slide show with several imbedded Manipulate objects. I can hide the Manipulate command by clicking on the ...
0
votes
1answer
50 views

User defined output forms

I have a mathematica program which performs some manipulation which I then want to continue in another language, as I already have some code written in it. Syntactically this language is very similar ...
2
votes
2answers
61 views

Assign named placeholder to a variable (as a string)

If I want to assign a regular placeholder as a string, it's very easy: (anything the user types in will automatically be given quotes around it, so when they evaluate the cell str is a string) ...
0
votes
2answers
46 views

How to output (anything) if any error happens

I have long code which goes through iteration process. some times I get error messages. I want to get the iteration numbers (or any kind of output indications) when errors happen. for example, how ...
2
votes
2answers
68 views

Rounding only coefficients

does Mathematica have built in functionality to round the coefficients of a polynomial to a certain accuracy. Say, we do Print[0.2134320980x^2+0.0023432x] Can ...
3
votes
1answer
53 views

Print prints into the Messages notebook rather than into the evaluation notebook

Some time ago I noticed that the results of the evaluating the function Print[something] does not emerge in a new cell created in the notebook where the operation ...
3
votes
1answer
141 views

Control over the way matrix is displayed

I am wondering how to change the output format in Mathematica. For example, I have $x=\binom{3}{1}$ and $y=\binom{2}{5}$, and I want to find what linear combination of $x$ and $y$ produces ...
1
vote
1answer
35 views

How to use Notation package with TraditionalForm

I know that I can use the Notation package to define my own custom notation. This works great for StandardForm output, but I ...
2
votes
1answer
69 views

Write numbers to a file

I want create file with some text (and numbers). This is my code. ...
0
votes
4answers
114 views

Conditionally formatting elements in a list

I have a list {{a1, a2, a3},{b1, b2, b3}, ...} and I want to replace the numbers less than 10 by 0x (just insert a 0 before the ...
3
votes
1answer
91 views

Frame thickness in Framed[] [duplicate]

I need to change the frame thickness in Framed[] in order to create a legend box. How can I set the frame thickness in Framed[]? ...
1
vote
3answers
84 views

Row and Column Headings for a Grid

It would be useful for me if I could write: Grid[{{a, b}, {c, d}, {e, f}}, GridHeadings -> {{"r1", "r2", "r3"}, {"c1", "c2"}}] just like ...
1
vote
2answers
55 views

How to remove a gap between the chart labels and the frame in a BoxWhiskersPlot

When making a nested BoxWhiskersPlot with chart labels, the labels are nicely spaced below the bottom frame when using labels for all nested data ...
2
votes
2answers
98 views

Use only exponents (no radicals) in output expressions

Radical symbols ($\sqrt{\,\,\,\,}$) are the devil. Is there any way to get mathematica to never use them, and instead express everything as an exponential? i.e. I want ...
2
votes
2answers
85 views

Set all output to be of specific form

I want every output expression in a notebook to use //PowerExpand and also to format numbers as scientific. Is there a way to do this without explicitly calling ...
1
vote
1answer
69 views

Typesetting help

I have a rather simple question that has me flummoxed. Let's say I have two matrices: m1 = {{a1, a2}, {b1, b2}}; m2 = {{u1, v1}, {u2, v2}}; I am looking to ...
1
vote
1answer
50 views

Save selection as PDF - non-image format

I am trying to save the following plot as a pdf, so that I can import it into LaTeX: ...
1
vote
1answer
37 views

Evaluation of m.v is blocked by applying MatrixForm. Why? [duplicate]

I'm trying to understand what is happening in the notebook session below. I have a 2x2 matrix m = {{-1,-1}, {-1,-1}}. And a vector ...
0
votes
1answer
65 views

export table with number written in scientific notation

I am trying to write on a file the table generated in this way: ...
1
vote
1answer
47 views

Grouping Nested Lists Based on Differing Values of Single Element

I've a list of lists representing k-rows of truth table having n elements each in a nested list consider ...
0
votes
1answer
63 views

How to format output when using Manipulate

As in the title, I want to output the image of a 3D body with its volume and surface area shown nicely beside it. (Maybe in a table?) But how can I do it? Is it possible to calculate the surface area ...
4
votes
2answers
120 views

Plots using TextAlignment with SwatchLegend to left align multi-line items

I have Legends that stretch over multi-lines and the only way I can get them left aligned is by adding white space to the end of the legend item. Does anyone know if there is a way to use ...
4
votes
2answers
91 views

Fractions formatting in Column / Grid

Fractions are squished in GridBox: ...
2
votes
1answer
91 views

Display negative exponents always as fraction

I want Mathematica to display negative exponents always as fractions. I already tried: ...
12
votes
3answers
302 views

Format and TeXForm does not work as expected

Recently, we had a nice question which brought up an issue that I believe is a bug. In the tutorial Defining Output Formats is an example at the end which doesn't make sense This specifies the ...
12
votes
3answers
280 views

TeXForm and large brackets (\Biggl[ etc)

Goal I am trying to export a very long expression like expr = c1*bracket1[a+b+c2*bracket2[d+e+f...]]+... to LaTeX using ...
0
votes
0answers
59 views

How to hide brackets and create bars over variables

I have two problems figuring out how to format my formulas properly so that when I print out the notebook the formulas look like the ones in my textbook. So far I've got this: $\sum\limits_{i=1}^5 ...
0
votes
0answers
34 views

Visible (or selectively visible) multiplication operator in output

I don't like the way that Mathematica hides the multiplication symbol when two variables appear adjacent in the multiplication, because the space between them isn't always sufficient to clearly see ...
4
votes
1answer
75 views

Is it possible to Print into a collapsable CellGroup?

During rather long computation I have intermediate steps Printed with useful information which should be collected for possible use in future inside of the ...
3
votes
1answer
84 views

Converting string representation of boxes into explicit boxes

It is very easy and convenient to write textual labels as Strings in the WYSIWYG mode. For example, I define a short form describing a linear model: ...
6
votes
3answers
321 views

Transforming a mutiplication into an addition

How can I force Mathematica to transform 5a into a+a+a+a+a
3
votes
2answers
100 views

Real and/or improved CForm of expressions

I'd quite like to be able to automatically generate C++ versions of certain mathematical expressions that I've manipulated in Mathematica. The resultant C++ code fragment is then going to be used ...
0
votes
1answer
50 views

Substituting a function in the output

I have to calculate the derivatives of the function K defined in the code: ...
1
vote
0answers
24 views

Ordering the Terms in an Expression [duplicate]

Why does Mathematica almost always put subtractions as the first term in a summation (as a negative summed with the rest)? How do I circumvent this feature so that every occurrence of "-" follows ...
1
vote
1answer
44 views

Formatting All Appropriate Output as Desired Automatically

I want to output in MatrixForm whenever I have a list/vector/matrix, but I do not want to have to type out the command each time. How can I write one command at ...
2
votes
0answers
28 views

How to simplify a polynomial and get the results in the order that I want? [duplicate]

How to simplify a polynomial in a order that I want? Assume that I have a polynomial here, for example, $a^3 b^4 c^2$, the order of symbels is the dictionary order, $a>b>c$. But what if I want ...
2
votes
3answers
149 views

Wrapping a data selection in Mathematica

I was wondering what would be the most efficient way to add brackets to given elements in my data set in order to change it's form from {{a,b},{c,d}} to {{{a},b},{{c},d}}. I took a look through a few ...
2
votes
1answer
73 views

Make FactorInteger print its result with CenterDot and Superscript?

I know that if I use CenterDot @@ (Superscript @@@ FactorInteger[x]) Mathematica will pretty print the output. However, is it possible to tell Mathematica to ...
2
votes
3answers
101 views

String formatting

I have the following string: "174,861.00 ( 4,053.52) 206,850.48 118.29 ( 31,989.48)" Parentheses stand for negative numbers. I will like to get ...
0
votes
3answers
53 views

Printing the base 'b' value of an integer as a string (without the subscript base indication)

Is there a simple one-liner to convert a given base 10 integer to a string representation of this integer in some desired base 'b'? Is there a way to do this avoiding the subscript indicating the ...
2
votes
1answer
44 views

Problem with parentheses and ScriptBaselineShifts

Style[ DisplayForm@RowBox[{"(", SubsuperscriptBox[2, 6, 7], ")"}], 18, Bold, ScriptSizeMultipliers -> 1, ScriptBaselineShifts -> {1, 3}] or for ...
1
vote
1answer
75 views

How to operate with function body without evaluation

I have several functions (let a[x] and b[x]), defined as expressions with integrals and differentiations. I want to perform some ...
0
votes
1answer
61 views

Customize TableForm behavior for a single function

I have a function of this form Garch[a,b,c....] that gives me a list as an output,where the first column collects names of output variables. Is it possible ...