Questions tagged [symbolic]

For questions about symbolic computation, as opposed to numerical computations.

Filter by
Sorted by
Tagged with
10
votes
2answers
1k views

Non-commutative algebra (NCAlgebra): How to properly SetCommutingOperators

I am starting to work with non-commutative algebra in Mathematica and had a look at the NCAlgebra package. I installed it and can use its functions. However, what I am struggling with is the ...
10
votes
3answers
526 views

How to implement symbolic Ramanujan's summation in Mathematica?

How to implement Ramanujan's summation in symbolic form in Mathematica? For instance, I want as input the function $f(x)=x$, as output $-1/12$, as input $f(x)=1/x$, as output $\gamma$ (Euler's ...
10
votes
1answer
410 views

Mathematica: computing a difficult integral

I am trying to compute the following integral: Integrate[Exp[Sum[-((cw λ - b[i])^2/(2 σ^2)), {i, 1, n}]], {cw, 0, 1}] And currently Mathematica outputs ...
10
votes
1answer
699 views

Is it possible to find a limit of a sequence given by its recurrence relation?

I need to calculate a limit of a sequence given by its recurrence relation. I tried the following: ...
10
votes
1answer
168 views

How do I expand StirlingS2[n, 10] in terms of elementary functions?

I know that it is possible to expand StirlingS2[n, 10] in terms of elementary functions of n. I tried ...
10
votes
2answers
632 views

Symbolic Integration along contour: branch cut problem?

Context Following this question on path integrals in the complex plane, having defined again a numerical and symbolic integrator along a path as ...
10
votes
2answers
603 views

Symbolic tensor simplifications and the identity matrix

How can I get Mathematica to simplify the following expressions, with $Assumptions including Element[n,Integers], n > 0, and <...
10
votes
1answer
220 views

1 is not the SameQ as Null, but why might 1 be Equal to Null?

The command SameQ[1, Null] returns False which is what I would expect, but the command ...
10
votes
1answer
157 views

Bug in GeneratingFunction?

Bug introduced in 7.0 and fixed in 9.0.0 According to the documentation GeneratingFunction[a[n],n,x]==Sum[a[n]x^n,{n,0,Infinity}] However, for $a_n=1/(n+2)$ I ...
10
votes
2answers
288 views

Integration of Booles and Gaussians in high dimensions

Context As a follow up of this question, I would like to predict the connectivity of the so-called cosmic web in arbitrary dimensions. The connectivity $\kappa$ is defined as the number of ridges ...
10
votes
1answer
378 views

Wrong limit: Limit[(1 + (-1)^n/n)^n, n -> Infinity]=1 (Mathematica 10.4 and W-Alpha)

Bug introduced in year 2002 (?) and fixed in 11.0 Since $(1-\frac{1}{n})^n\to 1/e$ and $(1+1/n)^n\to e$, the sequence $(1+\frac{(-1)^n}{n})^n$ has no limit as $n\to\infty$, but has limits for odds ...
10
votes
1answer
1k views

Compute inverse Laplace transform with Integrate

Since inverse Laplace transform is just an integral, while we already have InverseLaplaceTransform built in, can we compute it with ...
10
votes
1answer
2k views

Symbolic scalar-by-matrix derivative

Let's say I want to calculate the following scalar-by-matrix derivative $$\frac{\partial}{\partial A} \text{tr} \left[(\vec X^T A)^T (\vec X^T A)\right],$$ with $\vec X$ and $A$ being a $n \times 1$ ...
10
votes
1answer
196 views

How to predict the degree of the first series coefficient?

Given an expression f that is a function of x and a number x0, what is the least integer <...
10
votes
0answers
292 views

Possible Symbolic Integration Bug

Bug introduced between 5 and 8 and persisting through 12.0. I think I may have found a bug, and want to verify is this reproducible in other versions and platforms and not a mistake of mine. I ...
10
votes
0answers
325 views

Improving the performance of a package for working with rational functions

As Mathematica gets slow for large symbolic calculations, the cost of putting terms over a common denominator (Together), in particular, gets too high. It occurred ...
9
votes
2answers
670 views

How to simplify an expression with special functions to zero

