Carl Love

Carl Love

28055 Reputation

25 Badges

12 years, 359 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

@nm 

So, the semantics of Pi and pi are identical in Maple and Mathematica. The only difference is how they are treated by the help system. I think that there needs to be a help page ?pi because using pi when one means Pi is one of the most common newbie errors. The same is probably true for Mathematica newbies.

@mobosmobos 

Please let me know how it goes.

@Carl Love 

I am surprised that the above Answer has not attracted more attention. This failure to follow the McCarthy rules is a serious and AFAIK undocumented problem. Even worse, I just discovered that (at least in Maple 16) when using 2D input infix logical operators are always translated to prefix form and thus the McCarthy rules cannot be used in 2D input! For the OP, that means that the code cannot be run in 2D input: You will need to switch to 1D input, which many of us on MaplePrimes would recommend anyway.

You can also get around this by recoding your logical expression to use the `if` operator, like this:

if ST:-IsPrefix(y, x) and
     `if`(assigned(P[x]), ST:-IsPrefix(P[x], y), true)
then
     P[x]:= y
end if

@tomleslie 

Why is the coefficient 20, not 10?

@Markiyan Hirnyk 

Thanks for spotting that. I corrected the Answer.

Your code runs in Maple 16 without error. I don't have access to Maple 18 right now to compare.

@DJJerome1976 

Simply using the assumption a+b=d+c is enough to make the eigenvalues c+d and a-c. The integer assumption is not necessary.

What type of simplification do you imagine is possible using the integer assumptions?

@ 

I already used continuation to overcome an "Initial Newton iteration not converging" error. Continuation does not help with the general "Newton iteration not converging." In a few hours I'll post the worksheet for the BVP.

You asked the same question on Oct 22, 2014. I tried solving it with Maple then, and it failed with "Newton iteration is not converging."

To solve the problem, you need to assume that the ground makes a right angle with the wall and that the ground stays level for the 9 feet out to the base of the ladder. It's not a very realistic assumption because the ground usually slopes away from a wall for drainage, but I know that a right angle is what the problem's author intended.

@Rocket 

switches:= proc(sq::list(identical(0,1)))
local switches:= 0, k;
     for k to numelems(sq)-1 do
          if sq[k] <> sq[k+1]then
               switches:= switches+1
          end if
     end do;
     switches
end proc:

L:= combinat:-permute([1$2, 0$2]);

switches(L[4]);

     2

switches ~ (L);

ListTools:-Classify(switches, L);

@acer

Also, you made explicit the implied multiplication "3 y" in the definition of f.

@mohitgupta1993 

Your partial derivative symbol is being treated as a variable in its own right rather than as an operator. I don't know why. But you can get around this problem by explicitly typing diff rather than relying on menus and palettes. For example, diff(W(x,y), x, x).

@Markiyan Hirnyk 

It's utterly obvious if you read showstat(Matrix)! But I'll humor you anyway.

P:= proc(n::posint)
     to n do
          rtable(1..2, 1..2, storage= triangular[lower], subtype= Matrix)
     end do
end proc:

Q:= proc(n::posint)
     to n do
          Matrix(2, shape= triangular[lower])
     end do
end proc:

CodeTools:-Usage(P(100000)):

memory used=16.79MiB, alloc change=0 bytes, cpu time=187.00ms, real time=199.00ms

CodeTools:-Usage(Q(100000)):

memory used=0.58GiB, alloc change=32.00MiB, cpu time=8.75s, real time=8.86s

First 518 519 520 521 522 523 524 Last Page 520 of 709