Alec Mihailovs

Dr. Aleksandrs Mihailovs

4495 Reputation

21 Badges

20 years, 342 days
Mihailovs, Inc.
Owner, President, and CEO
Tyngsboro, Massachusetts, United States

Social Networks and Content at Maplesoft.com

Maple Application Center

I received my Ph.D. from the University of Pennsylvania in 1998 and I have been teaching since then at SUNY Oneonta for 1 year, at Shepherd University for 5 years, at Tennessee Tech for 2 years, at Lane College for 1 year, and this year I taught at the University of Massachusetts Lowell. My research interests include Representation Theory and Combinatorics.

MaplePrimes Activity


These are replies submitted by Alec Mihailovs

It's not Maple, it's some versions of Windows (ans some settings in Windows) cause problems with spaces. It works in some Windows versions, and doesn't work in others (or in the same versions, but with different settings.)

Sometimes it works inside a string, so the ssystem command should include a string inside a string, and that seems to be often causing problems in Standard, while working OK in Classic.

Alec

Yes, that's one of possibilities. And redirect the output to a text file with reading it from Maple after. Or just running qHull in a separate command window with redirecting the output to a text file. Since I have switched to Python several years ago, I don't do such things in Maple, and in Python such things are done very naturally, without any problems.

Axel, that, by the way, gives an idea of using gsl functions from Maple (in Windows), instead of recompiling it with -stdcall. The gsl functions can be called in a Python script (using ctypes) - it's very simple, much more simple than Maple's external calling. And that Python script can be used from Maple through ssystem.

Alec

Yes, that's one of possibilities. And redirect the output to a text file with reading it from Maple after. Or just running qHull in a separate command window with redirecting the output to a text file. Since I have switched to Python several years ago, I don't do such things in Maple, and in Python such things are done very naturally, without any problems.

Axel, that, by the way, gives an idea of using gsl functions from Maple (in Windows), instead of recompiling it with -stdcall. The gsl functions can be called in a Python script (using ctypes) - it's very simple, much more simple than Maple's external calling. And that Python script can be used from Maple through ssystem.

Alec

Something like that (with sequences instead of lists), can be done in a loop,

for i to LinearAlgebra:-ColumnDimension(A) do 
    if assigned(T[A[1,i]]) then 
        T[A[1,i]]:=T[A[1,i]],A[2,i] 
    else T[A[1,i]]:=A[2,i] 
    fi
od;

T[B];

                                0, 21

With lists, there is a slight problem in case if the elements of the second row may be lists, too.

This way the same value may be repeated several times in T[x]. To avoid that, sets can be used instead of sequences, with possible set with 1 element conversion to that element.

Alec

Something like that (with sequences instead of lists), can be done in a loop,

for i to LinearAlgebra:-ColumnDimension(A) do 
    if assigned(T[A[1,i]]) then 
        T[A[1,i]]:=T[A[1,i]],A[2,i] 
    else T[A[1,i]]:=A[2,i] 
    fi
od;

T[B];

                                0, 21

With lists, there is a slight problem in case if the elements of the second row may be lists, too.

This way the same value may be repeated several times in T[x]. To avoid that, sets can be used instead of sequences, with possible set with 1 element conversion to that element.

Alec

If you want to see the content of a 2×24 matrix, it can be done by setting

interface(rtablesize=25):

Alec

If you want to see the content of a 2×24 matrix, it can be done by setting

interface(rtablesize=25):

Alec

While I have a master degree, too, but I also have a PhD degree, so the Dr. Alec would be more appropriate, I think.

Thinking about that, I've noticed that my Maple prompt is set to

Yes, Master?

instead of >. That's why I don't copy >s here in the Maple code. So Maple is calling me a Master, too. Should I change it to a Dr. or a Sir? I'll have to think about that.

Alec

Still, I am not available.

Alec

But why would anybody want to do that?

Alec

But why would anybody want to do that?

Alec

I looked at the source of DeleteColumn

showstat(LinearAlgebra:-LA_Main:-DeleteColumn);

and noticed it there, then looked at its source, too.

Alec

PS The undocumented LinearAlgebra commands can be seen as

{exports(LinearAlgebra)} minus {LinearAlgebra:-_pexports()[]};

  {CheckFloat, QueryType, Simplify, StdOptions, _pexports,

        DeduceNormalizer, ComplementaryIndices}

The order in which they are listed, is not lexicographical - isn't that interesting? -Alec

I looked at the source of DeleteColumn

showstat(LinearAlgebra:-LA_Main:-DeleteColumn);

and noticed it there, then looked at its source, too.

Alec

PS The undocumented LinearAlgebra commands can be seen as

{exports(LinearAlgebra)} minus {LinearAlgebra:-_pexports()[]};

  {CheckFloat, QueryType, Simplify, StdOptions, _pexports,

        DeduceNormalizer, ComplementaryIndices}

The order in which they are listed, is not lexicographical - isn't that interesting? -Alec

The first one should work in Maple 9.5 (if I remember correctly - I have it installed somewhere, so I'll check that later.) The second one should work with replacing .. with either 1..4, or 1..-1. Also, if the first one still doesn't work, it should work as M[2,1..3] or M[2,1..-1].

Alec

The first one should work in Maple 9.5 (if I remember correctly - I have it installed somewhere, so I'll check that later.) The second one should work with replacing .. with either 1..4, or 1..-1. Also, if the first one still doesn't work, it should work as M[2,1..3] or M[2,1..-1].

Alec

First 53 54 55 56 57 58 59 Last Page 55 of 180