The following is a well-known Bessel function identity: $$J_{-n}(z)=(-1)^n J_n(z),\qquad n\in\mathbb Z$$ To check this, I used the following code and the result is as what I expected. ...
9
votes
2answers
749 views

How to solve this system of trigonometric trancendental equations over the reals?

Namely, $$\left\{x^2+2 x \sin (y)+3 \cos (y)=0,\sin ^{-1}\left(\frac{x}{2}+\sin (y)\right)=y-\frac{\pi }{3}\right\}$$ My simple-minded trial ...
9
votes
5answers
5k views

How do I obtain the correct double limit?

The command Limit[(Sin[x^2] + Sin[y^2])/ (x - y) /. x -> 0, y -> 0] (* 0 *) I think that Mathematica finds the iterated limit instead of the double ...
9
votes
3answers
304 views

Use both values of $\pm$ in equations

Is there an elegant way to use $\pm$ in equations, without having to make a text change and substitution using an Or function? For instance, I would like this ...
9
votes
1answer
407 views

Deep learning outperforms in symbolic integration and ODE?

There comes a new paper on arXiv (arXiv 1912.01412, Deep Learning for Symbolic Mathematics by Guillaume Lample, François Charton) claiming that a deep learning model outperforms Mathematica a lot in ...
9
votes
1answer
1k views

Symbolic linear algebra

I would like to know how I can ask Mathematica to expand (and simplify) such an expression : $$ (\alpha A + \beta B)^\top (\alpha A + \beta B) $$ where $\alpha,\beta$ are two real numbers and $A,B$ ...
9
votes
1answer
451 views

${\frac {\partial^{2} u}{\partial {x}^{2}}} +{\frac {\partial ^{2} u}{\partial {y}^{2}}} =0$ with one boundary at infinity

Is there a trick to make Mathematica solve $${\frac {\partial^{2} u}{\partial {x}^{2}}} +{\frac {\partial ^{2} u}{\partial {y}^{2}}} =0$$ with one boundary condition at $\infty$? Boundary ...
9
votes
2answers
171 views

Closed form of product of Gamma function

Mathematica recognizes this closed form \begin{align} \prod_{k=1}^{n-1}\sin(\pi k/n) &= 2^{1-n}\,n \end{align} just fine: but fails on this one despite that this expression also has a known ...
9
votes
2answers
134 views

How to stop DSolve from solving equations [duplicate]

I'm tring to solve this ODE, DSolve[y'[x] == Sqrt[1 + (x/y[x])^2] - x/y[x], y[x], {x}]. Mathematica gives this as the result: I don't want Mathematica to solve the ...
9
votes
2answers
651 views

InverseFourierTransform of simple function takes forever

i'm quite new to Mathematica. I'm trying to do something along the lines of: ...
9
votes
2answers
495 views

Analytic solution to Orr-Sommerfeld-Squire equations for a special case

Hello everybody in Mathematica SE. Although my question is related to flow stability analysis, this should be a general application of MMA to solve a system of ODEs. Thank you for your suggestion! ...
9
votes
1answer
234 views

When to use GenerateConditions -> True

Many functions, usuallly those involving integration, take a GenerateConditions option which often defaults to False, or at ...
9
votes
2answers
209 views

How can I make FourierCoefficient et al. handle the zero-order term correctly?

Say that I would like to use Mathematica to step through one of the most famous solutions to the Basel Problem, using Parseval's Identity, $$ \sum_{n = -\infty}^\infty \left|c_n\right|^2 = \frac{1}{2\...
9
votes
1answer
764 views

Define an operator with the distributive property

I would like to define the operator with distributive, associative, and commutative properties - so that Mathematica can symbolically simplify expressions I use ...
9
votes
2answers
903 views

How to symbolically differentiate an infinite series without evaluating the series itself

I'm dealing with finite sums of infinite series. Each of the infinite series possesses a different starting index, i.e. each of the series begins at n = 0, n = 1, or n = 2. As a result, it's important ...
9
votes
1answer
615 views

Mathematica 9 can't integrate this function but earlier versions could

Integrate[ ArcTan[x]/(1 + x) Log[(1 + x^2)/2], {x, -1, 1}] I used Mathematica 9.0.1 on Windows7 32bit, Mathematica 9 cannot compute this, but Mathematica 8 gives ...
9
votes
2answers
2k views

