MaplePrimes Questions

Hello everyone!

I used Maple 17 to fit an ellipse to a set of points using the following guide:

http://www.maplesoft.com/applications/view.aspx?SID=1395&view=html

My rotated ellipse was calculated to be:

SOL;

0.3939708949 x^2 - 0.005975799853 + 0.6345432059 y^2

But everytime I try to graph it in Maple 17, it only shows the axes and nothing else. Any help would be extremely appreciated.

I am recently using maple to plot poincare surface of section, and when I do the harmonic hamiltonian I need to fix different values of p1,q1,p2 and q2 in a tyler series expansion. So i'm expected to use the numbers from a txt file to caculate the tyler series expansion. But after i realize the "readdata" code, i don't know what to do next...

Can anybody tell me how to operate those data please?

Thank you very much!

By the way, I'm not a native English speaker, if my question is unclear please ask me for confirming...

Hi

 

I have some data:

Matrix(10, 2, {(1, 1) = 0, (1, 2) = 0, (2, 1) = .5, (2, 2) = 3.25, (3, 1) = 1.0, (3, 2) = 5.82, (4, 1) = 1.5, (4, 2) = 7.50, (5, 1) = 2.0, (5, 2) = 8.79, (6, 1) = 2.5, (6, 2) = 9.83, (7, 1) = 3.0, (7, 2) = 10.66, (8, 1) = 3.5, (8, 2) = 11.35, (9, 1) = 4.0, (9, 2) = 11.94, (10, 1) = 4.5, (10, 2) = 12.46})

 

I want Maple to make a trendline fitting a Logarithmic function. I can make it output some function with this:

LeastSquares(`<,>`(.5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5), `<,>`(3.25, 5.82, 7.50, 8.79, 9.83, 10.66, 11.35, 11.94, 12.46), x, curve = a+b*ln(x))

It outputs:

5.96497783539274+4.25309474196387*ln(x)

 

But please notice, the dataset in the function does not have the first 0 and 0. If i do that:

LeastSquares(`<,>`(0, .5, 1.0, 1.5, 2.0, 2.5, 3.0, 3.5, 4.0, 4.5), `<,>`(0, 3.25, 5.82, 7.50, 8.79, 9.83, 10.66, 11.35, 11.94, 12.46), x, curve = a+b*ln(x))

It outputs: 

Error, (in Matrix) numeric exception: division by zero

 

Besides that, i need the R-squard value for determinating how well it fits.

 

If i do the same thing i Excel the data set will give a formular: 5.5464ln(x)-0.2175 with a R-sward value of 0.9985.

 

How can i do this i maple?

 

Thanks in Advance!

 

----

Emil Kristensen

A large procedure I made caused me some problems. I finally found the source of the problem.
There seems to be some interaction between the end of parameters marker, $, and the elementwise operation ~.

Consider these 3 versions of essentially the same procedure:

restart;
Q1:=proc(Var::list,$) local n;
  n:=nops(Var);
  print(Var,n);
  proc(var::list)
       subs(Var=~[seq(1..n)],var); #Elementwise
  end proc;
end proc:
Q1([x,y]); #Doesn't work : "invalid expression"
Q2:=proc(Var::list,$) local n;
  n:=nops(Var);
  print(Var,n);
  proc(var::list)
      subs(zip(`=`,Var,[seq(1..n)]),var); # zip
  end proc;
end proc:
Q2([x,y]); #No problem
Q3:=proc(Var::list) local n; #No end of parameters marker $
  n:=nops(Var);
  print(Var,n);
  proc(var::list)
       subs(Var=~[seq(1..n)],var); # Elementwise
  end proc;
end proc:
Q3([x,y]); # No problem
lprint(Q3([x,y])); #Curious output involving ` $`
#A fourth procedure in which the output is not a procedure works:
Q4:=proc(Var::list,$) local n;
  n:=nops(Var);
  print(Var,n);
  subs(Var=~[seq(1..n)],Var)
end proc:
Q4([x,y]);

Does anybody have any comments? Is it a bug?

This is a silly question, but Maple's help menu didn't address it, and I couldn't find an answer in a few minutes of Web-surfing.  I have Maple15 installed on my office PC.  I have managed to set the default settings to avoid Maple's recent "disprovements", so that, for example, I can see what I've typed.  Using Maple today, in worksheet mode, for some reason a command prompt does not appear after I execute a command.  I want one to.  Does anyone know how to fix this?

GS

AOA...I want to introduce an operator to find the derivative of fractional order i.e.,

 

J^((alpha)) x^(k):=(GAMMA(k+1))/(GAMMA(k-alpha+1))x^(k-alpha):

 

when i applied J^(1/2) on x^2+x^3 it gives

 

GAMMA(3)*x^(3/2)/GAMMA(7/2)+GAMMA(4)*x^(5/2)/GAMMA(9/2)

 

Help.mw

hi, I am new here I want to solve these toe coupled equations with the following boundary condition numerically:

  1)  diff(f(eta),eta$3)+(1)/(2)*f(eta)*diff(f(eta),eta$2)-xi*(2*f(eta)*(diff(f(eta),eta))*

(diff(f(eta),eta,eta))+f(eta)^2*(diff(f(eta),eta,eta,eta))+eta*(diff(f(eta),eta))^2*(diff(f(eta),eta$2)))-K*

(diff(f(eta),eta)-1)=0

2)   diff(theta(eta),eta,eta)+(1)/(2)*Pr*f(eta)*(diff(theta(eta),eta))=0

