MaplePrimes Questions

If I have some data, how would I determine the best normal distribution fit?

Hi:

I would like to slightly modify the "Explore" command -- I find it extremely useful, but the layout often doesn't work well for me (my typical use case is say 12 plots with ~10 parameters that vary). The problem is that the default alignment the columns of the table that contains a matrix of plots is "Center" and my plots don't fit on the screen properly (no matter how I play with sizes, placement, etc) and I would like it to be "Left" aligned --- aligning things manually (via right click) after the explore command is executed is possible, but painful, given that I often change my code.

... bottom line is that I would like to be able to re-define the "Explore" command.

I tried doing so by first calling:
showstat(Explore);

... then removing all the numbers, renaming the proc to sat MyExplore, declaring it (i.e. so maple understands it) and for now using that instead of the old Explore in my program (with no actual code changes for now). The problem is that I get the following error:

Error, (in DocumentTools:-Layout:-Table) number of Column arguments, 3, exceeds total column span, 1, computed from Rows' Cells

I think, somehow maybe showstat is not showing the full thing? or maybe it is part of a more complicated module? or maybe by removing the numbers the formatting got screwed up (i was careful here)?

So my question:

How would I define my own function "MyExplore" that (for now) contains exactly the same code and functionality as the built-in "Explore"?

thanks!

Hi Clever guys,
I am sorry if I asked for too much, but I am really in a big problem, I had a family problem and I didn't attend most of the lectures, and now I have to hand in an assignment before easter hollydays, and to be honest with you, I don't know from where to start, I know I will have to understand this stuff, but now I don't have enough time to do the assignment, so if anyone can help me, please please, for you guys it will maybe take 20min to do it, i ll need days and days and in the end it will be all wrong. I am going to try to do the other questions, there are 5 questions :(  
Please help me , I am really not a very bad student that just want to copie, but if nobody does this for me this time I will fell, please do this question for me please.. maybe you will say start it and then ask to check if it is correct, I am really trying my best, please.

that is one question:


By integrating a third order Newton Gregory Polynomial, derive Simpson’s

three eights rule given by

∫ f(x)dx (from x0 to x3 ) =3/8*ℎ(y0 + 3y1 + 3y2 + y3)

(b) Find the order of accuracy of Simpson’s rule and Simpson’s three eights rule.

 




thank you very much 

Hi,

 

Lets say we have some expression like

0.5* t^5 * r^-1 *V

 

is there some way in maple to determine the power of the variable t ?

My goal is to realize a procedure [lets call it PowerOfT() ]  , so that

 

PowerOfT( 0.5* t^5 * r^-1 *V) = 5

 

Thank you very much for your help.

 

 

I want to translate my maple code with matrice multiplication  to C code. But the command  "Multiply" cannot be translated. So I want to edit the function translation by myself. I use "AddFunction" command to create a new function  "Multiply" and want to specify its corresponding C code.

 


f := proc ()
local x,y;
x := Matrix([[1, 2], [3, 4]]);
y := Matrix([[1,3],[4,2]]);
Multiply(x, y);
NULL;
end proc;

LanguageDefinition:-Define("NewC", extend = "C", AddFunction("Multiply", [Matrix,Matrix]::Matrix,
proc (X, Y)
local a,b;
a := 2;
b := convert(a, string);
Printer:-Print("Mmultiply(", X);
Printer:-Print(",", Y, ")"); Printer:-Print("\n");
Printer:-Print("from", b, "to");
Printer:-Print(",", Y, "do") end proc, numeric = double));
Translate(f, language = "NewC")

 

But when I run it, the "Multiply" function cannot be translated.  The result is:

 

Warning, type signature [CodeGeneration:-Names:-ArrayType(integer,CodeGeneration:-Names:-ArrayRanges(1 .. 2,1 .. 2),CodeGeneration:-Names:-ArrayOptions()), CodeGeneration:-Names:-ArrayType(integer,CodeGeneration:-Names:-ArrayRanges(1 .. 2,1 .. 2),CodeGeneration:-Names:-ArrayOptions())] for function Multiply is not recognized
void f (void)
{
  int x[2][2];
  int y[2][2];
  x[0][0] = 1;
  x[0][1] = 2;
  x[1][0] = 3;
  x[1][1] = 4;
  y[0][0] = 1;
  y[0][1] = 3;
  y[1][0] = 4;
  y[1][1] = 2;
  Multiply(x, y);
  ;
}

I don't know why "Multiply(x,y)" cannot be translated.

If I put two "Multiply(x, y)" in the procedure, like this:


f := proc ()
local x,y;

Multiply(x, y);
x := Matrix([[1, 2], [3, 4]]);
y := Matrix([[1,3],[4,2]]);
Multiply(x, y);
NULL;
end proc;

LanguageDefinition:-Define("NewC", extend = "C", AddFunction("Multiply", [Matrix,Matrix]::Matrix,
proc (X, Y)
local a;
a := 2;
b := convert(a, string);
Printer:-Print("Mmultiply(", X);
Printer:-Print(",", Y, ")"); Printer:-Print("\n");
Printer:-Print("from", b, "to");
Printer:-Print(",", Y, "do") end proc, numeric = double));
Translate(f, language = "NewC")

