You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a funcion to get the coefficent of a specified symbol in an expression, for example
julia>using SymEngine
julia> x, y =symbols("x y")
(x, y)
julia> y = (2*x+1)^3
(1+2*x)^3
julia> y_expand =expand(y)
1+6*x +12*x^2+8*x^3
If we want to get the coefficent of x^2, than we have a function get_coefficent(x^2, y) or get_coefficent(x^2, y_expand) . Then the function return 12.
I think this is a basis function. Thank you very much!
The text was updated successfully, but these errors were encountered:
Is there a funcion to get the coefficent of a specified symbol in an expression, for example
If we want to get the coefficent of
x^2
, than we have a functionget_coefficent(x^2, y)
orget_coefficent(x^2, y_expand)
. Then the function return12
.I think this is a basis function. Thank you very much!
The text was updated successfully, but these errors were encountered: