MaplePrimes Questions

I was curious to know if one can extract a specific solution from a LPSolve routine. 

As an example, consider the following output to a constrained linear problem. The objective value is 8 and the decision variable values (binary) are given.

Sol := [8, [w[1, 1] = 1., x[0, 0, 1] = 0, x[0, 1, 1] = 1, x[0, 2, 1] = 0, x[1, 0, 1] = 0, x[1, 1, 1] = 0, x[1, 2, 1] = 1, x[2, 0, 1] = 0, x[2, 1, 1] = 0, x[2, 2, 1] = 0, y[0, 0] = 0., y[0, 1] = 0., y[1, 1] = 2.]]

I am interested to know if we can isolate any variable value from this solution. I know that Sol[1] will return 8, and Sol[2] will return the remaining terms. But what if I wanted, say, x[1,2,1] alone?

Thanks for reading!

A bit of an annoyance. 

typing 'numerator' / 'denominator' generates an error.  The first quote never gets automatically grouped as it should.

Two workarounds.  The first is to move to, and delete the first quote and re-enter it again in front of numerator.
The second is to use brackets, although one shouldn't have to.

Hi

I have this problem that my computer crashed during Maple 2016.1 to 2016.2 update.

Now it won't start at all.

I have tried reinstalling Maple several times, tried not updating to 2016.1 and running the program as vesion 2016.0.

I get this error in my eventlog, when I try to run the program.

Name of program errors: javaw.exe, version: 8.0.1020.14, timestamp: 0x576af3f4
Name of the module with error: nvSCPAPI64.dll, version: 7.17.13.7849, timestamp: 0x588218a5
Exception code: 0xc0000409
Displacement by mistake 0x0000000000034b2f
Process ID 0x166c
The program's start time 0x01d279add4515202
Program path: E: \ School Program Files \ Maple 2016 \ jre \ bin \ javaw.exe
Module path: C: \ Program Files (x86) \ NVIDIA Corporation \ 3D Vision \ nvSCPAPI64.dll
Report ID: d52f952d-8fd2-4130-890a-196e6a7bdc92
Full name of the program with the error:
Relatively application ID for program errors:

So as my titel suggests I need help to remove all files associated with Maple so I can install the program anew. It has worked fine for over a year so far. Only stopped working after that crash.

I have even tried installing the older version, Maple 2015 and it doesn't work either, so I am guessing the files which are corrupted aren't removed during a normal uninstall process, and they are shared among the versions of the program.

Thanks in advance :)

Hi everybody, 

The sequence 
    writeto(MyFile)
    showstat(Myproc)

keeps printing the result on the screen

How is it possible to redirected the output of showstat(Myproc) into a file ?

Thanks in advance

Hello,

I've just started to use Maple 16, and I can't seem to get a neat result, when I use the solve function to solve 4 equations with 4 unknown constants.

I've posted my calculations.

 

How can I get a simpler result? I found a simplification command, but that didn't help

Where I made a mistake I got this error in for loop and how to fix it?


 

restart

Error, invalid input: with expects its 1st argument, pname, to be of type {`module`, package}, but received shareman

 

N := 5:

c__1 := Matrix([[c1__11, c1__12, 0], [c1__12, c1__22, 0], [0, 0, c1__66]]):

c__2 := Matrix([[c2__11, c2__12, 0], [c2__12, c2__22, 0], [0, 0, c2__66]]):

c__3 := Matrix([[c3__11, c3__12, 0], [c3__12, c3__22, 0], [0, 0, c3__66]]):

c__4 := Matrix([[c4__11, c4__12, 0], [c4__12, c4__22, 0], [0, 0, c4__66]]):

c__5 := Matrix([[c5__11, c5__12, 0], [c5__12, c5__22, 0], [0, 0, c5__66]]):

NULL

Q := Array(1 .. 3, 1 .. 3, 1 .. N):

A := Matrix([[0, 0, 0], [0, 0, 0], [0, 0, 0]]):

Z := Matrix([[h__1], [h__2], [h__3], [h__4], [h__5], [h__6]]):

for ii to 3 do for jj to 3 do Q(ii, jj, 1) := c__1(ii, jj); Q(ii, jj, 2) := c__2(ii, jj); Q(ii, jj, 3) := c__3(ii, jj); Q(ii, jj, 4) := c__4(ii, jj); Q(ii, jj, 5) := c__5(ii, jj) end do end do

"for i from 1  to 3 do for j from 1 to 3 do Ar:=0:for k from 1 to N do  Ar:=(Q (i,j,k)*(Z(k+1)-Z(k)))+Ar: end do A(i,j):=Ar: end do end do"

Error, invalid loop statement termination

"for i from 1  to 3 do for j from 1 to 3 do Ar:=0:for k from 1 to N do Ar:=(Q (i,j,k)*(Z(k+1)-Z(k)))+Ar: end do A(i,j):=Ar: end do end do"

 

``

``


 

Download quest.mw

Is there a problem with MaplePrime web site?   All my questions for the last 4 years, and answers are no longer available. All gone. I posted a question early today about sin(x) calling. one hr after that, I noticed all my questions and answers gone.

