The tag has no wiki summary.

learn more… | top users | synonyms

4
votes
3answers
202 views

Counting number of inversions

Is there an inbuilt method to find the number of inversions in a set of numbers? I found Inversions in Combinatorica but when I ...
2
votes
2answers
147 views

Permuting elements within a list

I have s = {2, 3, 5, 7, 1, 4, 6} (* always with diffente elements in {1,2....7}*) l = Length[s] n = 3 and n tells us that we ...
0
votes
1answer
102 views

Multivariate series expansions to different powers

I have a function that (I believe) correctly takes the multivariate Taylor series expansion about the origin for some expression (first argument), in some variables (second argument, list), to ...
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 ...
0
votes
1answer
74 views

Sorting lists of lists with string elements [closed]

I have a list of sublists. One element of each sublist is a string element. For example: list = {{1, "banana", 3}, {3, "orange", 1}, {2, "apple", 2}}; When I ...
2
votes
3answers
288 views

How can I reorder the factors in the terms of a polynomial?

How can I reorder the factors in the terms of a polynomial? Consider ...
9
votes
3answers
476 views

How do I get a two-term polynomial with a leading negative sign to display in the correct (i.e. textbook) order?

The first three expressions evaluate as expected and the polynomial is displayed in what I would call "textbook" form. The last expression, however, switches the order of terms. Mathematica employs ...
13
votes
3answers
594 views

How to keep Collect[] result in order?

For example, Collect[(1 + x + Cos[s] x^2)^3, x] gives the result ...
18
votes
5answers
726 views

How do I reassign canonical ordering of symbols?

I have a big polynomial that evaluates to: $$A^2 e^2 \phi ^- \phi ^++A e \phi ^- \phi ^+ c_{2 w} g_Z+\frac{1}{2} A e g h W^- \phi ^+ +\ll13\gg,$$ which is supposed to represent some terms in the ...