Questions on the analytic and numeric equation solving functions of Mathematica (Solve, Reduce, NSolve, FindRoot, DSolve, RSolve, etc.).

learn more… | top users | synonyms (4)

12
votes
2answers
354 views

Is there a way to use functions like Prime[n] within Solve[]?

I'm trying to see if a number can be written as the sum of two prime numbers. Ideally, I would like to use Solve[ Prime[n] + Prime[m] == 100, {n, m}] But that ...
3
votes
0answers
139 views

RSolve not returning known solution

I have the following recurrence relationship for which I know the solution is given by a binomial distribution: ...
1
vote
1answer
188 views
0
votes
1answer
140 views

Industrial Level Applications. Recipe for mixed notation of equations set

I am working with large (linear) equations set within Mathematica in numerical notation. For example, set from 4056 eq. is solved for a second, no more. There is no doubt, result is great. But even ...
1
vote
1answer
342 views

Comparing two symbolic expressions

Does Mathematica provide any way to compare two symbolic expressions and find which is the greatest? For example, I want to find which is the greatest of ...
0
votes
1answer
1k views

Tricks for solving (lots of) coupled nonlinear equations numerically?

I have a system of 6 non-linear (quadratic) coupled equations with 6 complex unknowns \begin{align*} |x_1|^2 + |x_2|^2 + |x_3|^2 &= a\\ x_1 x_4^* + x_3 x_5^* &= b + c i\\ x_1 ...
0
votes
1answer
160 views

Assign the result of Solve in a list [duplicate]

