equation

Float division issue in Python (tkinter)

Float division issue in Python (tkinter) Question: I’m working on a program which uses inputs from a tkinter interface to calculate the relative funniness of a joke based on sciencewritenow.com’s formula: H ≥ ((((T1 + T2) / (T3 – R)) × I ) / D = ((T3 / T4) × S)) × B While I …

Total answers: 1

To get trend-line's equation (polynomial, order 2)

To get trend-line's equation (polynomial, order 2) Question: A simple dataframe that I want to plot it with its trend-line (polynomial, order 2). However I got the equation obviously wrong: y = 1.4x**2 + 6.6x + 0.9 It shall be: y = 0.22×2 – 1.45x + 11.867 # the "2" after x is square How …

Total answers: 1

Automatic reduction and cancellation of units with SymPy

Automatic reduction and cancellation of units with SymPy Question: I am having issues with getting units to cleanly simplify. The program I am writing is involved with the calculation of spring properties, requiring 10/11 user controlled variables and about a dozen equations, all of which deal with mixed sets of units. The one missing variable …

Total answers: 1

How to Plot Implicit Equation in Python

How to Plot Implicit Equation in Python Question: I want to Plot V(y axis) vs t(x axis) graph using the below equation at 5 different values of L(shown below) L= [5,10,15,20,25] b=0.0032 Equation, (b*V*0.277*t) – (b*L) = log(1+b*V*0.277*t) code output will be as shown in figure Expected Outcome Asked By: Aryaman || Source Answers: While …

Total answers: 1

How to make a cue ball follow an equation in a pool game

How to make a cue ball follow an equation in a pool game Question: I am writing a python project for a pool game where rather than using a cue stick to hit a ball straight, the user can input a math equation (This will allow the use of exponential absolute and trigonometry etc. For …

Total answers: 1

Is it possible to solve a deductive reasoning test question using python?

Is it possible to solve a deductive reasoning test question using python? Question: Given a verbal question in a deductive reasoning style, is it possible to solve in python? If the potential variables are never assigned a real world/solid value rather a distance from each other, can it be done? Meaning there is no fixed …

Total answers: 1

XOR linear equation system solver in Python

XOR linear equation system solver in Python Question: I have n rows and n+1 columns matrix and need to construct such system For example matrix is x4 x3 x2 x1 result 1 1 0 1 0 1 0 1 0 1 0 1 0 1 1 1 0 1 1 0 Then equation will be …

Total answers: 2

How to balance a chemical equation in Python 2.7 Using matrices

How to balance a chemical equation in Python 2.7 Using matrices Question: I have a college assignment where I must balance the following equation : NaOH + H2S04 –> Na2S04 + H20 my knowledge of python and coding in general is extremely limited at the moment. So far I have attempted to use matrices to …

Total answers: 4

How can I use "e" (Euler's number) and power operation in python 2.7

How can I use "e" (Euler's number) and power operation? Question: How can I write 1-e^(-value1^2/2*value2^2) in Python? I don’t know how to use power operator and e. Asked By: Thanos Smar || Source Answers: Power is ** and e^ is math.exp: x.append(1 – math.exp(-0.5 * (value1*value2)**2)) Answered By: Daniel Python’s power operator is ** …

Total answers: 7

Computing complex math equations in python

Computing complex math equations in python Question: Are there any libraries or techniques that simplify computing equations ? Take the following two examples: F = B * { [ a * b * sumOf (A / B ”’ for all i ”’ ) ] / [ sumOf(c * d * j) ] } where: F …

Total answers: 3