das1404

135 Reputation

6 Badges

12 years, 219 days

MaplePrimes Activity


These are questions asked by das1404

I have a statement:

print(plots[display](seq(colr2[i],i=1..numplayers, xtickmarks=0,axes=NONE,view=[0..5*numplayers,0..1])):

which outputs a horizontal display of the various "colors" of the players, and it does so.

    However, the height of the output is quite big and makes the output look "chunky".  Inserting the option "scaling=constrained" makes the width of the output much narrower - but there is a bounding box of the output (which is not actually displayed.)  It is displayed when the mouse cursor is clicked on the display.  I was hoping the view= [..] option would provide a solution, but this does not alter the exterior bounding rectangle.

  Is there any means of modifying the dimensions of the rectangular display through Maple code?

Thanks,

   David

 

I recently downloaded a Maple reader software program from

http://www.crystaloffice.com/

I'mpuzzled as I'm not sure if this has anything to do with the Maple mathematics software,  On cursory observation it just looks like a text editor.

  I was curious to know if there was any software available which would allow people to read & execute a Maple program on the Internet. 

Cheers

   David

 

The "program" below includes a readline statement.  This does not clear the former output when run again.  Is there any modification to correct this?

David

 

restart;
 with(plots):
 with(plottools):
 #f:=proc()
 #local c, numplayers:
 #numplayers:=4:
 #c:= rectangle([0,0], [11,11], color=red):
 #plots[display](c, scaling=constrained, view=[-0.8..11.5,-0.8..12],axes=BOXED);
 printf("Enter the number of players:\n");
 numplayers:=readline(terminal):
 printf("Number of players is %s\n",numplayers);
 #printf("Number of players is %d\n",numplayers);
 #return "foo";
 #end proc:
 #f();

Short question version:

print(plots[display](seq(seq...   ...)):  works fine!  Why??

Longer, more detailed question:
  print(plots[display](seq(seq...   ...)):   This Maple statement ends in a colon - so I would not have expected any output.  I'm using "pretty" print, as opposed to printf, because it automatically centers the output

    This question is actually an extension of one I posed  yesterday, under the title "How to clear Maple output" - but the question I should have been asking is: "Why is the previous output not automatically cleared?"  The main points of that question are stated below.  Any comments, suggestions gratefully received.

   David

"How to clear Maple output"

I'd like to know how the screen previous ouput can be cleared.   ...or what is the likely cause.

   At the start of my program I have:

restart;
interface(echo=0, verboseproc=0, warnlevel=0, prettyprint=1):

#I thought restart; would automatically have cleared any previous output.

The program reads necessary input (eg no of players, ..)  using:

x:=readline(terminal):

I have written a program which plays the game of Multicube, a commercially made boardgame. It works OK except that when the game is replayed, the previous game output stays on the screen.  This is rather distracting and I'd like the screen cleared when a new game is run.   I'd like to know how the screen previous ouput can be cleared.   ...or what is the likely cause.

   At the start of my program I have:

restart;
interface(echo=0, verboseproc=0, warnlevel=0, prettyprint=1):

#I thought restart; would automatically have cleared any previous output.

The program reads necessary input (eg no of players, ..)  using:

x:=readline(terminal):

 

Thanks,  David

 

 

First 8 9 10 11 Page 10 of 11