karolis

5 Reputation

One Badge

11 years, 99 days

MaplePrimes Activity


These are replies submitted by karolis

@Markiyan Hirnyk if i try to use assuming t>0

ww := `assuming`([convert(min(r[-1], r[0], r[1]), piecewise, x)], [t > 0])

output error.
Maybe where is way somehow to get function from plot ?

@Markiyan Hirnyk I tried to compare two plots with both approaches you wrote before.

First one:

w := piecewise((x-a)/t <= -5/2, -20*x+20*a-(149/4)*t, (x-a)/t <= -9/4, -10*x+10*a-(49/4)*t, (x-a)/t <= -2, -9*x+9*a-10*t, (x-a)/t <= -7/4, -8*x+8*a-8*t, (x-a)/t <= -3/2, -7*x+7*a-(25/4)*t, (x-a)/t <= -5/4, -6*x+6*a-(19/4)*t, (x-a)/t <= -1, -5*x+5*a-(7/2)*t, (x-a)/t <= -3/4, -4*x+4*a-(5/2)*t, (x-a)/t <= -1/2, -3*x+3*a-(7/4)*t, (x-a)/t <= -1/4, -2*x+2*a-(5/4)*t, (x-a)/t <= 0, -x+a-t, (x-a)/t <= 1/4, x-a-t, (x-a)/t <= 1/2, 2*x-2*a-(5/4)*t, (x-a)/t <= 3/4, 3*x-3*a-(7/4)*t, (x-a)/t <= 1, 4*x-4*a-(5/2)*t, (x-a)/t <= 5/4, 5*x-5*a-(7/2)*t, (x-a)/t <= 3/2, 6*x-6*a-(19/4)*t, (x-a)/t <= 7/4, 7*x-7*a-(25/4)*t, (x-a)/t <= 2, 8*x-8*a-8*t, (x-a)/t <= 9/4, 9*x-9*a-10*t, (x-a)/t <= 5/2, 10*x-10*a-(49/4)*t, 5/2 < (x-a)/t, 20*x-20*a-(149/4)*t):

for i from -1 to 1 do n := i; r[i] := subs(a = n, w) end do:
plot3d(min(`$`(r[j], j = -1 .. 1)), t = 0 .. 4, x = -4 .. 4):

 

 

Second:
ww := `assuming`([convert(min(r[-1], r[0], r[1]), piecewise, x)], [t > 80])
plot3d(ww, t = 0 .. 4, x = -4 .. 4)

 

Both are similar but not equal. I know that the first is correct answer but i dont know its piecewise function which i need. then we assuming t<80 (for example t>20) shows error. So i think the function which we get by second approach is not correct

 

 

 

 

@Markiyan Hirnyk maybe you know how to get that min piecewise function which was plotted ?

w := piecewise((x-a)/t <= -10, 202*a-200*x-(202001/101)*t, (x-a)/t <= -910/101, 3*a-x-(1011/101)*t, (x-a)/t <= 910/101, 2*a-t, (x-a)/t <= 10, a+x-(1011/101)*t, 10 < (x-a)/t, -198*a+200*x-(202001/101)*t):
plot3d(min(eval(w, a = -1), eval(w, a = 0), eval(w, a = 1)), t = 0 .. 4, x = -4 .. 4);

@Markiyan Hirnyk Thanks you really helped a lot !!!

@Markiyan Hirnyk 

If we display all 3 graphics with a=-1,0,1 we can see that then a=-1 min is then x=-4..-0,5
 a=0, x=−0.5..0.5 and  a=1 min is then x=0.5..4. Correct me if i am wrong

For example in this situation everything works perfectly:

 

@Carl Love 

tried many times

@Markiyan Hirnyk 

why then i uploud file shows 404 file or directory not found...

Page 1 of 1