When I go to my user profile, it says I have zero questions, zero answer and zero post for the last 4 years. All the answers to my questions also got deleted, which is a shame if this happened. They have many useful information.

Any one else affected by this?

 

 I need help regarding this figure. i want to write both equations in maple 18. Second equation is related to first equation.So, please help me to write this code. I will be grateful. 

 

 

I have a need to calculate base 2 math as would be done in an integrated circuit. Math will be done using 15 bit 2's complement mantissa and 8 bit exponent. (the exponent is always assumed to be negative) We need to perform multiplication and addition, where each internal operation is represented by such a number.

The goal is to best represent the errors associated with such calculations and export the resulting code to a hardware description language for implementation on an integrated circuit.

Is there a package in Maple that can do that? Any advice on how te proceed?

How to do for to built animation Cylinder inscribed in cone?( in optimization problem)

I'm trying to plot the velocity of a ball thrown upwards with air resistance proportional to v^2 and also some simpler forms of this.

But the solution to v^2 returns root of and the plot stops for some specific time value. How can I proceed this plot to let's say 10 sec?

Staffan


 

``

``

restart

``

deq1 := m*(diff(v(t), t)) = -m*g:

``

sol := dsolve({deq1, v(0) = v__0}, v(t))

v(t) = -g*t+v__0

(1)

V := unapply(rhs(sol), t):

``

``

``

deq2 := m*(diff(v2(t), t)) = -m*g-k*v2(t):

``

sol2 := dsolve({deq2, v2(0) = v__0}, v2(t))

v2(t) = -g*m/k+exp(-k*t/m)*(v__0+g*m/k)

(2)

V2 := unapply(rhs(sol2), t):

``

deq3 := m*(diff(v3(t), t)) = -m*g-k*v3(t)*abs(v3(t))

m*(diff(v3(t), t)) = -m*g-k*v3(t)*abs(v3(t))

(3)

sol3 := dsolve({deq3, v3(0) = v__0}, v3(t))

v3(t) = RootOf(t+m*piecewise(_Z <= 0, arctanh(k*_Z/(k*m*g)^(1/2))/(k*m*g)^(1/2), 0 < _Z, arctan(k*_Z/(k*m*g)^(1/2))/(k*m*g)^(1/2))-m*piecewise(v__0 <= 0, arctanh(k*v__0/(k*m*g)^(1/2))/(k*m*g)^(1/2), 0 < v__0, arctan(k*v__0/(k*m*g)^(1/2))/(k*m*g)^(1/2)))

(4)

V3 := unapply(rhs(sol3), t):

``

m := 0.258e-2:

``

plot([V(t), V2(t), V3(t)], t = 0 .. 5, color = [blue, red, black], gridlines = true)

 

``


 

Download tal_3.9_sid_66_b.mw

for the simple ODE:

dsolve(26*(diff(y(x), x$4))-50*(diff(y(x),x$2))-2*y(x) = 0)

dsolve produces strange solution as below:

in this solution the forth function is wrong and it would be as below:

_C4*exp((1/26*I)*sqrt(26*sqrt(677)-650)*x)

can you explain this problem???

please help me :((((

Dear all,

 

Is there any way to fill the upper region in plot3d?

e.g. if I put the filled option in 

plot3d(y^3+x^2, x = 0 .. 1, y = -1 .. 1, filled)

then the region between the x-y plane and my plot will be filled. What if I want to fill the upper region?

The reason is that I want to show the upper region is acceptable for me, but I couldn't find any other way. 

If you have any solutions for me, I appreciate it.

Hi,

I am a maths teacher and would like to create an ebook for my students with explanations, examples and quizes in the same time. They should be able to access and work through it, even on mobile devices, using the free Maple player. I am new in Maple and don't know if all this is possible. I would like to see some samples of code to learn from and of course, some advice. I would highly apprecaite your support. Thank you.

One of the things I like about Maple, is that I am able to look at most of the source code, and learn from it. But since I am newbie in Maple, sometimes I find it hard to know which next call I need to showstat() in order to see what happens next and follow the code.

Sometimes I do not know how to find the proc() being called in the listing shown by showstat().

For an example, I wanted to see how Maple implements AiryAi(x).

So I did  showstat(`AiryAi`) and I see the listing of AiryAi. The top level of the function. But then I see it calling, which must be some other level of `AiryAi` function? For example, at line 16, it says

     res := ('AiryAi')(x)

Since I am looking at AiryAi itself, this must be either recursive call or calling other internal AiryAi?

But if it recursive, then I do not see where the actual implementation is? I wanted to see if it uses the integral form of AiryAi or series form (not likely, uses GAMMA). I see the same recursive call in many places, such as line 35 and line 37 and othere places.

But looking at all the 42 lines, I do not see where the actual calculation of AiryAi(x) is done. Did I miss it?

There is a lot of error checking and looking at special cases and such. But how does one know from looking at this listing, which other function they need to showstat() in order to see the actual implementation? There must be more to it than those 42 lines?

This is on Maple 2016.2

 

First 1016 1017 1018 1019 1020 1021 1022 Last Page 1018 of 2428