boundary conditions: 1)  f(0) = 0   2)  D(f)(0) = 0   3)  D(f)(infinity=10) = 1

                               1) theta(infinity=10) = 1      2) theta(0)=0

xi=0.2 ... 1    K=0.2     pr=0.7

1.

entail logic ⊨ is equivalent to what logic which in terms of conj and disj and not 

for example ⊨A <-> B, there is nothing in left hand side, 

2.

does it mean that it should represent Entail(_, A<->B)  where _ is wildcard? 

I can get the function to iterate as a recursive function by just reevaluating the x := evalf(x-(f1*j-i*g1)/(h*k-i*j), 25); y := evalf(y-(h*g1-f1*j)/(h*k-i*j), 25) portion of the function below but im trying beneath it to assign it as newt2d so that i can iterate it as newtons method in two variables like (newt2d@@10) and I can't seem to figure out what im doing wrong. Thanks for any help you can provide!

f := proc (x, y) options operator, arrow; x+y-cos(x)+sin(y-1) end proc; f1 := f(x, y)

(x, y) -> x + y - cos(x) + sin(y - 1)
x + y - cos(x) + sin(y - 1)

> g := proc (x, y) options operator, arrow; x^4+y^4-2*x*y end proc; g1 := g(x, y);

(x, y) -> x + y - 2 x y
x + y - 2 x y

> dh := D[1](f); h := dh(x, y);

(x, y) -> 1 + sin(x)
1 + sin(x)

> di := D[2](f); i := di(x, y);

(x, y) -> 1 + cos(y - 1)
1 + cos(y - 1)

> dj := D[1](g); j := dj(x, y);

(x, y) -> 4 x - 2 y
4 x - 2 y

> dk := D[2](g); k := dk(x, y);

(x, y) -> 4 y - 2 x
4 y - 2 x

x := .3; y := .8

0.3
0.8

> x := evalf(x-(f1*j-i*g1)/(h*k-i*j), 25); y := evalf(y-(h*g1-f1*j)/(h*k-i*j), 25);

0.2924403963319692595180140
0.8321243516906678979858730

> newt2d(.3, .8);

0.2577789764, 0.8333916830

> (newt2d@@5)(.3, .8);

Error, (in @@) invalid arguments



Hi There,

 

Could you let me know how to tell Maple to use the ln simplification to give -ln(x)+ln(y) = ln(y/x).

 

I tried following command.

simplify(-ln(x)+ln(y), ln)

 

However, it is not able to give the required simplification.

Greetings folks,

 

I need to perform Gauss Jordan Elimination on a 7x10 Matrix, returning the row reduced echolon form. The matrix entries itself are sums of several variable products, where the variables itself are sometimes exponential. The link provides an excerpt of said matrix for illustration.

https://www.dropbox.com/s/p9lyg8tmk0hpbbj/polyGLS7rows.png

I tried solving this with MatLab Mupad, but to no avail, at some point the calculation runs out of memory. Simplification of the expressions didn't help either.

Tried the same with Maple. It doesn't run out of memory but looses connection with the kernel at some point.

I'd be glad about some suggestion about how to solve this problem. Basically I want to reproduce the process of the following paper: http://www.inf.ethz.ch/personal/pomarc/pubs/FraundorferECCV10.pdf

The paper itself cites using the Gröbner basis package of Maple for reaching a solution so maybe I am missing something out.

Any help is greatly appreciated

Regards,

JCR

 

Edit: Exponential functions reside in the lower part of the matrix. Path to Maple Worksheet https://www.dropbox.com/s/xb99xlddba57cs7/GLSPoly7rows.mw

Hi,
can you please help me solve that?
I want to write maple procedure that checks if a number is prime or not and I need to do it so that it doesn`t take forever to give an answer.
I wrote a procedure that works good with small numbers but when I put bigger numbers eg.9999971 it is taking far too long (5min) to get the answer, I tried to modify it and I think I find out something that could be modified to make it more efficient, like for example in the line:   for j from 2 to n-1 do     (I changed it to: ) for j from 2 to n-1  by n do    - it tooks 9.953 second to get the answer   (or I changed it to: ) for j from 2 to (n-1)/2  do   - it tooks 262.062 second I also tried many things and I always get an answer after long time excepte when I changed the line to for j from 2 to (n-1)/n  do   - it tooks 0 second but I didn't find any explanation why should I devide it by n as j from 2 to ((n-1)/n) = 1-(1/n) which is less than 2 as it make no sence....
But it still not efficient enough, because if for example I use the maple command isprime,then I got the result in less than 1 second.
In the program I used other procedure that I think will make it quicker which is a floor function procedure. please see bellow :  

> flr:=proc(a,b)

      local n:

      n:=0:

      while a>=b*(n+1) do

         n:=n+1:

     od:

       n;

   end:

 


> Isprime:=proc(n)        

         local j, p:      

         p:=true:               

         if n=2 then

            p:=true;       

        else

             for j from 2 to n-1 do 

                  if (n/j-flr(n,j))=0 then

                       p:=false:

                  fi:

              od:

         fi:

     p:

     end:

 

>zeit:=time():

Isprime(9999971); 

time()-zeit,`second`;

                                                                   true

                                                                    309.558, second

 

Please reply and thank you in advance

Maple crashed while saving and now there is nothing in my file. Lost a bunch of work, any way to fix it?

Thanks
EquationSheet357.mw

(x+y)(x2+y2) = 5500

(x-y)(x2-y2) = 352

First 1459 1460 1461 1462 1463 1464 1465 Last Page 1461 of 2434