Possible Duplicate: Assign the results from a Solve to variable(s) I want to assign the results of a Solve command in a list. For example Solve[-((287 s^3)/50) == 0, s] returns {{s -> 0}, ...
2
votes
1answer
269 views

How to modify a matrix to satisfy a special condition?

I have matrix like this: How do I modify this matrix to make it satisfy the following condition: For each element {i, j} in the matrix the sum of the elements of row i must be equal to the sum ...
9
votes
5answers
540 views

Create filling between two trig functions

Working with trig functions, period, amplitude, etc. I found a worksheet at a calculus website, with some nice questions related to interpreting trig functions, at least, they provide some "fun" ...
6
votes
2answers
1k views

NDSolve with vectors

I'm stumped. I'm trying to write this using vectors, but the 2nd derivative isn't being expanded like I expected it to be. This is a system of equations for a projectile with quadratic drag and ...
4
votes
2answers
237 views

Both Sin[x]==0 && Cos[x]==0 as a solution

If I do FullSimplify[Reduce[Sin[p1] == 0 && Cos[p1] == 0, Reals]] I get Cos[p1] == 0 && Sin[p1] == 0 ...
0
votes
1answer
517 views

Solving linear equation

I want to solve following linear equations: \begin{align*} 3 x - y &= 0\\ y + 2 z &= -1\\ x + y + z &= 3 \end{align*} The output will be ...
2
votes
2answers
386 views

FindRoot errors

I'm trying to solve a system of two equations in two variables for some range of parameter values. I use ContourPlot to see where I should look for a solutions and ...
0
votes
2answers
189 views

Derivative of the solutions by parameter

P0 = 0.1; K = 1000; Quiet[sol = Solve[{K*P*L == PL, P0 == P + PL, r*P0 == L + PL}, {P, L,PL}][[1]]]; complex = PL /. sol; Plot[complex, {r, 0.1, 2}] How can I ...
6
votes
2answers
559 views

Solve an equation in $\mathbb{R}^+$

How can I solve this equation (both numerically and literally) only in the positive reals $\mathbb{R}^+$? Solve[x == (v0 - (A CD t v0^2 ρ)/(4m)) Cos[θ] t, t] And ...
1
vote
0answers
530 views

Calculating the mean curvature of a surface - suggestions

I am attempting to calculate the mean curvature [1, 2] of a surface defined by a function of x and y. My function is rather ...
0
votes
1answer
187 views

x/.NSolve[f==g,x] does not work when f or g is the output of NDSolve!

I have been trying to put Points at the intersection of two curves, one of which is the ouput of a differential equation solved with NDSolve. The output being an Interpolation, NSolve cannot find the ...
3
votes
1answer
509 views

How to solve this equation with positive integers as a solutions?

This is a problem of United Kingdom Mathematical Olympiad. Find all triples $(x,y,z)$ of positive integers such that $$\biggl(1+\dfrac{1}{x}\biggr)\cdot \biggl(1+\dfrac{1}{y}\biggr)\cdot ...
11
votes
2answers
814 views

NSolve gives additional solutions that don't satisfy the equations!

I am trying to solve the following polynomial equations in Mathematica: ...
1
vote
1answer
219 views

How to find 4 unknowns?

There are 4 unknowns constants: a,b,c,p. The variable is ...
0
votes
0answers
153 views

Reducing a statement with Mathematica, step by step [duplicate]

Possible Duplicate: Get a “step by step” evaluation in Mathematica I have a list of inequalities combined with quantifiers. And Mathematica is able to reduce to simple statement with the ...
6
votes
3answers
390 views

Plotting $\omega(k_x, k_z)$ in $(\omega, k)$ plane with assumption of $k^2 = k_x^2 + k_z^2$

I'm currently studying atmospheric-gravity waves and their dispersion relations. For analysis I need to plot the dispersion function: \begin{equation} \omega^4 - \omega^2\cdot C_s^2(k_x^2 + ...
8
votes
2answers
2k views

How do I work with Root objects?

I want to solve the trigonometric equation : $$(3-\cos 4x )\cdot (\sin x - \cos x ) = 2.$$ I tried Solve[(3 - Cos[4*x])*(Sin[x] - Cos[x]) == 2, x] It returns the ...
2
votes
1answer
362 views

How to solve this exponential inequality?

I want to solve the exponential inequality $$8^x +18^x -2\cdot 27^x>0.$$ I tried Solve[8^x + 18^x - 2*27^x > 0, x] and ...
1
vote
0answers
93 views

Symbolic FindInstance

I'm wondering if there is any way of doing something like the following: FindInstance[x < y, {x}, Reals] and getting, as a possible return value, ...
2
votes
2answers
945 views

Why doesn't Mathematica solve $x=\cos\,x$ properly? [duplicate]

Why doesn't Mathematica solve x == Cos[x] properly? Both Solve and NSolve fail with the ...
5
votes
4answers
1k views

How to solve this logarithmic equation?

The equation $$x^2\cdot\log_2\dfrac{3+x}{10}-x^2\cdot\log_{\frac{1}{2}}(2 + 3x)=x^2 - 4+2\cdot\log_{\sqrt{2}}\dfrac{3x^2+11x+6}{10}$$ has two solutions for x, namely 1 and 2. I tried ...
1
vote
1answer
106 views

How to find the values of $m$ so $A \cap B = \emptyset$ and $A \cup B = (-3,+\infty)$?

I have two intervals $A = (-3, m^2- 2]$ and $B=[m, +\infty)$. How to find the values of $m$ so that $A \cap B = \emptyset$ and $A \cup B = (-3,+\infty)$? I tried ...
3
votes
0answers
873 views

Solving a system of nonlinear equations self-consistently

I am trying to solve a set of three non-linear equations in Mathematica. I need help with them. The Mathematica code (in plain text format) is attached below. If you copy & paste the code below ...
1
vote
1answer
416 views

Using 'Reduce' to solve a set of inequalities, specified by a list

I have a two lists $LHS$ and $RHS$, both of size $n$. I want to solve a system of inequalities of the form: $$LHS[1] \leq RHS[1]$$ $$LHS[2] \leq RHS[2]$$ $$LHS[3] \leq RHS[3]$$ $$\vdots$$ ...
2
votes
1answer
318 views

Vector Analysis: Why are the Grad, Laplacian and Div being evaluated to zero

For the non linear partial differential equation below, why are the Gradient, Laplacian and Divergence being evaluated to zero despite using the VectorAnalysis ...
3
votes
1answer
1k views

Finding the Minimum value of an interpolating function

I can't seem to use FindMinValue to find the min. value of a curve represented by an interpolating function. For instance the below code generates an interpolating ...
1
vote
1answer
375 views

2 non-linear equations with 2 unknowns which I cannot solve

I have the following equations and I would like to solve them in Mathematica anyway. Numerical results are very much welcomed. However, when I use the command ...
2
votes
1answer
563 views

'not a valid variable' error when trying to solve 13 equations with 13 variables

I want to solve 13 variables by 13 equations. And here is my program: ...
2
votes
1answer
533 views

Linear Solve with Modular Arithmetic

I am interested in using LinearSolve[m,b] which will find a solution to the equation $m.x=b$, where I am in mod 2 arithmetic. Is there any way to perform this ...
-1
votes
1answer
685 views

Help to solve Simultaneous Equations

I think this should be easy to numerically solve in Mathematica, but for some reason I'm not finding the correct way to do it. I basically want to solve these simyltaneous equiations: ...
0
votes
1answer
234 views

FindRoot on a 2D list of Equations

I have a $n \times k$ Matrix of data that I want to feed into an equation and solve for an unknown variable. I suppose I can always just convert the Matrix into a long Array but I'd like to learn how ...
2
votes
1answer
323 views

Defining regions for `Exclusions`

I have the following function I want to plot in 3D (For simplicities sake we can say $a=5,b=-1,c=3$.) ...
10
votes
1answer
799 views

How do I find all the solutions of three simultaneous equations within a given box?

Sometimes, one needs to find all the solutions of three simultaneous nonlinear equations in three unknowns $$\begin{align*}f(x,y,z)&=0\\g(x,y,z)&=0\\h(x,y,z)&=0\end{align*}$$ within a ...
3
votes
1answer
190 views

Tracking FindRoot errors in NestWhileList and Table

I'm solving many systems of two equations by varying the initial parameters. I'm running FindRoot in a NestWhileList where the ...
2
votes
1answer
380 views

How to solve simultaneous equations faster with Compile?

I have large 6x6 matrix Uwhich is a multiplication of 15 rotational matrix. All of the elements are Sin\[theta] and ...
1
vote
3answers
349 views

equation solving problems

I have some equation: $$ veq=-2-lr-l^2r+2(r+ir^3\omega) v' + (-2+r)r^2v'^2 + (-2+r) r^2 v''==0 $$ or in Mathematica form: ...
6
votes
2answers
373 views

Reduce and Solve unable to solve equation

I have the following equation. Why aren't Solve and Reduce able to find the solution? ...
1
vote
2answers
335 views

Replacing variable in an equation with an Interpolating function polynomial and plotting residual

I was trying to plot the residual for the solution of my PDE. However, I was unsure about a couple of things. I imported the data and created an Interpolation polynomial with ...
3
votes
2answers
428 views

Is there a way to solve the Apollonius Circle problem in Mathematica?

Assuming x, a, and b are complex numbers, is there a way to reduce the equation Abs[x - a] == k Abs[x - b] to something like ...
5
votes
2answers
1k views

Solving a trig equation

I am trying to find an explicit solution to a trigonometric equation. It is running for a long time and I didn't get any result, but Maple solves it quickly. Why ? ...
3
votes
1answer
523 views

Solving Simultaneous Equations

I am trying to solve two equations that take the form: $W_0 \sqrt{1+\left(\dfrac{z}{\lambda\,\pi\, W_{0}^2}\right)}=W_1\;\,\quad \ldots(1)$ $W_0\sqrt{1+\left( \dfrac{z+0.1}{\lambda\, \pi\, ...
2
votes
1answer
267 views

How to solve a symbolic equation with symbols in powers

I am trying to solve $\dfrac{\rho\ ((1-b)\ \lambda _f\ \lambda _s\ P _A)^{\rho }}{b-1}+\dfrac{\rho \left(\dfrac{b\ \text{ps}\ x}{1-\text{ps}}\right)^{\rho }}{b}=0$ in terms of $b$, I ...
0
votes
1answer
190 views

How to solve this equation? [closed]

The numbers real x and y, are solutions of the following equation system : $$ \{x^3 + 3x^2y + 3xy^2 + y^3 2\sqrt2$$ $$ \{x^3 - 3x^2 + 3xy^2 -2y^3=0 $$ . $$ x^2 + y^2$$ How to solve it ?