Maple 2017 Questions and Posts

These are Posts and Questions associated with the product, Maple 2017

Using Tools -> Check for Updates, I have just tried to update my Maple installation from 2017.0 to 2017.1. The download itself went without a hitch, but then nothing happened. In view of the fact that I clicked a button titled 'Download and Install', I would certainly expect the installation to have started automatically after download. Are anyone else experiencing the same odd behaviour?

PS: Related question of mine is Automatic update of help pages?

Hi, friends

I need to calculate the double integral over a non-rectangular domain.

Say, the domain is the triangle (in red)

When I enter

int(int((x^2+y^2)*`if`((y-x-1/2 <= 0) and (y+2*x-2<=0) and (y+x/2-1/2>=0), 1, 0), x=0..1, numeric = true), y=0..1, numeric = true);

or 

int(int((x^2+y^2)*eval(`if`((y-x-1/2 <= 0) and (y+2*x-2<=0) and (y+x/2-1/2>=0), 1, 0)), x=0..1, numeric = true), y=0..1, numeric = true);

an error occur (Error, (in int) cannot determine if this expression is true or false: y-x <= 1/2 and y+2*x <= 2 and 0 <= y+(1/2)*x-1/2)

For me, it is desirable to write boundary conditions in the int operator itself, not as a separate expession.

 

Consider the following:

with(Physics):
Setup(anticommutativeprefix = psi):
psi^2,psi__1^2,psi__a^2;   # double underscores

Why does the square of psi__a (double underscore) not vanish as well? Or, perhaps, more to the point: why is psi__a not as well considered Grassmann-odd by Maple? Is this counter-intuitive behaviour intentional, or is it a bug?

I need to install FGb package into Maple, the instruction is here:http://www-polsys.lip6.fr/~jcf/FGb/FGb/darwin_i386/index.html

But after I tried so many times, I am still unable to install the package(the instruction is a little bit unclear).  Basically, I downloaded the file FGb-1.61.macosx.tar.gz  in my home directory and unzip it. I created .mapleinit and put these commands inside:

libname:= “Macintosh HD/Users/jinhuilitar xvfz/tmp/FGb-1.61.macosx.tar.gz”/FGblib, libname:

mv <12627>/*.so <Macintosh HD/Users/jinhuili/tar xvfz/tmp/FGb-1.61.macosx.tar.gz>

 mv <12627>/FGblib <Macintosh HD/Users/jinhuili/tar xvfz/tmp/FGb-1.61.macosx.tar.gz>

 

I put .mapleinit in the home directory as well. But after I did all of these followed the instructions, I opened Maple and type with(FGb), it says FGb does not exist. I am so desperate, I have tried two days to solve this simple problem, please help.

See the below. The two answers should be identical, but they are not.

Input:


Output:


 

I have a plain text file, with hundreds of lines. I read using the command

ImportMatrix(file_to_read, source=csv):

The files has mixed fields which are integers and strings. The problem happens when a string happeneds to be "0". Maple interprets this when reading as the integer zero and not as the string zero! So that when I print this field later on using printf("%s",field) I get an error. (since I know this field is string, the format for output is fixed in the code). 

I made a very small example to illustrate. One line with 4 fields. The 4ht field is string.

This specific field is always a string with alphanumeric content in the file. It has " " around it. But sometimes the content of the string happens to be the string "0".  Maple gets confused and reads "0" as integer 0.

Is there a way to tell Maple not to read this string as an integer using ImportMatrix?

Here is MWE to show the problem


restart;
currentdirName :="C:\\bug";
currentdir(currentdirName);
file_to_read := cat(currentdirName,"\\maple_input.txt");
data:=ImportMatrix(file_to_read, source=csv):

print(data);
whattype(data[1,1]);
whattype(data[1,4]);

printf("%d,%d,%d,%s",data[1,1],data[1,2],data[1,3],data[1,4]):

 

The input file maple_input.txt has this one line in it:

1,2,3,"0"

As you can see, the 4ht field is a string.  But Maple reads it as integer:

 

This is using Maple 2017.1 on windows. Also Attached the text file.

1,2,3,"0"

Download maple_input.txt

 

Do you have Maple content that you want to protect from editing and viewing, while still allowing others to execute the code within and obtain results? In Maple, worksheets can be password protected so the users of your Maple application can benefit from the specialized routines you've created while the details remain hidden.


The password protection feature can be useful for a variety of situations, such as:

  • • Providing a Maple-based solution while protecting the intellectual property embodied in your algorithms
  • • Ensuring the users of your application can not accidentally make changes that break your code

 

To learn more about this feature in Maple, you can download the free Tips & Techniques from the Application Center.

Moments ago, when I consulted the help pages, there popped up an Update window followed by a download of some 100MB+, and then nothing more seemed to happen. What was that about?, I wonder. Was it automatic updating of the help pages, or what?

Is there a command to find out what is new in 2017.1 that just got installed on my PC?

kernelopts(version);
  Maple 2017.1, X86 64 WINDOWS, Jun 19 2017, Build ID 1238644

I searched and googled and could not find such a command.

This Saturday is Canada’s 150th birthday. As you can imagine, the country has been paying a lot more attention to this year’s anniversary than our usual low key approach, and as a Canadian company, we at Maplesoft decided to join in the fun.

And what better way for Maplesoft to celebrate Canada’s birthday than to create a maple leaf in Maple! 

So here is a maple leaf inspired by the Canada 150 logo, which was created by Ariana Cuvin, a student at the University of Waterloo and former co-op here at Maplesoft:

Here’s the code to reproduce this plot (more details can be found in this follow up post):

p:=thickness=5,color="#DC2828":
plots:-display(

    plot([[-.216,-.216],[0,0],[-.216,.216],[-.81,0],[-.216,-.216]],p),  
    plot([[-.55,.095],[-.733,.236],[-.49,.245]],p),
    plot([[-.376,0],[0,0],[0,.376],[-.705,.705],[-.376,0]],p),
    plot([[-.342,.536],[-.355,.859],[-.138,.622]],p),
    plot([[-.267,.267],[0,0],[.267,.267],[0,1],[-.267,.267]],p),
    plot([[.342,.536],[.355,.859],[.138,.622]],p),
    plot([[0.,.376],[0,0],[.376,0],[.705,.705],[0.,.376]],p),
    plot([[.55,.095],[.733,.236],[.49,.245]],p),
    plot([[.216,.216],[0,0],[.216,-.216],[.81,0],[.216,.216]],p),
    plot([[0,-.5],[0,0]],p),

scaling=constrained,view=[-1..1,-.75..1.25],axes=box);

 

Know other ways to plot a maple leaf in Maple?  If so, please share them below - we’d love to see them!

x dot produces x dot (t)   

How do I suppress the t in the output display?  The help page shows an Unsuppress all so I thought a Typsetting:-Suppress(all) would do it, but it throws an error message. 

Typesetting:-Suppress(x(t)) would do it but I'd prefer the option all.

I've got Maple 2017 linked to MATLAB R2017a but I can't get MATLAB R2017a linked to Maple 2017.

I've got MATLAB R2016b linked to Maple 2017.

Any ideas? (Or do I just need to wait for an update?)

hello...i have a problem with this program.

I want to save the result(y,u(y)) in a text or another format file, but I encounter with this error message:

Error, (in fprintf) number expected for floating point formatBVP.mw
 

restart:

A1:= 5.5:  n:= 0.59:  A2:= 11818.:  h0:= 0.402e-3:
L:= .1:  dpx := -11823.9:  uc:= 0.44e-2:

ODE:= (A3,y)->
   (h0^(n+1)*L/sqrt(n)*(A1*exp(sqrt(n)*y/L)-A2*exp(-sqrt(n)*y/L))+dpx*y*h0^(n+1)+A3*(h0)^n)^(1/n)
;

proc (A3, y) options operator, arrow; (h0^(n+1)*L*(A1*exp(sqrt(n)*y/L)-A2*exp(-sqrt(n)*y/L))/sqrt(n)+dpx*y*h0^(n+1)+A3*h0^n)^(1/n) end proc

(1)

ODEINT:= proc(A3)
option remember;
local y;
   evalf(Int(ODE(A3,y), y= 0..1, epsilon= 1e-7)) - uc
end proc:

ReINT:= proc(A3x, A3y)
   Digits:= 15:
   Re(ODEINT(A3x + I*A3y))
end proc:

ImINT:= subs(Re= Im, eval(ReINT)):

Digits:= 7:
a3:= fsolve([ReINT, ImINT]);

[6.3610757968979, 0.]

(2)

A3:= Complex(a3[]);

6.3610757968979+0.*I

(3)

Solve as IVP:

Digits:= 15:
sol:= dsolve({diff(u(y),y) = ODE(A3,y), u(0)=0}, numeric, range=0..1,  output=listprocedure):

``

``

plots:-odeplot(
   sol, [[y, Re(u(y))], [y, Im(u(y))]], y= 0..1,
   legend= [real, imag], labels= [y, u(y)]
);

 

 

F53 := proc (y) options operator, arrow; U end proc; G53 := proc (y) options operator, arrow; Re(evalf[20](F53(y))) end proc; Temp3 := cat("u(y)-y.dat"); fd53 := fopen(Temp3, WRITE, TEXT); for i from 0 by 0.5e-1 to 1 do tt := i; u := eval(G53(y), y = tt); fprintf(fd53, "%10.5e %10.5e  \n", tt, u) end do; fclose(fd53)

Error, (in fprintf) number expected for floating point format

 

NULL


 

Download BVP.mw

 

please help me

thanks

I'm still quite new to maple and I'm working calculating some dynamic equations.

I want to be able to selectively group certain variables or numbers depending on how I need the equations to be showed, I don't know if that's possible, I´ll explain further.

In typewritting extended format one equation is shown like this:

 

 

And maple standard:

 

The fisrt thing I want is to show the time derivatives in the dot representation, but I also want the 1/2 multiplyting each term of the whole equation like in the maoke standard format. 

I also need to group certain variables in some other equations I have and I was wondering if there is a way to do this.

I have made a small package in a workbook and want to upload it as a package to MapleCloud. According to the help pages, I should select Save To Cloud from the File menu and select the package option for Application Type in the dialog that appears. However, no matter what I do the only option availlable is Maple. What is going on?

First 34 35 36 37 38 39 40 Page 36 of 40