Questions on changing Mathematica expressions of one type or format to another, for example date formats, Boxes and other typesetting representations, or different units of measurements.

learn more… | top users | synonyms

24
votes
2answers
1k views

How do I extract the contents of a selected cell as plain text?

My aim is to extract the contents of an Input cells as plain text. Ideally I would like to be able to select one or more Input cells and press a button which would then extract the text from these ...
15
votes
3answers
751 views

How to convert between various ItemSize/ImageSize units?

How can one convert between the implicit units used by Grid (ems and line height for horizontal and vertical dimensions) and printers points (in ...
7
votes
1answer
409 views

How to write aligned equations and export them HTML/TeX

This question is mainly about exporting to HTML/TeX. For those of you who do not know how to write aligned equations in Mathematica please see this answer. Lets assume that you modified your ...
6
votes
2answers
2k views

How to convert a string of number into real numbers without precision loss

I searched and did not find similar answers which can resolve the 'no precision loss' issue. A sample string is: ...
8
votes
3answers
235 views

Incompatibility of Row and TeXForm

Bug introduced in 9.0 and persisting through 10.1.0 or later Update: Since no one has been able to give a reason for this change in behavior or provide a solution I am tagging this as a bug. ...
8
votes
3answers
239 views

Graphics in Notebook Different from Graphics Expression?

Consider the expression TreeForm[a+b^2+c^3+d] which displays as This is a nice Graphics object, as I can prove by typing ...
12
votes
1answer
775 views

Exporting numbered equations to HTML/TeX using conversion rules

This question is a follow up from this one. It may also be considered a duplicate since I have already asked this question in stackoverflow almost a year ago. For a background on using numbered ...
12
votes
2answers
683 views

Exporting notebook to HTML, using conversion rules

The idea is to export the whole notebook to HTML with all the math equations in latex form. In this way we can add the mathjax script and it will take care of the math. Suppose we have the following ...
7
votes
1answer
119 views

ToExpression and ToBoxes aren't inverses of each other?

Applying ToExpression and ToBoxes repeatedly to Hold[1/1] gives many ...
5
votes
1answer
75 views

How to convert arbitrary raw boxes directly into String?

This question is motivated by the recent question about searching inside of the NB files. According to the Documentation, ToString expects a high-level WL ...
7
votes
2answers
263 views

Programatically adding/retaining comments within a nested list

Is it possible to convert the following list of strings to computable numbers with the comments preserved? ...
7
votes
2answers
399 views

Revert FullForm-ed text to prettyprinted

Sometimes strings in a notebook/package file end up garbled due to some unknown/unintentional conversion of the expression/cell/notebook. I could not find a way to revert such unreadable text to its ...
5
votes
1answer
2k views

Combine multiple PDF files into one document

I have multiple single page PDFs I'd like to join together into a single file. (Obviously I mean the file format and not the probability distributions here!) I'm aware of free online services such as ...
1
vote
2answers
83 views

Command to change binary mlf terms into Subscripted mlf terms?

I express multilinear functions in the following format. Is there any ready command to convert them to multilinear functions easily? Input ...
21
votes
8answers
4k views

How to express an integer number in English words?

How do I convert a number to a readable string? I would like to implement a function, inWords[], inWords[n_]:= ? which ...
7
votes
6answers
3k views

Convert a string into a list of numbers

I got the following problem I don't know how to solve or if it's at all possible to solve(I'm quite new to Mathematica and don't have an IT background, so please explain slowly if possible:)) I'm ...
7
votes
1answer
826 views

Creating and editing new stylesheets

I'm trying to create a stylesheet, but the process has become painful. I'm sure that this has to do something with resetting something in Mathematica everytime I make changes to the stylesheet. To ...
9
votes
2answers
292 views

Working with Java hashmaps from Mathematica

I'm using J/Link to access data from an external Java program. The data are represented as a ConcurrentHashMap (see the official specification here). ...
3
votes
1answer
51 views

An issue regarding the use of CopyToClipboard with dynamic content

Please, consider the following code: ...
1
vote
2answers
63 views

How to get monomials multiplied by each other?

Suppose Subscript[x, #] & /@ {1, 3, 7} that returns {x_1,x_3,x_7}. Now how can I get ...
5
votes
3answers
276 views

Converting between AbsoluteTime and Unix time

By trial and error, I've found that the following gives the current Unix time: AbsoluteTime[] - UPOCH where UPOCH can be defined in any of the following ways: ...
4
votes
1answer
62 views

convert MeijerG to form Standard Functions in Mathematica

I'd like to convert MeijerG[{{}, {1., 1.}}, {{0., 0., 4.}, {}}, -1. T λ] to its Standard Functions (For example Bessel function or ...). Any suggestion?
0
votes
0answers
42 views

Possible bug of Exporting as HTMLFragment at Linux

This is the result of Mathematica 10.0.2 of Linux Version. There are two style inside one tag, and this fragment cannot be Imported as XML by Mathematica. This is the result of Mathematica 10.1 of ...