MaplePrimes Questions

I need a procedure to simplify rational functions r(x,y) = p(x,y)/q(x,y)  where p(x,y) and q(x,y) are polynomials in Z/(2)[x,y].

For example suppose r(x,y) = (1+x+y)/(x^2+x*y+y+1) then mod 2 this reduces to 1/(1+x) since 

            Factor(x^2+x*y+y+1) mod 2 = (1 + x + y) (1 + x)

I wrote a procedure to do this using Factors mod 2, but I wonder if there is a builtin procedure to make such simplifications that might be more efficient.  For now 2 variable is fine, but later I may want more than 2 variables.

Edwin

 

 

How can I create a new object from a stanrd, defined in a given metric? For example I want to define an object by convolution of two indices of the Christoffel symbols? I cannot even to see components of such object.

Many thans for an explanation

 

Leonid

Hi, there i want to basically plot the graph attached. It is basically the graph y= 2x^2 transformed to y = x^2. I can plot them, but how do they get the arrows showing the transformation and the arrows on the axis. Any help would be appreciated.

Thanks

okay so im quite confused, im trying to write a procedure that prints the orbit of a 2x2 matrix through a given list of points.  our arguments should be a a (2x2) matrix, a list L of points represented by 2 vectors, ie (2x1) matrices and a natural number N. Returnvalue : NULL

a side effect should be to 

A^i.L[j] for i = 0 ... N and j = 1 ... nops(L)

thus, an example, if the proc is called P, then 

P(Matrix([[0,-1],[1,0]]),[Matrix([[1],[1]]),Matrix([[1],[0]])],2) 

should plot the points  

(1,1) ,(-1,1) , (-1,-1)  for the 1st point  and 

(1,0)  ,(0,1) , (-1,0) for the second

thanks for any help in advance

Hi, how would you add arrowheads to the x and y-axis to show that they continue.

Thanks 

Composite1:=proc(g,f)
Flist := indets(f): Glist := indets(g): gof:=g:
Subslist1 := [seq( Flist[i]=q, i=1.. nops(Flist))]:
return subs(q=f,subs(Subslist1, gof)): # g(f)
end proc:
#F(g o f) = F(g) o F(f) = F o g o f = (F o g) o (F o f)
Functor := (1/2)*(-y*t2-x*t1-y*t3+sqrt(y^2*t2^2+2*y*t2*x*t1+2*y^2*t2*t3+x^2*t1^2+2*x*t1*y*t3+y^2*t3^2-4*x*t4*y*t9-4*x*t4*y*t8-4*x^2*t4*t7-4*y^2*t5*t9-4*y^2*t5*t8-4*y*t5*x*t7-4*y^2*t6*t9-4*y^2*t6*t8-4*y*t6*x*t7))/(x*t4+y*t5+y*t6);
F1:=x+2;
G1:=3*x+5;
gof:=subs(x=F1, G1);
osys := Composite1(gof, Functor) = Composite1(Composite1(G1, Functor),Composite1(F1, Functor));
sys1 := subs(x=3,subs(y=2, osys));sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
res:=solve([sys1, sys2, sys3, sys4, sys5, sys6, sys7, sys8, sys9], {t1,t2,t3,t4,t5,t6,t7,t8,t9});
simplify(%);
`~`[lhs](select(evalb, res));

alpha:= (1/2)*(-y*t2-x*t1-y*t3+sqrt(y^2*t2^2+2*y*t2*x*t1+2*y^2*t2*t3+x^2*t1^2+2*x*t1*y*t3+y^2*t3^2-4*x*t4*y*t9-4*x*t4*y*t8-4*x^2*t4*t7-4*y^2*t5*t9-4*y^2*t5*t8-4*y*t5*x*t7-4*y^2*t6*t9-4*y^2*t6*t8-4*y*t6*x*t7))/(x*t4+y*t5+y*t6);
g := -y/x;
f := (-x+sqrt(x^2-x*y-2*y^2))/(2*y+x);
subs(p=f,subs(q=f,subs(x=p,subs(y=q,g))));
g := (1/2)*(-x+sqrt(x^2-4*y*x-4*y^2))/(x+y);
f := x*y;
gof := subs(p=f,subs(q=f,subs(x=p,subs(y=q,g))));
lhsgofoalpha := subs(q= alpha,subs(p=alpha, subs(x=p,subs(y=q,gof))));
foalpha := subs(p= alpha,subs(q=alpha,subs(x=p,subs(y=q,f))));
rhsgofoalpha := subs(x= foalpha,subs(y= foalpha, g));
osys := lhsgofoalpha = rhsgofoalpha;
sys1 := subs(x=3,subs(y=2, osys));
sys2 := subs(x=5,subs(y=1, osys));
sys3 := subs(x=1,subs(y=5, osys));
sys4 := subs(x=1,subs(y=2, osys));
sys5 := subs(x=2,subs(y=5, osys));
sys6 := subs(x=5,subs(y=2, osys));
sys7 := subs(x=2,subs(y=1, osys));
sys8 := subs(x=3,subs(y=5, osys));
sys9 := subs(x=5,subs(y=3, osys));
res:=solve([Re(sys1)=0, Re(sys2) =0, Re(sys3) =0, Re(sys4) =0, Re(sys5) =0, Re(sys6) =0, Re(sys7) =0, Re(sys8) =0, Re(sys9) =0], {t1,t2,t3,t4,t5,t6,t7,t8,t9});

 

I want to taylor-expand cos(x) to the powers of two, four, and six, then to make equations which does not contain O(x^2) etc. and to obtain its value at x=0.1.

For that, I wrote as the following.
(1):
a:=seq(taylor(cos(x),x=0,i),i=[2,4,6]);
convert(a),polynom);

