## 2243 Reputation

19 years, 188 days

## Mixed statistics?...

Maple

Is it within the Physics environment possible to specify two sets, A and B, say, of quantities for which the following holds?

1.) any two elements of A anticommute,

2.) any two elements of B anticommute (as well), but

3.) any quantity from A commutes (not anticommutes) with any quantity from B.

## Physics trouble, again, or what?...

Consider the following code:

`with(LinearAlgebra):with(Physics):Setup(anticommutativeprefix = psi):psiFermi := Vector(2,symbol = psi):psiBose  := Vector(2,symbol = phi):A := Matrix([[0,1],[1,0]]):Transpose(psiFermi) . A;Transpose(psiBose ) . A;`

It produces the following output:

Why is the first line, for anticommuting components, not evaluated to the same form as the second line, for commuting components? The actual choice of the matrix A seems immaterial; the odd behaviour is present even if A is chosen to be the identity matrix!

In comparison, the 'contracted' (scalarly) expressions

`Transpose(psiFermi) . A . psiFermi,Transpose(psiBose ) . A . psiBose;`

produce the following completely sensible output:

## Problem in Physics package with multipli...

Perhaps I am being daft, but to me the Physics package seems, quite surprisingly, to have trouble multiplying by a nonzero, non-square matrix. The test code

`restart:with(Physics):Matrix(2,2,fill = 0) . Vector(2),Matrix(2,2,fill = 1) . Vector(2),Matrix(2,3,fill = 0) . Vector(3);Matrix(2,3,fill = 1) . Vector(3);`

produces the following output:

Error, (in Vector[column]) Matrix index out of range

i.e., the last expression cannot be evaluated; while the test code (where no loading of the Physics package is performed)

`restart:#with(Physics):Matrix(2,2,fill = 0) . Vector(2),Matrix(2,2,fill = 1) . Vector(2),Matrix(2,3,fill = 0) . Vector(3),Matrix(2,3,fill = 1) . Vector(3);`

produces the following expected output:

PS: To be sure, I have from http://www.maplesoft.com/products/maple/features/physicsresearch.aspx downloaded the latest version (2014, March 19, 4:0 hours) of the Physics package for Maple 17 (the version I am running).

## Forced evaluation?...

I have a procedure that takes an object, i.e. a module, as an argument. On grounds of the properties of that object, the procedure should return a certain map. But I hit a snag, the gist of which is along the following lines (just an example):

`M := module()   export dim;   dim := 2;end module:F := proc(m::`module`)   (x::Vector(m:-dim)) -> somethingend proc:`

My problem is that F(M) produces

rather than

How can I force m:-dim within F to be evaluated?

## Maple 17 freezes...

For executing a worksheet in Maple 17, I use the shortcut sequence Alt E + E + W. Once in a while I mistype this sequence, and sometimes, when doing so, it causes the worksheet to hang or freeze. Then it seems possible to terminate Maple only by killing it in the Windows Job List (Ctrl + Alt + Delete), where, by the way, the program still figures as running.

Until now I have not been able to track down what exact (wrong) key sequence of mine it is that triggers this unfortunate behaviour. Although weird if actually so, perhaps it also depends on the present state/history of the actual worksheet, I cannot tell for sure. Talking against that, though, is the fact that the behaviour has been found in different worksheets of mine, also very simple ones.

Has anyone had similar experiences with Maple hanging or freezing this way?

 First 7 8 9 10 11 12 Page 9 of 12
﻿