Tagged Questions

How to manipulate expressions structurally, not necessarily complying with the rules of algebra.

62 views

Sequence of arbitrarily many variables separated by commas? [closed]

I am wondering if it is possible to produce an input such as x[1],x[2],x[3],...,x[n] for an arbitrary but fixed amount of n ...
206 views

Is there a way to use array of data as a function variable?

I have a data that looks something like. {{1,1},{12,1},{7,9},{10,14}, ...... } I want to see if there is an easy way to apply this array of data into a ...
141 views

How I can count multiplications in an experssion?

Next task to complete: Count *-symbol in such expression as a + s^2*b - c/y + o^3 + n*m*u (in this case count of ...
50 views

...
86 views

What options need to be set for Simplify to perform a certain manipulations similar to FullSimplify?

Simplify performs algebraic transformations and is fast, while FullSimplify tries a wide range of transformations involving ...
46 views

How can I manipulate a long expression to order it by factors/derivatives of a particular function?

I have a Mathematica notebook that generates a linear expression involving derivatives of a given variable. Expanded (and simplified for our purposes), it looks something like this: ...
50 views

2D plot using Manipulate command [closed]

Can anyone tell me what the problem is with the following code: y[x_ a_] := Sin[x (1 + a x)] Manipulate[Plot[y[x a], {x, 0, 6}], {a, 0, 2}] However, the ...
166 views

Is there a way to control which special forms Normal converts?

Normal documentation reads: Normal[expr] converts expr to a normal expression, from a variety of special forms. But is there a way to control which special ...
50 views

Analogue of Maple's identify command in Mathematica [duplicate]

In Maple there is a useful command identify that tries to find a closed form expression based on its numeric approximation. As far as I know there is no built-in ...
81 views

Extracting subtree for a TreeForm

How can I extract an entire subtree from a TreeForm starting from a specific point of the tree? Because with Extract or Part you can take only that specific point...
56 views

How to force evaluation of an expression with Part left unnevaluated?

My goal is to minimize a real valued multi-variable function averageFreeEnergyDensity. The function accepts an integer argument ...
93 views

Loop in a loop, or how to evaluate complex expressions

I need to find $h_{0j}$ for every $1\leq j\leq300$, where \begin{multline*} h_{0j} = \sum_{q=1}^{Q}g_qe^{-\lambda_q j\Delta}\frac{e^{\lambda_q\Delta}-1}{\lambda_q} + \sum_{p=1}^{P}\frac{e^{-\alpha_p ...
269 views

Print all numbers from a sequence which don't contain the digit 7

so i have this: Cases[RecurrenceTable[{a[n + 1] == 7 a[n] + n, a[1] == 1}, a, {n, 7}], Except[7]] But i noticed that it will only exclude numbers that are 7, and ...
183 views

Get constant term with Coefficient for a non-polynomial

Take a nonlinear equation such as exp = (x + 3)/4 + Exp[x] + 1 + (c + x) Note that this is not a polynomial. Now, I want to extract the coefficients of this. ...
96 views

Work around bugs in Summation, Hypergeometric function?

I'm so confused I don't even know how to phrase the question, so here's what's happening: I need an analytic form for this: ...
87 views

Factoring out parts of an expression

I'm looking to factor out the parts of a multiplication type of expression. For example for the expression: $$20 e^{-t^2}\frac{t^2}{\sqrt{t^2+a}} erf(b+t)$$ I'd like to get a list in the form of: ...
55 views

Subsituting expressions for expressions

I'm trying to define functions using other functions, like so: f[a_, b_] := a/b; a[c_] := c; b[d_] := d; Now what I want to be able to do is two things: ...
206 views

How to manage list of list of rules?

Considering we have a list: str = "{1 -> {a -> aa, b -> bb}, 2 -> {2a -> \"{b -> bb}\"}}" Bringing this to expression gives: ...
122 views

How to convert string to integer list?

Saying we have a string: "1 2 3 4 5 6" I want to convert this to integer list. First I do: ...
73 views

How to list variables given equation? [closed]

Given an expression, is there any means to list variables? Example: a^3 + b^2 + c -> a,b,c I need this functionality because I am manipulating large expressions of many variables (20) and would ...
29 views

50 views

How can I drop the “belongs to integers” part from Reduce output?

I have this Mathematica line: Reduce[1/(E^0)^x + 1/(E^1)^x + 1/(E^3)^x == 0, x] that gives the output: ...
62 views

How do I extract the value of a 'Style'?

I have a Style displaying an underlying Real value. For example I might have ...
287 views

How to do algebra on summations of variable expressions?

Is there any easy, general way to handle algebra on variable Sums? For examples, Gaussian Mixtures or Fourier Series: ...
84 views

TrigExpand Idiosyncracies

TrigExpand[Sin[x]^2 Log[y]] returns sin^2(x) log(y), as one would expect. However, ...
108 views

Collect powers of variables and integers separately?

Let expr contain a sum of powers of x with some coefficients ci. The exponents of ...
262 views

Derivatives of functions with arbitrary number of variables?

I am trying to define a function f[x1,x2,...,xn] with n integer but not specified. And then I would like this funktion to behave ...
46 views

Conditional replacement of all occurrences of a variable?

I know there is functionality in Mathematica to perform replacements like: x[a] d[a,b]/.y_[z_] d[z_,p_]->y[p] Which naturally gives ...
181 views

Expression manipulation: Explode sums and products? [duplicate]

I wonder if the functionality exists to explode a sum, or product? What I mean by that is the following. Imagine, you have input data data = a + b c - d e f ; Is ...
270 views

How can I get Solve to combine Sin/Cos into Tan?

I want to solve an equation in x, containing Sin[x], Cos[x] and a positive real constant ...