(2):
a:=seq(taylor(cos(x),x=0,i),i=[2,4,6]);
seq(convert(op(i,a),polynom),i=[2,4,6]);

(3):
a:=seq(taylor(cos(x),x=0,i),i=[2,4,6]):
convert(a,polynom);

All of the above were not good.

On earth, I couldn't pick up each of the result of
a:=seq(taylor(cos(x),x=0,i),i=[2,4,6])
with op(1,a).

How can I solve this problem?

I have created a diagram with "plots" and "plottools" that involves the line command creating a line in 3-space.  It works just fine on all of my machines and versions of Maple but it fails on Maple 17 in the Windows 8 environment.   By "fai;s" I mean that it does not draw the line; it does not generate an error message.   Any idea what's happening? 

I wrote the following code inside a code region in order to implement a scalar product for lists:

m:= module() option package; export `*`;
    `*`:= proc( a::list, b::list) option overload;
        return add(i, i  in zip((x, y)-> x*y, a, b));
    end proc;    
end module;
l1:=[1,2,3,4];
l2:=[4,1,0,5];
with(m);
l1*l2;

when i run the code I sometimes get the desired result ->26

but sometimes I get

I don't have any clue, where this weird behaviour comes from.

Any help would be greatly appreciated.

 

Hi! I can't answer the following two simple questions.

1) Why do use different font sizes every other  files created by the attached worksheet?

2) What happens when we uncomment some (all) of the #restart lines, and execute the commands (execution groups)  in the original order? How many files should we get?

 

Update: sorry, I can't see the uploaded worksheet, but here it is as plain text:

#### on Fedora 18 Linux, Maple 17.01:

#restart;


currentdir(kernelopts(homedir)):
currentdir();


#restart;


plotsetup(ps,plotoutput= `sinplot1`, plotoptions = `width=500,height=500, font=[TIMES, BOLD, 16]`);
plot(sin(x), x=-Pi..Pi, title="Output: sinplot1.eps");


#restart;


plotsetup(ps,plotoutput= `sinplot2`, plotoptions = `width=500,height=500`);
plot(sin(x), x=-Pi..Pi, font=[TIMES, BOLD, 16], title="Output: sinplot2.eps");

#### Restart in the same execution group as the plot statements - no output file?

#restart;
plotsetup(ps,plotoutput= `sinplot3`, plotoptions = `width=500,height=500, font=[TIMES, BOLD, 16]`);
plot(sin(x), x=-Pi..Pi, title="Output: sinplot3.eps");


#restart;
plotsetup(ps,plotoutput= `sinplot4`, plotoptions = `width=500,height=500`);
plot(sin(x), x=-Pi..Pi, font=[TIMES, BOLD, 16], title="Output: sinplot4.eps");

hello, how to write this system?

> restart;
> x10:=0.2; x20:=0.4; U0:=0.25;
> eq3 :=subs(U(t)=(piecewise(U(t)<=0,0,U(t)>=1,1,U(t))),(1/4)*(U(t)^2*x1(t)-2*U(t)*x1(t)*sqrt(x2(t))-U(t)^2*x2(t)+2*U(t)*x2(t)*sqrt(x1(t))-2*(diff(U(t), t))*x1(t)^(3/2)*U(t)+4*(diff(U(t), t))*x1(t)^(3/2)*sqrt(x2(t))+2*(diff(U(t), t))*x2(t)^(3/2)*U(t)-4*(diff(U(t), t))*x2(t)^(3/2)*sqrt(x1(t)))/(x1(t)^(3/2)*x2(t)^(3/2)));
> sys := eq3=0, diff(x1(t), t) = (piecewise(U(t)<=0,0,U(t)>=1,1,U(t)))-sqrt(x1(t)), diff(x2(t), t) = (piecewise(U(t)<=0,0,U(t)>=1,1,U(t)))-sqrt(x2(t));
> dsolve({sys,x1(0)=x10,x2(0)=x20,U(0)=U0},{x1(t),x2(t),U(t)},type=numeric);

 

Male produces an error: Error, (in DEtools/convertsys) invalid input: eval expects its 2nd argument, eqns, to be of type {integer, equation, set(equation)}, but received newdeqns

Hi,

restart:with(plots):

L1 := (1/2)*(S+sqrt(S^2+4*a*b))/b;

L2 := (1/2)*(S-sqrt(S^2+4*a*b))/b;

solve(L1=L2,S);

         2*sqrt(-a*b), -2*sqrt(-a*b)

solve(L1=L2,a);

             -(1/4)*S^2/b

solve(L1=L2,b);

                -(1/4)*S^2/a

Here is my question. 

Now plotting L1, L2 

a:=1:b:=1: # say

plot({L1,L2},S=0..1);

Is there a way to utilize the conditions which we can get through solve and use it while plotting (not 3d plotting) for any given choice of the values of a, b, S? 

 

 

Hallo guys,

I am newbie in Mapple, i could not solve the problem yet, here is my little function. I want to estimate beta with the Maximum Likelihood Estimation with Weibull: 

> MaximumLikelihoodEstimate(Weibull(beta, eta), F1); F1 := Vector([1500, 1750, 2250, 4000, 4300, 5000, 7000]);
print(`output redirected...`); # input placeholder
[beta = HFloat(HFloat(undefined)), eta = HFloat(HFloat(undefined))

]

 

May someone help me why i just get HFloat(undefined)  ?

 

Kind regards

Can anyone tell me how to solve the equation above using Maple.  I know that there is a solution around x=0.995, y=0.743, but I cannot induce Maple to find it.  Any help or suggestions would be appreciated.

Ratch

 

First 1461 1462 1463 1464 1465 1466 1467 Last Page 1463 of 2426