MaplePrimes Posts

MaplePrimes Posts are for sharing your experiences, techniques and opinions about Maple, MapleSim and related products, as well as general interests in math and computing.

Latest Post
  • Latest Posts Feed
  • I just received and installed Maple 11.  (Maplesoft wouldn't sell me the student version, but I learned they have an unadvertised Home User version which is reasonable.  You have to call on the phone to order it.)  So far it's working well, but I can't figure out how to get an exact (symbolic) solution to a quartic with integer coefficients.

    Of all the ways to decompose a numerical (floating point) matrix, my favorite is the singular value decomposition (SVD).  There are a lot of applications of the SVD (see my dissertation for one related to polynomial algebra) but my favorite ones are probably two applications related to image processing.

    The first one I want to talk about comes from the cover of James Demmel's book "Applied Numerical Linear Algebra": image compression.  This example gives a really cool intuitive understanding of the Rank of Matrix and is also nice excuse to play with Maple's ImageTools package.

    So, the first thing you need a test image. I used the classic image compression benchmark of a Mandrill.



    Read this in with:


    mandrill:=ImageTools:-Read("4.2.03.tiff");


    The result is a 512x512x3 array.  In order to do something with this, we need to make it into a matrix so, call


    manmat:=convert(ArrayTools:-Reshape(mandrill, 512*3, 512), Matrix);


    Now we can compute a singular value decomposition of the image:


    (U, S, V) := LinearAlgebra:-SingularValues(manmat, output = ['U', 'S', 'Vt']);

    Now we can zero-out small singular values and multiply things back together to create low-rank approximations of the matrix that are also compressed versions of the image.
    Rank 32 will give us 1/8 of the data (64 dimension 512 vectors: 32 rows of U, 32 columns of V, and the 32 corresponding singular values) but still a pretty good image:


    rank32approx:=MatrixMatrixMultiply(`.`(U, DiagonalMatrix(S[1..32], 3*512, 512)), V, outputoptions = [order = C_order]);


    This reshape it back to an image and display:


    Preview((Reshape(rank32approx, 512, 512, 3)));


    Taking things down to rank 8, is leaving only 1/32 of the data, but it is amazing how what is left resembles the original image:


    rank8approx:=MatrixMatrixMultiply(`.`(U, DiagonalMatrix(S[1..8], 3*512, 512)), V, outputoptions = [order = C_order]);
    Preview((Reshape(rank8approx, 512, 512, 3)));


    To look at more images in order of descending rank, take a look at my worksheet:
    Download 5480_SVD-face-colour-improved.mw
    View file details

    Next time: eigenfaces

    A colleague showed this to me earlier this afternoon. I can explain, and accept, most of Maple's responses. I do have one case where I believe Maple could do better.

    This arose during the creation of some Maple materials to support the derivation of the Integral Test for series convergence. Consider:

    restart;
    I1 := Int( 1/x^p, x=1..infinity );
                                    /infinity      
                                   |          1    
                                   |          -- dx
                                   |           p   
                                  /1          x    
    

    The time for Easter eggs will soon be here.

    And using LibraryTools to browse and poke about in Maple's .mla files can show a few undocumented items.

    Here's one below, that's an interesting part of a package.

    I would like Maple to assist me with the following definite double integral:

    int(int(x/(x^2+y^2+z^2)^(3/2), y = -b .. b), z = c .. a+c)

    so far, I have failed.  Can anybody help?

    Here is my worksheet:

    View 4937_Page92.mw on MapleNet or Download 4937_Page92.mw
    View file details

    I'm asking Maple for simple things only, yet still (5 years later) I get nothing.

    I'm creating 3 contour plots for potential functions in 3 bordering regions of 3-space,

    because a continuous potential function isn't possible to define. 

    After an entire worksheet worth of variable definitions and series expansions, i say simply:

     

    CPA:=contourplot3d(VI(a,b,c,d,e)......)

    CPB:=contourplot3d(VII(a,b,c,d,e)......)

    CPC:=contourplot3d(VIII(a,b,c,d,e).......)

     

    Does anyone here use this?

    Would it be useful for someone new to topology/homological algebra learning wise ?

    comments/opinions very welcomed.

    thanks,

    dc

    http://wwwb.math.rwth-aachen.de/homalg/

    Why is the following function such a problem to differentiate?

    A := 1/(8*cos(`θ`)*(sin(`θ`))(sin(`θ`)+cos(`θ`))^2)

    Here is a worksheet:

    View 4937_page84.mw on MapleNet or Download 4937_page84.mw
    View file details

    I posed an integration problem and Maple solved it so easily I decided I would like to get Maple.  I'm waiting to hear whether Maplesoft will sell me the student version.  While I'm waiting, I would like to ask this group a question I've always had about systems like Maple.  I will start by posing a problem:

    Let C be a unit circle and let P be a point on C.  Draw a bigger circle B with P as center which crosses C at two diametrically opposed points of C.  What is the area of the crescent-shaped region inside C and outside B?

    Hello Everyone:

     

    The e-mail notification feature that was previously available before the last update to the site has been re-enabled.

    Please post any issues with this feature as comments on this blog entry. If you have comments about any other features, please add them to the MaplePrimes Suggestions forum

    I used to receive emails each time when a comment/reply was made to my questions on mapleprimes. Very convenient. Now this service either stopped to exist or something else, as I receive nothing. Can it be resumed somehow? Thanks.

    I am thinking about buying Maple, but I would like to know how it does with the following problem:

    f(x):=log(2-cos(x)+sqrt(3+cos(x)*(cos(x)-4))) ;
    r(n,p):=(1/%pi)*integrate((1-exp(-abs(n)*f(x))*cos(p*x))/sinh(f(x)),x,0,%pi) ;
    r(1,3) ;


    These are Maxima commands--let me know if it is not clear what they are doing.  I am wondering if someone with Maple could translate these commands into Maple-ese and try them. (Maxima just gives up on this integral.)

    The following give very different answers.

    > evalf( int( ln(2+2*cos(t)^2+cos(t)^4), t = 0 .. Pi));

       -8.710344354+19.73920881*I;


    > evalf( Int( ln(2+2*cos(t)^2+cos(t)^4), t = 0 .. Pi));

     

    Hello to All,

    I am just in testing process of new version Mechanics of Materials 2.0 ToolBox.

    Some of Maple pictures are so good that I decided to put here one from them.

    What a great Maple...

    Sorry for my some immodesty...

     

     

    First 206 207 208 209 210 211 212 Last Page 208 of 307