1 | initial version |
Sorry I have changed your function (but I thinks it is not the problem). You must usee a dictionary to reuse the result
a=3
var('x')
eq1 = x+a==0
sol=solve([eq1],x,solution_dict=True)
x_sol=sol[0][x]
show(LatexExpr(r"x\_sol="+latex(x_sol)))
f(x)=7*x +10
show(LatexExpr(r"f(x\_sol)="+latex(f(x_sol))))
2 | No.2 Revision |
Sorry I have changed your function (but I thinks it is not the problem). You must usee use a dictionary to reuse the result
a=3
var('x')
eq1 = x+a==0
sol=solve([eq1],x,solution_dict=True)
x_sol=sol[0][x]
show(LatexExpr(r"x\_sol="+latex(x_sol)))
f(x)=7*x +10
show(LatexExpr(r"f(x\_sol)="+latex(f(x_sol))))
3 | No.3 Revision |
Sorry I have changed your function (but I thinks it is not the problem). You must use a dictionary to reuse the result
a=3
var('x')
eq1 = x+a==0
sol=solve([eq1],x,solution_dict=True)
x_sol=sol[0][x]
show(LatexExpr(r"x\_sol="+latex(x_sol)))
f(x)=7*x f(x)=5*x +10
show(LatexExpr(r"f(x\_sol)="+latex(f(x_sol))))