Questions tagged [formatting]

Questions on typesetting and making your expressions, matrices, operators, equations or formulae look how you want them to.

Filter by
Sorted by
Tagged with
3
votes
1answer
113 views
+50

How to recover these TemplateBox into normal form?

I often use $\TeX$ editor by Insert→Inline TeX Input in PlotLabel to label graphics: I will get a well-formed plot label: But when I Copy As Input Text and paste ...
0
votes
1answer
43 views

Force union "∪" to typeset big

I'm asking about typing math in an inline text cell. So in a text cell, ctrl-9 puts the cursor in an inline cell. Then escunesc1ctrl-_2 produces so evidently that subscript isn't "low enough&...
0
votes
0answers
16 views

Modify typesetting of ↪ with MMA equivalent of \raisebox

I was going to ask about the MMA equivalent of $\TeX$'s \raisebox, since the character ↪ is way too high up in inline cells: vs from TeX Then I found it: ...
0
votes
0answers
22 views

How to Hold a Form function

For Example Hold[HoldForm[FullForm[x]]] ...
29
votes
2answers
468 views

Writing a technical note in Mathematica

I have been using Mathematica for many years, mostly for plotting, derivations and numerical computations. Many times I tried to incorporate some text and formulas in my worksheets. Text is Ok, but ...
4
votes
1answer
121 views

Remove the Times x from display in Inactivate expressions in V13

I tried the solutions given in How do I remove the little × that shows up in the frontend when typing? and Getting rid of the horrible Times x in Mathematica 12.3. They work for standard expressions: ...
2
votes
1answer
71 views

Output function definition as TeXForm with big bracket

I've checked this answer. While it works in Mathematica, the $\LaTeX$ output is weird. ...
7
votes
2answers
330 views

Why is Mathematica changing the output display format?

I do a command like Table[i^5/(i^5 + 7*i + 1) Sin[x]/E^(3 i x), {i, 1, 5}] The output shows up as $$\left\{\frac{1}{9} e^{-3 x} \sin (x),\frac{32}{47} e^{-6 x} \...
1
vote
0answers
54 views

A question about generating table [closed]

Consider a vector that is generated somehow, say vec:={RandomReal[{0,2}],RandomReal[{0,1}],RandomReal[{2,3}]}; Note that it is evaluated on-flight, I cannot ...
0
votes
0answers
50 views

How do I make a symbol for a second derivative?

In my script, I want the second derivative of a function to be a symbol that I can manipulate (i.e. give a value to, use in an expression, etc.). So I want to build a box for the expression:$$\frac{d^...
0
votes
0answers
12 views

How to map a keyboard combination of two keys pressed in sequence with modifiers to a palette?

I am aware of the question How to add a keyboard shortcut to open a Palette. I would like to modify the example there to open the special character palette when I press Ctrl+Shift+S,C. How would I ...
0
votes
0answers
40 views

Why does Format produce this warning as a side-effect?

I'm trying to Format[event[][digit[n_], pos[j_]]] ^:= Column[{n, Row[{"[", j, "]"}]}, Alignment -> Center] which seems to work; evaluating <...
1
vote
2answers
66 views

Control size of extensible parentheses and bracket

Consider \!\(\*SuperscriptBox[f,0]\)((a,b]). I would want that typeset something like $$f^0((a,b])$$ or maybe $$f^0\Big((a,b]\Big)$$ Instead it formats like $$f^0((...
3
votes
0answers
92 views

Creating a style that center aligns columns but tweeks terms that are negative

I have created the following style in a private stylesheet that applies to gridbox structures for matrices. So far I have ...
1
vote
1answer
76 views

Palette to control alignment in formula cells

I would like to create a palette with three buttons: Inserts an alignment marker at the current cursor insertion point (i.e., inserts the character ...
2
votes
0answers
36 views

How to automatically name a Wolfram Notebook after the first title line of code if present?

I have a goal of somehow using Wolfram Mathematica's Notebook object functionality to program an initialization cell that will automatically save and name a new file after a title line of code ...
7
votes
0answers
165 views

How to format notebook like ACL Papers?

I typically use the ICML or ACL paper format in latex which is two-columns (shown below). Is there anyway to get a two column stylesheet that looks similar?
1
vote
1answer
52 views

Is there a way to reduce the vertical white space between input and output in a notebook cell?

Is there a way to control the vertical spacing between input and output cells? If CellMargins is supposed to do it, then what am I doing wrong? In[8]:= CellMargins -> {{1, 1}, {1, 1}}; a = 7 Out[9]...
1
vote
1answer
76 views

How to format linear equation solve

I need to solve the system of linear equations $S_i = \sum_ {r = 1}^\lambda x_ {r, i} E_r$, where $S_i$ is a $\lambda$ - dimensional vector, $i$ runs from 1 to $n$, $r$ runs from 1 to $\lambda$,...
16
votes
1answer
951 views

Getting rid of the horrible Times x in Mathematica 12.3

Revised question to reflect new issues pertinent to Mma 12.3 and that are unresolved by the linked question - this is NOT a DUPLICATE and should not be reflected as such As of Mathematica 12.3, if I ...
0
votes
0answers
61 views

How can I change the way Mathematica orders exponents?

How can I change the ascending order that Mathematica has of ordering the exponents, to a descending one. For example, get ...
4
votes
3answers
223 views

Creating a table from a for loop output [closed]

I have created a For loop that solves f(x)=0 using the Bisection method: ...
1
vote
1answer
46 views

How can I get matrices and text to show up in the same table with MatrixForm?

I'd like to be able to display matrices in the usual written MatrixForm in a table alongside text (or anything that isn't a matrix). Here is an example: ...
2
votes
1answer
72 views

Different Latex is generated when changing a number from 2 to 1. Using HoldForm

This is the most bizzar thing I saw with Mathematica TeXForm. Could someone please explain why it happens and if there is a workaround? First, will show screen shot. I have an expression, when I have ...
0
votes
0answers
54 views

view linebreak symbol

As you see in the above example, In[294] and In[295] looks just the same, but the outputs are different. The fact is that there is no linebreak symbol in In[294], but there is one linebreak symbol in ...
0
votes
1answer
110 views

Writing axis into scientific notation

I want to express numbers on the y-axis using scientific notation for the plot given below. ...
4
votes
3answers
227 views

Showing data in a grid

I tried this code for one variable and it works fine. ...
0
votes
0answers
31 views

How to set small tabs (right) instead of the tall tabs (left) in the menus?

How to set the Mathematica menu tabs with small heigth?
0
votes
1answer
60 views

Seeking help with converting output to formatted text for inclusion in a report

Hello and please forgive the beginners question. I am using Solve on a system of equations where results are presented in a format like the following (data is arbitrary in this example, however all ...
4
votes
4answers
220 views

Is there an easy way to copy a TableForm column and convert it into a vector?

Is there an easy way to take a column output from a TableForm command, like this: ...
3
votes
1answer
61 views

hiding input cells in presentations [duplicate]

I notice that presentations have the input cells (the ones with code) often hidden. Specifically in slide shows. This seems like a pretty basic question, but I can't seem to find out how to do this. ...
2
votes
0answers
33 views

Removing function arguments from expressions with derivatives

( This question is basically the opposite of this one: Variable dependency...easy one ) I would like to be able to output expressions in Mathematica that look more like pen-and-paper math. In ...
0
votes
0answers
18 views

Partially activate a derivative

Is there a way to make an inactive derivative do some amount of simplification? For instance, say I have Inactive[D][{{f,g},{u,v}},x] I would like ...
3
votes
1answer
75 views

How can I let RegularExpression remove all colors from its regex-input string before processing it?

Regular expressions are a very powerful tool, but such expressions are often very cryptic. If you want to understand them, it is best to have colored pencils at hand to color-code the parts that ...
1
vote
0answers
39 views

Automatically export .nb to a package upon saving while preserving section headings

Is it possible to automatically export a .m package when I save my .nb as can be done using the option ...
1
vote
1answer
54 views

How to represent a subgraph of a directed graph as a LayeredGraph with EdgeWeights

The following code generates: The first element is a layered graph of the original system sam. The second element is a list of ...
1
vote
2answers
105 views

How to set a background color for a cell style via a command?

I want to set different background colors for various cell styles (e.g. Section, Text), so that whenever I choose a specific style for some cell in the notebook, it automatically gets colored ...
1
vote
1answer
50 views

Highlight text given String and String-Pattern

given a String: string = "the cat is on the mat" and given a String-Pattern ...
2
votes
0answers
31 views

How do I create a vertical RadioButtonBar in FormObject?

RadioButtonBar has an option Appearance->"Vertical". But I am using RadioButtonBar in a FormObject(basically to create multiple-choice questions), and ...
3
votes
1answer
140 views

Doing calculations on values input in USD currency format (e.g., $1,234.56)

I'd like to be able to copy and paste, into MMA, numbers that have a standard USD currency format, i.e., that include dollar signs and comma separators, and get the output in the same format. I'd ...
1
vote
0answers
34 views

Yet Another Expression Ordering Question (not polynomial but transcendental)

Forcing a particular ordering of terms, i.e. overriding Mathematica's, is a recurrent issue, especially for users working within particular domains where there is a particular ordering tradition or ...
4
votes
2answers
154 views

Organising and examining a complicated CSV file

I am being sent data in CSV files. The sender is providing helpful comments and lots of headings so that it is fine to look at in a spreadsheet environment. However, when I import it into Mathematica ...
0
votes
0answers
60 views

On the precision of `Table` calculation [duplicate]

I want to add two arrays length and Apice, It's accuracy to six decimal places. When I use ...
1
vote
1answer
38 views

How to use Power with NumberForm?

Being in need of calculating the following numbers with 18 decimals of precision: $2^{2^{-x}}, x\in{\mathbb{N}}$. I looked for what built-in symbols can help me and found Power and NumberForm. I tried ...
8
votes
1answer
104 views

List of all formatting elements available for .m files

I'm looking into generating .m files programmatically and would like to explore different possibilities of formatting their content when opened in the front end. For example, if you write ...
3
votes
0answers
53 views

Pasting multiline commands

If i copy and paste something from one nb to another it works normally. But if I copy from any other app it just puts everything in the same line. Recently, I have automated my workflow in ...
1
vote
0answers
23 views

Palette to align formulas in input cell

I have a palette that formats input cells for display, and also copies the number of cells in DisplayFormulaNumbered format so I can paste references to them in the ...
2
votes
1answer
115 views

What would you substitute for { and } in Mathematica code so it will display in YouTube comments?

Curly braces are not allowed in YouTube comments, so it would be good to find another character that Mathematica doesn't use and YouTube will allow so a global find and replace will put back the ...
1
vote
1answer
43 views

UnitSimplify for unit multiples and submultiples

Is there any way to automatically rewrite units so that they display more naturally looking magnitudes? By this I mean that ...
0
votes
0answers
43 views

Formatting code in .wl and .m files from the command-line?

I use an external editor (Sublime Text) to edit my .wl and .m files and run them with WolframKernel from the command line. This means everything I do is outside of Mathematica. Is there a way I can ...

1
2 3 4 5
16