Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

to_poly_solve problem?

Hello,

I have:

var ('N,m,sec,a,t,c')

T = (1.27 * 10^6)
Fg = ((9.81*107000))
a = ((T-Fg)/107000)
a = 2.05915887850467

v = a*t
P3 = plot(v, (t,0,11))

v.integral(t)
y = 1.029579439252335*t^2

P1 = plot(y, (t,0,12))

T1 = 1.27*e^(-(t-11)/2) * 10^6
Fg = 9.81*107000
a1 =(T1-Fg)/107000

v1 = a1.integral(t)
v1 = -9.81*t - 23.738317757009348*e^(-1/2*t + 11/2) + 154.299065420560
P4 = plot(v1, (t,11,22))

v1.integral(t)

y1 = -4.905*t^2 + 154.29906542056*t + 47.476635514018696*e^(-1/2*t + 11/2) -1026.68224299065

P2 = plot (y1, (t,12,22))

P = P1 + P2; 
show(P)

Impact = y1.find_root(21,22)
Impact

P5 = P3 + P4
show(P5)

differentiate = diff(y1, t)

solve(-9.81000000000000*t - 23.73831775700935*e^(-1/2*t + 11/2) + 154.299065420560
 == 0, t, to_poly_solve=True)

I am learning SageMath.

When I try to solve the last solve equation that has an exponential with a "t" (the last line in the code) while using to_poly_solve=True, I get the following error:

TypeError: 'sage.symbolic.expression.Expression' object does not support indexing

I would like to solve for "t" so that I can find the maximum of a function.

Thanks in advance.

to_poly_solve problem?

Hello,

I have:

var ('N,m,sec,a,t,c')

T = (1.27 * 10^6)
Fg = ((9.81*107000))
a = ((T-Fg)/107000)
a = 2.05915887850467

v = a*t
P3 = plot(v, (t,0,11))

v.integral(t)
y = 1.029579439252335*t^2

P1 = plot(y, (t,0,12))

T1 = 1.27*e^(-(t-11)/2) * 10^6
Fg = 9.81*107000
a1 =(T1-Fg)/107000

v1 = a1.integral(t)
v1 = -9.81*t - 23.738317757009348*e^(-1/2*t + 11/2) + 154.299065420560
P4 = plot(v1, (t,11,22))

v1.integral(t)

y1 = -4.905*t^2 + 154.29906542056*t + 47.476635514018696*e^(-1/2*t + 11/2) -1026.68224299065

P2 = plot (y1, (t,12,22))

P = P1 + P2; 
show(P)

Impact = y1.find_root(21,22)
Impact

P5 = P3 + P4
show(P5)

differentiate = diff(y1, t)

solve(-9.81000000000000*t - 23.73831775700935*e^(-1/2*t + 11/2) + 154.299065420560
 154.299065420560 == 0, t, to_poly_solve=True)

I am learning SageMath.

When I try to solve the last solve equation that has an exponential with a "t" (the last line in the code) while using to_poly_solve=True, I get the following error:

TypeError: 'sage.symbolic.expression.Expression' object does not support indexing

I would like to solve for "t" so that I can find the maximum of a function.

Thanks in advance. advance.