Tampilkan postingan dengan label color. Tampilkan semua postingan
Tampilkan postingan dengan label color. Tampilkan semua postingan

Casio fx-CG 50: Random Walk Histogram

Casio fx-CG 50:  Random Walk Histogram


Mosquitos an Inspiration, What? 


Inspiration:  

Ellenberg, Jordan.   Shape:  The Hidden Geometry of Information, Biology, Strategy, Democracy, and Everything Else  Penguin Books:  New York, NY. 2021


The beginning of Chapter 4, Sir Ronald Ross proposes the problem:  In a simple case, a mosquito can only travel in one of two directions, which is northeast or southwest.   The goal was to find the average distance a mosquito is from its home after a given life span.


The program TWALK would address a similar problem.  


N = number of trials


S = number of steps the mosquito (or whatever you want to imagine) walks in a single direction


Each trial calculates the final position.  The program draws a histogram of all the trails.   


TWALK gives two choices:


(-1, 1):  Each turn, the mosquito must move forward 1 step or backward 1 step


(-1, 0, 1):  Each turn, the mosquito must either move forward 1 step, move backward 1 step, or stay still for one turn. 



Drawing an Histogram Program in Casio Programming


Syntax:


S-Grph#  DrawOn, Hist, List x, 1, [ColorLinkOff], [Color] ColorLighter


# = Graph 1, 2, 3

List x = List 1 to List 26

Color Commands:  ColorLinkOff, 

Colors: One of 8 eight colors

ColorLighter: the fill of the color is lighter than the bar


The color commands are optional.  If you are using a Casio fx-9750GIII, leave of the color commands.



Casio fx-CG50 Program TWALK


Text:

'ProgramMode:RUN

"EWS 2022-08-04"

"RANDOM WALK 2.0"

"NO. TRIALS"?->N

N->Dim List 26

"NO. STEPS"?->S

Menu "STEPS","_(-)_1,1",2,"-1,0,1",3

Lbl 2:2->F:Goto 1

Lbl 3:3->F:Goto 1

Lbl 1

For 1->I To N

F=2=>Sum (2*RanInt#(0,1,S)-1)->List 26[I]

F=3=>Sum (RanInt#((-)1,1,S))->List 26[I]

Next

"POSITIONS LIST:"Disps

List 26Disps

(-)S->H Start

1->H pitch

S-Gph1 DrawOn,Hist,List 26,1,ColorLinkOff,Blue ColorLighter 

DrawStat



On the Screen:

"EWS 2022-08-04"

"RANDOM WALK 2.0"

"NO. TRIALS"?→N

N→Dim List 26

"NO. STEPS"?→S

Menu "STEPS","-1,1",2,"-1,0,1",3

Lbl 2:2→F:Goto 1

Lbl 3:3→F:Goto 1

Lbl 1

For 1->I To N

F=2⇒Sum (2×RanInt#(0,1,S)-1)→List 26[I]

F=3⇒Sum (RanInt#(-1,1,S))→List 26[I]

Next

"POSITIONS LIST:"◢

List 26◢

-S->H Start

1->H pitch

S-Gph1 DrawOn,Hist,List 26,1,ColorLinkOff,Blue ColorLighter 

DrawStat


Examples


N = 50, S = 5


(-1, 1):  Mosquito cannot rest





(-1, 0, 1): Mosquito can rest






Wishing you an excellent day,


Eddie 


All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


Numworks: Version 19.2 Is Available

Numworks:  Version 19.2 Is Available


19.2 Is Here

The full upgrade to software 19.2 is for Numworks N0110 and N0120 models.  Only some of the features will be available for the oldest version N0100. 

How do I know which version I have?  

1.  Press the Yellow Home button.

2.  Go down to Settings and press [ EXE ]

3.  Go down to the last option in the menu, About, and press [ → ]. 

4.  You will see the Software Version.  The last five characters of the FCC ID will tell you what model of Numworks you have.


To update your calculator, just open a browser like Google Chrome, plug in your calculator, go to the numworks.com website.  


Features

Some of the features of 19.2 are (from the Numworks page):


*  The Statistics App now offers four plots: Histogram, Boxplot, Cumulative Frequencies, Normal Probability Plot

*  Median-Median and Exponential regressions are added.

*  Lists are now available everywhere, including the main Calculation app.   List elements are accessed by using the parenthesis (example:  list(1)).  Unlike Python, the first element is designated as element 1.

*  Plots in the Grapher app can be set to any one of seven colors of the user's choosing.

*  Significant tests now include a graphical result in the Inference App

*  The memory for the Python app is increased from 32,000 to 42,000 bytes

*  In the Application menu, each of the apps are assigned to a shortcut key as follows:

1:  Calculation

2:  Grapher

3:  Solver

4:  Statistics (one variable stats)

5:  Regression (two variable stats)

6:  Inference

7:  Sequences

8:  Python

9:  Settings


More information here:  https://www.numworks.com/calculator/update/version-19/


Eddie 

All original content copyright, © 2011-2022.  Edward Shore.   Unauthorized use and/or unauthorized distribution for commercial purposes without express and written permission from the author is strictly prohibited.  This blog entry may be distributed for noncommercial purposes, provided that full credit is given to the author. 


Backlink 9999 Traffic Super

Order Now...!!!!