Comments (4)
I would have expected both to be True.
from sympy.
While the integration symbol is truly a dummy symbol during definite integration, the symbol of differentiation is not. One must introspect to see if the symbol will survive differentiation. When the function being differentiated does not have the symbol of differentiation, t, the result clearly will be independent of t. That's why it makes sense that there is no t in the free symbols.
But if the function had t in a linear form then perhaps it is debatable whether the t should be reported as a free symbol or not, just like any other object, e.g. y=x**2 +2*x - (x + 1)**2
as written contains x
, but after expansion, will not.
So the answer could be True or False for the OP expressions, but they should be consistent, and documentation should be clear for Derivative to indicate when a symbol will be considered free or not.
from sympy.
I don't think free symbols should try to do any sort of mathematical constant detection. It should be a fast structural check only, along the lines of ==
. If the symbol appears in an expression in a place where it is free it should be considered a free variable.
Also, consider that if t
is not free in expr
, then that means that you should be able to replace any free symbol in expr
with t
and get an equivalent expression. But Derivative(f(x), t).subs(x, t)
is not the same thing anymore. So from that point of view, even mathematically constant expressions should not be considered to be free of a given symbol if they still contain it literally somewhere.
from sympy.
Related Issues (20)
- sympy.Float and sympy.Integer compare equal but have different hashes HOT 1
- Duffing Spring Simulation HOT 5
- Formal Power Series with even or odd terms shouldn't return Piecewise formula for coefficients HOT 3
- The `join` method is unable to create beams with discontinuous values of elastic modulus.
- `lambdify()` and `lambdastr()` can't unpack `sympy.Matrix` typed parameter symbols properly
- RecursionError in sympy.solvers.inequalities.reduce_inequalities with custom function HOT 1
- The `point_cflexure` method doesn't return points when a region of the bending moment line is 0.
- Symbolic specifying of locations that are "just" before or "just" after another location. HOT 18
- parse_mathematica cannot handle greek letters HOT 1
- FiniteField.__call__ returns different types depending on whether flint is installed or not HOT 6
- Incorrect partial fraction expansion with floats HOT 3
- Sphinx build failing regularly HOT 1
- calling `latex` on `Array` with less rows than columns, and at least 10 columns, emit bad latex
- Does solve(...) respects symbol(..., real=True) assumption?
- Sympy results are int, not Integer HOT 1
- Regression: lambdify of Derivative instance now throws PrintMethodNotImplementedError HOT 24
- sp.solve: expected an integer, got rational HOT 2
- Cannot determine truth value of Relational HOT 1
- plot error after a "clean" simpify check up HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sympy.