Items tagged with pattern




I am having trouble getting a pattern match to the Heaviside function.

patmatch(Heaviside(x), Heaviside(a::algebraic))

returns "false" whereas I would expect it to return true.

On the other hand:

patmatch(Heaviside(x), Heaviside(x::algebraic))

returns true.


What am I missing?





I have use a sparsematrixplot to identify the patterns in a matrix.

In order to facilitate the readability of my sparsematrixplot, i would like to change the labels of the rows/ columns axis.

Instead of the numeric graduation, i would like to add :

- for my rows, the labels : [eq1,eq2, ..., ]
- for my columns, the labels : [q1,q2,q3,...,]

Do you have ideas how I can do that ?

Thank you for your help


let m3 = [[0; 1; 0]; [1; 0; 1]; [0; 1; 0]]

1. Firstly, express this matrix into sequence function expression

2. how to express this matrix in terms of forloop code

3. for complicated case such as 1 is not in easy pattern, can it intelligently express the matrix in terms of for loop code


is there exist extra tools to express matrix in terms of for loop code or sequence function code?

Hello!  I am writing a Grassmann multiplication operator:

define('`&*`', 'multilinear', 'flat', 'identity' = 1)

So that it automatically constructs operators like &*(arg1, arg2,arg3 ...)

Now I want to teach Maple how to transforms &* with ARBITRARY number of arguments.

How to create a pattern for that?  (to be added to "define")

Hi everyone

I'm new to the forum, but I hope you can help me with a problem concerning import of pictures to Maple. I'm working with diffraction from a rectangular and circular aperture. I haven't made the experiment yet, but I've thought about taking some pictures of the diffraction pattern and then use Maple to calculate the intensity of the light to make a three dimensional plot (intensity as a function of position).

Right now I just want to import a picture...

I was recently asked a question on using regular expressions with ?type , and I thought it was interesting enough, to share here.


I so thankful for your help. Please help me expressing this expression compactly is there any pattern here?


The following works:

  patmatch(%,a::name*b::name +c::name,'p');

                        [a = v, b = w, c = u]
Page 1 of 1