THe result is:

Warning, cannot resolve types, reassigning x's type
Warning, cannot resolve types, reassigning y's type
Error, (in CodeGeneration:-IssueError) type 'Matrix' cannot be translated to target language

I don't know why type 'Matrix' cannot be translated.

 

 

how to customize/invert the foreground/background color scheme in Maple?

 

The black on white is killing my eyes and also wasting energy, white on black is much better on the eyes and conserves energy (pixel brightness), imho

 

thanks in advance!

 

 

I want to draw plots with big numbers in axes

but when I change font sizes it dont work

please help me

Thanks

restart;
eta := 3:
beta := t[1]*(H-t[1])/H^2:
for i from 5 to 10 do H := i:
PL[i] := plot((t[1]^4+2*eta*beta*(2-beta)*H^4+eta^2*(H-t[1])^4)/(eta*(H-t[1])+t[1]), t[1] = 0 .. H, y = 0 .. 3000, color = black, axesfont = [Font(14), Font(14)], size = [560, 500]) end do:
with(plots): display({seq(PL[j], j = 5 .. 10)})

 

Hello!

I performed a calculation where the output was a matrix that Maple said was too big to display explicitly. So, this output was just a summary. Specifically, something like this:

 

 

How can I save/export the data inside it to another matrix so that I can manipulate it while staying within Maple?

 

I can export to an external file using

and then reimport the data back into Maple. But this is cumbersome.

I can also see the data on my screen by double-clicking on the matrix. But I haven't been able to manage to copy & paste it within Maple or transfer it to another matrix so I can manipulate the data. How do I do this? I'd like to stay within Maple to avoid the hassle of exporting data to Excel & then reimporting it.

Thanks,

Damian.

given the following:

param:= {mu[2] = (1600), mu[4] = (1500)}
R := unapply(1/(1+exp((1/50)*x)), x);

prior := evalf(expand(eval(eval(R(abs(mu[4]-mu[2])), `` = (x->x)), param)));
   

I need to keep the paramaters encapsulated. I would like this last step to output the answer 0.1192029.... but the abs function doesn't let me

I need a list version of Contourplot. I have a list in the format [[z1,x1,y1],[z2,x2,y2],...[zn,xn,yn],...]

where z represents some data value at coordinate (x,y). Basically I need a 2D figure with the x and y values shown on the axes and the z-value represented in a color code. Just like "contourplot" except in my case I cannot use it since I do not know the general function of two variables but only the list  with the data points. Is this possible with a built in Maple command?

 

Thanks

 

 

Hello I download maple2015 today but I dont know how can I work with it ?  how can I write math phrases?

Please help me soon!!!!

I have this (which finds each Fourier term of a sequence)

term := proc(lst,k::integer)
    local n;
    n := nops(lst);     
    seq(lst[m+1]*exp(-I * 2*Pi/n *(k*m)),m=0..n-1);
end proc;

Now I call it as

term([1,2,3],1);

and it returns

So it evaluated and convert the exp(-I * 2*Pi/n *(k*m)) terms. I wanted to keep these as is, so I can compare result with textbook. Then do simplify if I wanted to above output. 

I can do that if I use small pi instead of large Pi, like this

term := proc(lst,k::integer)
    local n;
    n := nops(lst);     
    seq(lst[m+1]*exp(-I * 2*pi/n *(k*m)),m=0..n-1);
end proc;

and now r:=term([1,2,3],1); return

Which is what I wanted, but with Pi instead of pi.  now how would I evaluate the above?

I tried to use subs to replace small pi with large Pi, but it does not work

subs(pi=Pi,r); #error

Then I tried eval, which worked

eval(r,pi=Pi);

So, I can use the above method.

My question is: Is the above a common way to handle such case? Is there another way to use Pi but at the same time prevent Maple from automatic simplification of the exp() terms?

 

 

 

 

Maplesim 7.0(1) installer looks for Maple 18 installation.  Will Maplesim work with Maple 2015?

If not, what is the expected date of making both products compatible?

Regards,

G

Hello to everyone,

I want to solve the following inequality:

solve(b^4-(2-d)*b^2-2*d*b+1+d > 0, [b]), where b is my variable and d is a pamater in (0,1]. 

When I try to sovle this I get a message "Warning, solutions may have been lost" and from the official maple website they suggest to reformulate the problem.

Is there anything I can do to solve the above inequality?

 

Thanks in advance!

I want to plot a function f(v). But I could not find the explicit form of f(v). I know the function f(u) where u satisifies the relation int(h(u),u)=v for known function h(u). But unfortunately, Maple could not help to solve the integral i.e. I could not find u in terms of v. Under these conditions, is it possible to plot f(v) by using Maple?

Thanks.

First 1296 1297 1298 1299 1300 1301 1302 Last Page 1298 of 2429