Questions tagged [equation-solving]
763 questions
0
votes
2 answers
SympifyError: SympifyError: index when using a loop
I am having trouble using simpify when changing the parameters in a loop. Before adding the loop it worked just fine so I am a bit confused about what is going wrong. The idea is to calculate the fixed points for the above equations when having a…

Johanna
- 11
- 2
0
votes
1 answer
Solve non linear equations with scipy NonlinearConstraint over pandas dataframe
I'm trying to solve the system of equations:
where a,b and c are columns from pandas dataframe. I used to work with Excel, where I run a macro
with go seak in one column (residuals) by changing the values of the other columns (functions), but I…

JCV
- 447
- 1
- 5
- 15
0
votes
1 answer
Solving for all valid inputs with an ATS
Let's say you have a system of pure expressions, like,
(bi0, bi1, bi2, ai0, ai1, ai2) := inputs
b0 := bi0 && bi1
a1 := b0 ? ai0 : cbrt(ai0)
a2 := bi2 ? a1 : ai1
output := a2 > ai2
# prove:
output == True
Can an automated theorem prover be…

alexchandel
- 532
- 6
- 15
0
votes
0 answers
why when I evaluate my function in nleqslv(fun)$x the results aren't near 0?
I want to determine the value of z = z1, ..., zn such that
z1 = g1(z1,..,zn)
...
zn = gn(z1,..,zn)
for some nonlinear gi(z1,..,zn), 1<=i<=n. And I declared the function:
vecfun <- function(z){
fun1 <- z1 - g1(z1,..,zn)
...
funn <- zn -…

leplata
- 123
- 5
0
votes
0 answers
How to find strictly positive solutions of a nonlinear system of equations in R?
I have a system of equations with L+2 variables that looks something like:
zL = f(z0, ..., z(L-1)), z0 = g(zL), zl = h_l(z(l-1)) for 0

leplata
- 123
- 5
0
votes
1 answer
Solve system of equations using scipy.optimize.root with text input: how to assign equations and variables?
As part of a program, I am struggling to implement a function to solve a system of equations.
First, I receive a set of equations from text input. Please note that the number of equations and thus variables are unknown, as well as the name of…
0
votes
2 answers
I am trying to solve an equation with multiple variables for b
I am trying to solve a simple equation, but this is what is being outputted:
the equation is y = m*x + b,
y, m, and b are already defined
I would like to print b.
import sympy
while True:
x1 = int(input('x1: '))
y1 = int(input('y1: '))
…

Ilan1009
- 7
- 1
- 6
0
votes
2 answers
How can I solve a diophantine equation x^2-2w^2+2y^2-z^2-constant using SymPy
I have a triplet, for example (1806336, 1849600, 93636) and I need to solve the diophantine equation:
x^2-2w^2+2y^2-z^2-constant=0
Here the constant is 1806336 + 1849600 - 93636.
What I tried is:
from sympy.solvers.diophantine.diophantine import…

Eldar Sultanow
- 205
- 2
- 9
0
votes
1 answer
Using an AWK script in a windows program
I've been struggling for days with an AWK script that solves this Equation
I can't seem to run AWK with any program I download for windows, so I was wondering how I can run AWK in a windows program like Visual Studio Code or if I can translate the…
0
votes
2 answers
Trigonometric simultaneous equation
I can't solve this trigonometric simultaneous equation.
(1) cos(C)=-sin(B)*sin(D)*cos(E)+sin(D)*sin(E)*cos(B)
(2)
-sin(A)*sin(B)*sin(D)*sin(E)-sin(A)*sin(D)*cos(B)*cos(E)-cos(A)*cos(D)=0
I'd like to get sin(D), sin(E) only using the angle A, B, C…

Y K
- 1
- 1
0
votes
1 answer
Using sympy to solve equation
I am very new to coding and must solve this particular equation with python for a project. (It's not for credit. It's just for my understanding.)
please note: I know how to solve the equation by hand and I don't need to learn the solution. I need to…

Meimei Leigh
- 17
- 4
0
votes
0 answers
Root-finding algorithm for polynomials
I am currently writing a program in TI-BASIC to compute the eigenvalues and associated eigenvectors of a given matrix (I am working with a TI83 Premium CE that doesn't offer such a program). I have found and written an algorithm to compute the…

Elyo
- 205
- 2
- 8
0
votes
1 answer
Unable to write the equation correctly as it keeps giving me the answer 0 which has to be around 0.4879602393
enter image description here
so I am new to C# and I have to write this equation but whatever I do, or however I try to break it down, I tried to just use different double names for some parts of the equation like (1 / 4) is S1 and then the rest as…

Kamel Avad
- 46
- 7
0
votes
1 answer
How to solve easy matrix equations thanks to sympy in python?
Can you tell me why
import sympy as sym
import numpy as np
a=np.eye(3)*3
eq = sym.Eq(a*y,0)
sym.solve(eq, y)
Eror code is:
---------------------------------------------------------------------------
SympifyError …

Marek Umiński
- 1
- 1
0
votes
0 answers
Solve two equations with two unknowns having complex conjugate
Unknows are two, which are complex number X and complex number Y.
Constants are sixteen, which are complex numbers A_1, A_2, B_1, B_2, C_1, C_2, D_1, D_2, E_1, E_2, F_1, F_2, G_1, G_2, H_1 and H_2.
Equation (1): XA_1+ YB_1+ XYC_1+ conj(X)D_1 +…

Hansel Dsilva
- 1
- 2