Christopher2222

MaplePrimes Activity


These are replies submitted by Christopher2222

Yes, thanks that helps, but more generally, keeping with the distribution=uniform syntax in the ArrayTools[RandomArray] call, how would one go about changing the way the call to distribution=uniform outside the unit interval?

Using showstat(ArrayTools[RandomArray]) on lines 15,18 and 28 I suppose I could alter the numbers for normal there, can't I?  and also maybe line 10 is all I need to change for uniform, I think. Can they be changed?  Of course not recommending the change to main command programming (if it's possible?), is there a way to bypass the call instead?  I believe something similar was done with another command, but I can't recall, which leads me to my last question.

Even more general still, for any command can we substitute some options calls with our own modified version (not to replace but just to override)? 

Yes, thanks that helps, but more generally, keeping with the distribution=uniform syntax in the ArrayTools[RandomArray] call, how would one go about changing the way the call to distribution=uniform outside the unit interval?

Using showstat(ArrayTools[RandomArray]) on lines 15,18 and 28 I suppose I could alter the numbers for normal there, can't I?  and also maybe line 10 is all I need to change for uniform, I think. Can they be changed?  Of course not recommending the change to main command programming (if it's possible?), is there a way to bypass the call instead?  I believe something similar was done with another command, but I can't recall, which leads me to my last question.

Even more general still, for any command can we substitute some options calls with our own modified version (not to replace but just to override)? 

Okay now, I got it.

x:=map(Re,x):

ScatterPlot(t,x,symbol=point)

Okay now, I got it.

x:=map(Re,x):

ScatterPlot(t,x,symbol=point)

I'm unable to complete your code to get it to plot right.  In your first example, the best I can do for any output is something like this:

complexplot(convert(x, list), style = point)   

I'm missing t in the plot and can't figure it out. 

I'm unable to complete your code to get it to plot right.  In your first example, the best I can do for any output is something like this:

complexplot(convert(x, list), style = point)   

I'm missing t in the plot and can't figure it out. 

@pagan I have a bad habit of initially building code with lists in loops. 

I probably should have done it more like this

a := table():
i := 1:
while i < 100 do
   ba := (rand(-15 .. 15))():
   bb := (rand(-15 .. 15))():
   b := evalf(sqrt(ba^2+bb^2)):
   if b <= 15 and b >= 10 then a[i] := [ba, bb]:  i := i+1:  end if:
end do:
plots:-pointplot(convert(a,list));

@pagan I have a bad habit of initially building code with lists in loops. 

I probably should have done it more like this

a := table():
i := 1:
while i < 100 do
   ba := (rand(-15 .. 15))():
   bb := (rand(-15 .. 15))():
   b := evalf(sqrt(ba^2+bb^2)):
   if b <= 15 and b >= 10 then a[i] := [ba, bb]:  i := i+1:  end if:
end do:
plots:-pointplot(convert(a,list));

ScatterPlot, I see is the example I wanted. 

How about a scatterplot around the circle x^2+y^2=5^2 ?

ScatterPlot, I see is the example I wanted. 

How about a scatterplot around the circle x^2+y^2=5^2 ?

I'll provide more info as it might be lacking.  Produce a graph of points that will have a probability that they will most likely fall onto a sin(x) curve

Maybe a picture of a few thousand points will better help the meaning. 

Ah, the tricks of the trade.  Thanks

Ah, the tricks of the trade.  Thanks

Option to select which axes contains the labels in 3d style=boxed mode

During manual rotation of a plot style=box, the labels of the axes switches around (front to back, top to bottom, left to right) depending on how the graph is orientated. 

I would like the option to anchor the axis, say for example at the origin 0,0,0.  Pehaps an anchor axes option.  And even also have the option to specify where I want the labelled axes to stay ie. have the x axis labels be displayed on the upper y and lower z boundary axis (sorry if I'm mixing up the axis / axes but I think you get the idea).

Let's even go so far as to make a syntax suggestion.  Something like:

plot3d(x^2,axis=(anchor=true,axislocation=[[uppery,upperz],[lowerx,upperz],default]))

#anchor=false is default but plot is created as specified if axislocation values exist.

Or even add the option to something that already exists say  axis1 =[location=[uppery,lowerz],anchor=true]
in the case 2 axis are specified then axis1,2 = [location = [[uppery,upperz],[lowerx,lowerz]],anchor=true]

Well, my syntax suggestions might be a bad idea, but I think the general idea of being able to stop the labelled axes from jumping around has been brought up before.

Dennis Ritchie wrote a great C programming language book which a lot of programmers still use as an excellent reference.  Co-authored with Brian Kernighan -  The C programming Language second edition, it was and still is a valuable resource for programming in C.  I am sure some Maple users already own a copy.

 

First 104 105 106 107 108 109 110 Last Page 106 of 155