Coordinate free differential forms package

I am looking for a package in Mathematica which can handle differential forms in a coordinate free manner. I am aware of several packages which do differential forms, but it seems that for all of them ...
9
votes
2answers
391 views

Symbolically prove that two expressions are identical

I encountered this problem when trying to reproduce the result of this paper. (The relevant parts are all included in the preview i.e. the 1st page of the article. This link is just given as ...
9
votes
2answers
403 views

Why is ToRadicals[] not able to handle all cases? Is there a workaround?

The documentation for the function ToRadicals says: ♦ There are some cases in which expressions involving radicals can in principle be given, but ...
9
votes
1answer
477 views

Verifying and deriving basic (block) matrix identities

How can I use the new symbolic matrix/tensor capabilities to verify matrix identities, such as (1) or (2) Even better, how can I ask Mathematica to derive expressions for X, Y, Z, and U like ...
9
votes
1answer
242 views

Comparing exact expressions for equality — is it really OK if I get wrong answer?

Bug introduced in 7.0 or earlier and fixed in 10.2.0 I found an unexpected behavior (that I think of as a bug) in evaluation of the equality operator applied to mathematical functions with exact ...
9
votes
2answers
1k views

Bug in Integrate for Mathematica

Bug introduced in 8.0.0 and fixed in 9.0.0 Consider the following: ...
9
votes
0answers
132 views

Symbolically evaluating gradients/Hessians

I'm taking a machine learning course, which involves taking a lot of analytical gradients and Hessians. It would be ideal if I could perform these calculations in Mathematica. However, I am only aware ...
9
votes
0answers
140 views

When and why are Assuming and Assumptions not equivalent? [duplicate]

In this question there's an example of an integral where using Assuming and Assumptions give different results: ...
8
votes
3answers
731 views

Efficient code for solve this equation

We have $a*b*c=-1$, $\frac{a^2}{c}+\frac{b}{c^2}=1$, $a^2 b+a c^2+b^2 c=t$ What's the value of $a^5 c+a b^5+b c^5$? I tried ...
8
votes
2answers
435 views

Can I get rid of the noise in my differential equation solution?

I am solving a differential equation: ...
8
votes
3answers
425 views

Series expansion wrong

I had to work with some series expansions lately, and at some point I realised that something was becoming inconsistent at some point. It seems that applying Factor ...
8
votes
3answers
5k views

How to solve an overdetermined system in Mathematica

I would like to understand the reasons and find a way to avoid such behaviour of the Solve function in Mathematica 8. ...
8
votes
2answers
274 views

How to represent $f(x) = (y-x)^k \log(y-x)$ as a summation of the form $f(x) = \sum\limits_{j=0}^\infty \cdots$?

I am having a lot of trouble working with summations in Mathematica, and this is unfortunate as it is my main use case for the application My latest summation issue is the following. I am trying to ...
8
votes
2answers
256 views

Calculating sum of BesselJ[n, x]

My friend has a sum in his research paper that looks like this $$ \sum_{n=-\infty}^{\infty}\frac{J_n^2(x)}{n-\kappa}. $$ He was able to calculate this sum analytically, by substituting the ...
8
votes
3answers
682 views

Is this solution to nonlinear first order ODE correct?

Mathematica 11.3. I am not sure if this solution given by Mathematica is correct. But I'd like to ask the experts. ...
8
votes
2answers
190 views

Issue with Upvalues

I want to introduce two variables (I call them EXt and EXtC, where "C" stands for complex conjugate) which would mimic the behavior of a phase of a complex number. For that, I use the following tags: ...
8
votes
2answers
477 views

Lookup in Inverse Symbolic Calculator+ from Mathematica

There is a useful feature in WolframAlpha that allows to find a possible closed form for approximate numeric values. It can be used, for example, to guess the value of an integral that Mathematica ...
8
votes
3answers
4k views

Algorithm for parts integration

Sorry if this is a duplicate, I've searched how to do this to no avail. What I'd like to do is a function that integrates by parts $n$ times, i.e $$ \int u(x) v(x) dx = u \left(\textstyle{\int}v\...

1 2
3
4 5
23