SlideShare a Scribd company logo
1 of 14
body {
text-align: center;
font-family: sans-serif;
}
canvas {
background-color: black;
}
styles.css
body {
text-align: center;
font-family: sans-serif;
}
canvas {
background-color: black;
}
__MACOSX/._styles.css
// Draw stuff
// Time-stamp: <2019-01-21 20:08:33 Chuck Siska>
// ------------------------------------------------------------
// FUN. Draw filled rect.
function draw_rect( ctx, stroke, fill )
{
stroke = stroke || 'lightgrey';
fill = fill || 'dimgrey';
ctx.save( );
ctx.strokeStyle = stroke;
ctx.fillStyle = fill;
ctx.lineWidth = 5;
ctx.rect(75, 50, canvas.width - 150, canvas.height - 100);
ctx.stroke();
ctx.fill();
ctx.restore( );
}
//
===============================================
====== draw_grid ====
function draw_grid( rctx, rminor, rmajor, rstroke, rfill )
{
rctx.save( );
rctx.strokeStyle = rstroke;
rctx.fillStyle = rfill;
let width = rctx.canvas.width;
let height = rctx.canvas.height;
for ( var ix = 0; ix < width; ix += rminor )
{
rctx.beginPath( );
rctx.moveTo( ix, 0 );
rctx.lineTo( ix, height );
rctx.lineWidth = ( ix % rmajor == 0 ) ? 0.5 : 0.25;
rctx.stroke( );
if ( ix % rmajor == 0 ) { rctx.fillText( ix, ix, 10 ); }
}
for ( var iy = 0; iy < height; iy += rminor )
{
rctx.beginPath( );
rctx.moveTo( 0, iy );
rctx.lineTo( width, iy );
rctx.lineWidth = ( iy % rmajor == 0 ) ? 0.5 : 0.25;
rctx.stroke( );
if ( iy % rmajor == 0 ) {rctx.fillText( iy, 0, iy + 10 );}
}
rctx.restore( );
}
335 — Algorithm Engineering — Cella Rule 90
Project #1 – Cella Rule 90
Introduction
This project is to write a program to display the generational
progress of Wolfram's Rule-90 cellular
automaton. The program will be written in Javascript with an
HTML web page for display.
The cella "growth generations" will be shown in a 2D grid of
black and white cells. Each row after the top
will show the next generation.
Rule-90
Wolfram's Rule-90 (from his 2002 book "A New Kind of
Science") is based on a 1D array where each cell is
"active". What happens to it depends on its current binary state
(1 or 0, white or black) and the states of its two
neighbors; 3 cells in all. With 3 binary cells, there are 8
possible configurations. A Rule needs to specify what
happens to a cell with each of those 8 neighborly
configurations. Rule-90 looks like this:
This Rule format is interpreted as follows: leftmost is a cell
containing all black (1's, or filled cells). If the
center cell and its two neighbors are in state 1, then in the next
generation, the cell will change to state 0 (white,
clear). Put differently, if the binary number represented by the
3 cells is 111 = 7; then the middle cell will be
changes to state 0 in the next generation. A similar analysis is
used for the other 7 triple-cell states. Now, if we
treat the next generation states as 8 bits of a binary number,
then these 8 configurations generate (from left to
right) the bits 01011010, which equals a decimal 90. Hence,
this set of state transitions based on 3-cells each is
called Rule-90.
Setup
Your program should initialize a 400 by 400 square grid to have
all cells empty (state 0). Then set the top
row's 200th (just left of center) cell in state 1. This represents
the initial (#0 == seeded) generation. Include
your team name on the web page above the grid.
Running
After setup, your program should show on the next row down
the next (#1) generation of Rule-90 operating
on every row cell. You should presume that a "neighboring
cell" off the right or left side of the grid is empty.
(This limits the right and left border cells to only 4 of the 8
possible configurations, each.) Similarly, continue
running until all 400 rows (generations) have been shown. Then
stop.
NB, generations #0 thru #3 should look like this (roughly, using
empty space (and a hyphen) for state = 0
cells and X for state = 1 cells):
----X----
---X-X---
--X---X--
-X-X-X-X-
Complexity Order
You should prepare a 1-page paper describing your analysis of
the Big-O running time of your algorithm.
Address the usual issues such as main operations, input size,
etc.
Team
Your team may contain up to four members. We would prefer
larger teams. Pick a three-letter name for your
team (e.g., “ABX”). [For the next project, teams can be
changed.]
C. Siska February 3, 2019 Page 1 of 3
335 — Algorithm Engineering — Cella Rule 90
Project Reports
Tasks (WBS): Slice the project up into tasks. List each such
task. If a task needs to be split into sub-tasks,
the list these and indicate which task they are a sub-task of. At
the beginning, this does not have to be accurate
or final -- it changes as you develop and need to make changes
to the list of tasks.
Progress Board: Which WBS tasks have been A) Begun, by
whom? B) Completed (and can be
demonstrated) by whom, when? C) Verified (QA'd) by whom,
when? Include the current Progress Board file at
the end of each Standup Status report.
Standup Status, twice weekly. The Standup Status Report is due
Sunday by 11pm and on the day before the
last class session of the week at 11pm. One report per team. It
should contain, for each team member, their
Standup answers to the 3 standard Standup questions: Q1. What
task(s) have you completed since last status?
Q2. What task(s) do you plan to complete by next status? Q3.
What obstacles are blocking your progress (on
which task(s))? Consider sub-dividing a WBS task into "Half-
Day" sub-tasks so as to be able to have a task
completion (or more) for each status. Note that if a team
member takes on a WBS task and sub-tasks it, then the
sub-tasks should be added to the WBS and shown on the
Progress Board. Also, note that keeping track of tasks,
new/old sub-tasks, and completions takes effort, but can be
streamlined. Don't forget that merging your
completed task code into the team's mainline code requires
integration testing. Tasks that have gone through
QA should be demonstrable in class.
These documents should be delivered as .pdf files, and each
filename should include your course number,
your team name, the doc type (WBS, Progbrd, Standup), and the
date in YYMMDD format. E.g., “543-ABX-
Standup-190212.pdf”.
Readme File
You should provide a README.txt text file. Be clear in your
instruction on how to build and use the project
by providing instructions a novice programmer would
understand. If there are any external dependencies for
building, the README must also list them and how to find and
incorporate them. Usage should include an
example invocation. A README would cover the following:
• Class number
• Project number and name
• Team name and members
• Intro (including the algorithm used)
• Contents: Files in the .zip submission
• External Requirements (None?)
• Setup and Installation (if any)
• Sample invocation
• Features (both included and missing)
• Bugs (if any)
Academic Rules
Correctly and properly attribute all third party material and
references, lest points be taken off.
Submission
All Necessary Files: Your submission must, at a minimum,
include a plain ASCII text file called
README.txt, all project documentation files (except those
already delivered), all necessary source files to
allow the submission to be built and run independently by the
instructor. [For this project, no unusual files are
expected.] Note, the instructor not use use your IDE or O.S.
Headers: All source code files must include a comment header
identifying the author, author’s contact info
(please, no phone numbers), and a brief description of the file.
No Binaries: Do not include any IDE-specific files, object files,
binary executables, or other superfluous
files.
Project Folder: Place your submission files in a folder named X-
pY_teamname. Where X is the class
number and Y is the project number. For example, if your team
name is ABC and this is for project #2 in class
CS-123, then name the folder ”123-p2_ABC”.
Project Zip File: Then zip up this folder. Name the .zip file the
same as the folder name.
Turn in by 11pm on the due date (as specified in the bulletin-
board post) by sending me email (see the Syllabus
C. Siska February 3, 2019 Page 2 of 3
335 — Algorithm Engineering — Cella Rule 90
for the correct email address) with the zip file attached. The
email subject title should include the folder name.
ZAP file: If your emailer will not email a .zip file, then change
the file extension from .zip to .zap, attach
that, and tell me so in the email.
Email Body: Please include your team members' names and
campus IDs at the end of the email.
Project Problems: If there is a problem with your project, don't
put it in the email body – put it in the
README.txt file.
The Cloud: Do not provide a link to Dropbox, Gdrive, or other
cloud storage. Note, cloud files (e.g., G-
drive) are not accepted.
Grading
• 75% for compiling and executing with no errors or warnings
• 10% for clean and well-documented code (Rule #5(Clean))
• 10% for a clean and reasonable documentation files
• 5% for successfully following Submission rules
C. Siska February 3, 2019 Page 3 of 3
<Sample> CS-411 Project-1 Zeta – Standup Status Report
<Sample>
Standup Status: CS-411 Project-1 Zeta <Sample from Zeta
project>
Team: ABX = Alice Allison, Bob Robertson, Eve Evans
Alice:
1. Completed: #4 (Initialize Zeta Array), #12-Verified
2. Plan to complete: #7 (Move Glider Object)
3. Obstacles: None
Bob:
1. Completed: None, still working #6 (Check for Fixed
Collision)
2. Plan to complete: #6 (Check for Fixed Collision)
3. Obstacles: Trouble sub-tasking #6 <Sub-tasking so as to
have a demoable result takes practice.>
Eve:
1. Completed: #12 (Paint Background), #13 (Draw Walls)
2. Plan to complete: #14 (Draw Dragon Lair)
3. Obstacles: Waiting on format for Fixed Object Structure
Progress Board <Sample from Cella project>
<NB, Dotted task numbers to show dependencies can get in the
way of Rule #0(Fast).>
<NB, Not all tasks have been "fleshed out", yet.>
Ready:
#2 Setup Initial Layout (nested on #2.*, dep on #1)
#2.2 Setup Project Info
#3 Run Cella
#3.1 Generate next row (nested on #3.*)
Working:
#4 Draw XY cell color (Wk by Alice, 11/3)
<Where's Bob and Eve? Are they working on something?>
Done:
#11 Get XY cell next state (Wk by Bob, 11/2-11/2) <”Wk” =
“Working/Worked”>
#12 Get color from state (was #6, Wk by Alice, 10/30-10/30)
<Always write a task title before you start working on
something. Change the title later, if needed.>
Verified:
#1 Setup Infrastructure Demo (QA by Alice, Wk by Bob
10/30-10/31)
#2.1 Setup Cella Grid (QA by Eve, Wk by Alice 10/30-11/1)
Issues: <Tech Debt, Fix-later Defects, Issues that may need to
be Resolved>
o- Do we need an FSM object to “hold” the Cella rules?
o- Grid gen code is very ugly
OBE: <To connect with earlier status-reported task names.
Renaming is flexible.>
#6 Get XY cell next color ==> replaced by #11 (...next state)
and #12 (...next color)
#2 Setup Cell Board ==> renamed Setup Initial Layout
C. Siska February 4, 2019 Page 1 of 1
READNE: Notes on an HTML + CSS + JS example
Time-stamp: <2019-02-03 20:31:18 Chuck Siska>
------------------------------------------------------------
How to handle the JS-1 files to get results:
1. Main HTML file is js-1.html, a web page.
2. Sibling folder (at same level as .html) is "assets".
(You can move this folder elsewhere if you change js-1.html
accordingly.)
3. Web page links to (loads) assets/styles.css, a very simple
CSS file.
4. Web page has some HTML markup for title, header and text.
5. After body, web page loads a script file from assets with
fcns.
6. After that, another Script section defines another function.
7. And then runs some "loose" Javascript commands.
How to show (and run) the web page:
8. Drag and drop the html file onto a browser to see what it
does.
(*) Key: use fcn key F12 to open a "javascript console" in your
browser
and see what might be going wrong: errors and warnings.
Playing the HTML canvasTime-stamp:
body {  text-align center;  font-family sans-serif;}.docx

More Related Content

Similar to body { text-align center; font-family sans-serif;}.docx

ComputeFest 2012: Intro To R for Physical Sciences
ComputeFest 2012: Intro To R for Physical SciencesComputeFest 2012: Intro To R for Physical Sciences
ComputeFest 2012: Intro To R for Physical Sciences
alexstorer
 
CSC8503 Principles of Programming Languages Semester 1, 2015.docx
CSC8503 Principles of Programming Languages Semester 1, 2015.docxCSC8503 Principles of Programming Languages Semester 1, 2015.docx
CSC8503 Principles of Programming Languages Semester 1, 2015.docx
faithxdunce63732
 
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docxHW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
adampcarr67227
 
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and FuncCSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
MargenePurnell14
 
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docxNew folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
henrymartin15260
 
CS 542 -- Query Execution
CS 542 -- Query ExecutionCS 542 -- Query Execution
CS 542 -- Query Execution
J Singh
 
1 Project 2 Introduction - the SeaPort Project seri.docx
1  Project 2 Introduction - the SeaPort Project seri.docx1  Project 2 Introduction - the SeaPort Project seri.docx
1 Project 2 Introduction - the SeaPort Project seri.docx
honey725342
 
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docxpa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
gerardkortney
 
CS 112 PA #4Like the previous programming assignment, this assignm.docx
CS 112 PA #4Like the previous programming assignment, this assignm.docxCS 112 PA #4Like the previous programming assignment, this assignm.docx
CS 112 PA #4Like the previous programming assignment, this assignm.docx
annettsparrow
 

Similar to body { text-align center; font-family sans-serif;}.docx (20)

ComputeFest 2012: Intro To R for Physical Sciences
ComputeFest 2012: Intro To R for Physical SciencesComputeFest 2012: Intro To R for Physical Sciences
ComputeFest 2012: Intro To R for Physical Sciences
 
CSC8503 Principles of Programming Languages Semester 1, 2015.docx
CSC8503 Principles of Programming Languages Semester 1, 2015.docxCSC8503 Principles of Programming Languages Semester 1, 2015.docx
CSC8503 Principles of Programming Languages Semester 1, 2015.docx
 
Data structures cs301 power point slides lecture 01
Data structures   cs301 power point slides lecture 01Data structures   cs301 power point slides lecture 01
Data structures cs301 power point slides lecture 01
 
Class 10 Arrays
Class 10 ArraysClass 10 Arrays
Class 10 Arrays
 
Azure Data Lake Analytics Deep Dive
Azure Data Lake Analytics Deep DiveAzure Data Lake Analytics Deep Dive
Azure Data Lake Analytics Deep Dive
 
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docxHW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
HW2.pdfCSEEEE 230 Computer Organization and Assembly La.docx
 
CIS 336 (DEVRY) Entire Course NEW
CIS 336 (DEVRY) Entire Course NEWCIS 336 (DEVRY) Entire Course NEW
CIS 336 (DEVRY) Entire Course NEW
 
Write and run three interesting queries/tutorialoutlet
Write and run three interesting queries/tutorialoutletWrite and run three interesting queries/tutorialoutlet
Write and run three interesting queries/tutorialoutlet
 
CIS 336 STUDY Introduction Education--cis336study.com
CIS 336 STUDY Introduction Education--cis336study.comCIS 336 STUDY Introduction Education--cis336study.com
CIS 336 STUDY Introduction Education--cis336study.com
 
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and FuncCSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
CSE 1310 – Spring 21Introduction to ProgrammingLab 4 Arrays and Func
 
MICRO PROJECT 22319 DMS
MICRO PROJECT 22319 DMSMICRO PROJECT 22319 DMS
MICRO PROJECT 22319 DMS
 
e_lumley.pdf
e_lumley.pdfe_lumley.pdf
e_lumley.pdf
 
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docxNew folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
New folderCSE2AIF 2015 Assignment 2.pdfCSE2AIF - Artifi.docx
 
CS 542 -- Query Execution
CS 542 -- Query ExecutionCS 542 -- Query Execution
CS 542 -- Query Execution
 
Python - Lecture 12
Python - Lecture 12Python - Lecture 12
Python - Lecture 12
 
1 Project 2 Introduction - the SeaPort Project seri.docx
1  Project 2 Introduction - the SeaPort Project seri.docx1  Project 2 Introduction - the SeaPort Project seri.docx
1 Project 2 Introduction - the SeaPort Project seri.docx
 
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docxpa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
pa5PA5.docxCS 211 PA #5At certain universities, professors of.docx
 
CS 112 PA #4Like the previous programming assignment, this assignm.docx
CS 112 PA #4Like the previous programming assignment, this assignm.docxCS 112 PA #4Like the previous programming assignment, this assignm.docx
CS 112 PA #4Like the previous programming assignment, this assignm.docx
 
7986-lect 7.pdf
7986-lect 7.pdf7986-lect 7.pdf
7986-lect 7.pdf
 
C++ Boot Camp Part 2
C++ Boot Camp Part 2C++ Boot Camp Part 2
C++ Boot Camp Part 2
 

More from moirarandell

BOOK REVIEWS How to write a book review There are two .docx
BOOK REVIEWS How to write a book review  There are two .docxBOOK REVIEWS How to write a book review  There are two .docx
BOOK REVIEWS How to write a book review There are two .docx
moirarandell
 
Book required Current Issues and Enduring Questions, by Sylvan Ba.docx
Book required Current Issues and Enduring Questions, by Sylvan Ba.docxBook required Current Issues and Enduring Questions, by Sylvan Ba.docx
Book required Current Issues and Enduring Questions, by Sylvan Ba.docx
moirarandell
 
Book ListBecker, Ernest The Denial of D.docx
Book ListBecker, Ernest                          The Denial of D.docxBook ListBecker, Ernest                          The Denial of D.docx
Book ListBecker, Ernest The Denial of D.docx
moirarandell
 
BOOK 1984 MiniProject What makes a human beingOne .docx
BOOK 1984 MiniProject What makes a human beingOne .docxBOOK 1984 MiniProject What makes a human beingOne .docx
BOOK 1984 MiniProject What makes a human beingOne .docx
moirarandell
 
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docx
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docxBonnie Morgen First Day on the Job and Facing an Ethical Di.docx
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docx
moirarandell
 
Boley A Negro Town in the American West (1908) The commu.docx
Boley A Negro Town in the American West (1908)  The commu.docxBoley A Negro Town in the American West (1908)  The commu.docx
Boley A Negro Town in the American West (1908) The commu.docx
moirarandell
 
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docxBolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
moirarandell
 
BoF Professional Member Exclusive articles & analysis availa.docx
BoF Professional  Member Exclusive articles & analysis availa.docxBoF Professional  Member Exclusive articles & analysis availa.docx
BoF Professional Member Exclusive articles & analysis availa.docx
moirarandell
 

More from moirarandell (20)

BOOK REVIEWS How to write a book review There are two .docx
BOOK REVIEWS How to write a book review  There are two .docxBOOK REVIEWS How to write a book review  There are two .docx
BOOK REVIEWS How to write a book review There are two .docx
 
Book Review #3- The Spirit Catches You and You Fall Down”Ch.docx
Book Review #3- The Spirit Catches You and You Fall Down”Ch.docxBook Review #3- The Spirit Catches You and You Fall Down”Ch.docx
Book Review #3- The Spirit Catches You and You Fall Down”Ch.docx
 
Book required Current Issues and Enduring Questions, by Sylvan Ba.docx
Book required Current Issues and Enduring Questions, by Sylvan Ba.docxBook required Current Issues and Enduring Questions, by Sylvan Ba.docx
Book required Current Issues and Enduring Questions, by Sylvan Ba.docx
 
Book Review #1- The Spirit Catches You and You Fall Down”Chapte.docx
Book Review #1- The Spirit Catches You and You Fall Down”Chapte.docxBook Review #1- The Spirit Catches You and You Fall Down”Chapte.docx
Book Review #1- The Spirit Catches You and You Fall Down”Chapte.docx
 
Book reportGringo viejo- Carlos FuentesThe written book repo.docx
Book reportGringo viejo- Carlos FuentesThe written book repo.docxBook reportGringo viejo- Carlos FuentesThe written book repo.docx
Book reportGringo viejo- Carlos FuentesThe written book repo.docx
 
Book reference Kouzes, James M. and Posner, Barry Z. The Leadership.docx
Book reference Kouzes, James M. and Posner, Barry Z. The Leadership.docxBook reference Kouzes, James M. and Posner, Barry Z. The Leadership.docx
Book reference Kouzes, James M. and Posner, Barry Z. The Leadership.docx
 
BOOK PICTURE I POSTED TOO. Go to the the textbook, study chapt.docx
BOOK PICTURE I POSTED TOO. Go to the the textbook, study chapt.docxBOOK PICTURE I POSTED TOO. Go to the the textbook, study chapt.docx
BOOK PICTURE I POSTED TOO. Go to the the textbook, study chapt.docx
 
Book ListBecker, Ernest The Denial of D.docx
Book ListBecker, Ernest                          The Denial of D.docxBook ListBecker, Ernest                          The Denial of D.docx
Book ListBecker, Ernest The Denial of D.docx
 
Book list below.docx
Book list below.docxBook list below.docx
Book list below.docx
 
Book is Media Literacy. Eighth EditionW.JamesPotte.docx
Book is Media Literacy. Eighth EditionW.JamesPotte.docxBook is Media Literacy. Eighth EditionW.JamesPotte.docx
Book is Media Literacy. Eighth EditionW.JamesPotte.docx
 
Book Forensic and Investigative AccountingPlease answer t.docx
Book Forensic and Investigative AccountingPlease answer t.docxBook Forensic and Investigative AccountingPlease answer t.docx
Book Forensic and Investigative AccountingPlease answer t.docx
 
Book Criminoloy Second EditionRead Chapter 6. Please submit .docx
Book Criminoloy Second EditionRead Chapter 6. Please submit .docxBook Criminoloy Second EditionRead Chapter 6. Please submit .docx
Book Criminoloy Second EditionRead Chapter 6. Please submit .docx
 
Book Discussion #2 Ideas(may select 1 or more to respond to).docx
Book Discussion #2 Ideas(may select 1 or more to respond to).docxBook Discussion #2 Ideas(may select 1 or more to respond to).docx
Book Discussion #2 Ideas(may select 1 or more to respond to).docx
 
BOOK 1984 MiniProject What makes a human beingOne .docx
BOOK 1984 MiniProject What makes a human beingOne .docxBOOK 1984 MiniProject What makes a human beingOne .docx
BOOK 1984 MiniProject What makes a human beingOne .docx
 
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docx
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docxBonnie Morgen First Day on the Job and Facing an Ethical Di.docx
Bonnie Morgen First Day on the Job and Facing an Ethical Di.docx
 
Bonds are a vital source of financing to governments and corpora.docx
Bonds are a vital source of financing to governments and corpora.docxBonds are a vital source of financing to governments and corpora.docx
Bonds are a vital source of financing to governments and corpora.docx
 
Bond Company adopted the dollar-value LIFO inventory method on Janua.docx
Bond Company adopted the dollar-value LIFO inventory method on Janua.docxBond Company adopted the dollar-value LIFO inventory method on Janua.docx
Bond Company adopted the dollar-value LIFO inventory method on Janua.docx
 
Boley A Negro Town in the American West (1908) The commu.docx
Boley A Negro Town in the American West (1908)  The commu.docxBoley A Negro Town in the American West (1908)  The commu.docx
Boley A Negro Town in the American West (1908) The commu.docx
 
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docxBolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
Bolsonaro and Brazils Illiberal Backlash Wendy Hunter, Timo.docx
 
BoF Professional Member Exclusive articles & analysis availa.docx
BoF Professional  Member Exclusive articles & analysis availa.docxBoF Professional  Member Exclusive articles & analysis availa.docx
BoF Professional Member Exclusive articles & analysis availa.docx
 

Recently uploaded

BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
SoniaTolstoy
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
kauryashika82
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
fonyou31
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
heathfieldcps1
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Krashi Coaching
 

Recently uploaded (20)

BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in DelhiRussian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
Russian Escort Service in Delhi 11k Hotel Foreigner Russian Call Girls in Delhi
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 
Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
fourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writingfourth grading exam for kindergarten in writing
fourth grading exam for kindergarten in writing
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3Q4-W6-Restating Informational Text Grade 3
Q4-W6-Restating Informational Text Grade 3
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Disha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdfDisha NEET Physics Guide for classes 11 and 12.pdf
Disha NEET Physics Guide for classes 11 and 12.pdf
 
APM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across SectorsAPM Welcome, APM North West Network Conference, Synergies Across Sectors
APM Welcome, APM North West Network Conference, Synergies Across Sectors
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 

body { text-align center; font-family sans-serif;}.docx

  • 1. body { text-align: center; font-family: sans-serif; } canvas { background-color: black; } styles.css body { text-align: center; font-family: sans-serif; } canvas { background-color: black; }
  • 2. __MACOSX/._styles.css // Draw stuff // Time-stamp: <2019-01-21 20:08:33 Chuck Siska> // ------------------------------------------------------------ // FUN. Draw filled rect. function draw_rect( ctx, stroke, fill ) { stroke = stroke || 'lightgrey'; fill = fill || 'dimgrey'; ctx.save( ); ctx.strokeStyle = stroke; ctx.fillStyle = fill; ctx.lineWidth = 5; ctx.rect(75, 50, canvas.width - 150, canvas.height - 100); ctx.stroke(); ctx.fill(); ctx.restore( );
  • 3. } // =============================================== ====== draw_grid ==== function draw_grid( rctx, rminor, rmajor, rstroke, rfill ) { rctx.save( ); rctx.strokeStyle = rstroke; rctx.fillStyle = rfill; let width = rctx.canvas.width; let height = rctx.canvas.height; for ( var ix = 0; ix < width; ix += rminor ) { rctx.beginPath( ); rctx.moveTo( ix, 0 ); rctx.lineTo( ix, height ); rctx.lineWidth = ( ix % rmajor == 0 ) ? 0.5 : 0.25; rctx.stroke( );
  • 4. if ( ix % rmajor == 0 ) { rctx.fillText( ix, ix, 10 ); } } for ( var iy = 0; iy < height; iy += rminor ) { rctx.beginPath( ); rctx.moveTo( 0, iy ); rctx.lineTo( width, iy ); rctx.lineWidth = ( iy % rmajor == 0 ) ? 0.5 : 0.25; rctx.stroke( ); if ( iy % rmajor == 0 ) {rctx.fillText( iy, 0, iy + 10 );} } rctx.restore( ); } 335 — Algorithm Engineering — Cella Rule 90 Project #1 – Cella Rule 90 Introduction This project is to write a program to display the generational
  • 5. progress of Wolfram's Rule-90 cellular automaton. The program will be written in Javascript with an HTML web page for display. The cella "growth generations" will be shown in a 2D grid of black and white cells. Each row after the top will show the next generation. Rule-90 Wolfram's Rule-90 (from his 2002 book "A New Kind of Science") is based on a 1D array where each cell is "active". What happens to it depends on its current binary state (1 or 0, white or black) and the states of its two neighbors; 3 cells in all. With 3 binary cells, there are 8 possible configurations. A Rule needs to specify what happens to a cell with each of those 8 neighborly configurations. Rule-90 looks like this: This Rule format is interpreted as follows: leftmost is a cell containing all black (1's, or filled cells). If the center cell and its two neighbors are in state 1, then in the next generation, the cell will change to state 0 (white, clear). Put differently, if the binary number represented by the 3 cells is 111 = 7; then the middle cell will be changes to state 0 in the next generation. A similar analysis is used for the other 7 triple-cell states. Now, if we treat the next generation states as 8 bits of a binary number, then these 8 configurations generate (from left to right) the bits 01011010, which equals a decimal 90. Hence, this set of state transitions based on 3-cells each is called Rule-90. Setup Your program should initialize a 400 by 400 square grid to have all cells empty (state 0). Then set the top
  • 6. row's 200th (just left of center) cell in state 1. This represents the initial (#0 == seeded) generation. Include your team name on the web page above the grid. Running After setup, your program should show on the next row down the next (#1) generation of Rule-90 operating on every row cell. You should presume that a "neighboring cell" off the right or left side of the grid is empty. (This limits the right and left border cells to only 4 of the 8 possible configurations, each.) Similarly, continue running until all 400 rows (generations) have been shown. Then stop. NB, generations #0 thru #3 should look like this (roughly, using empty space (and a hyphen) for state = 0 cells and X for state = 1 cells): ----X---- ---X-X--- --X---X-- -X-X-X-X- Complexity Order You should prepare a 1-page paper describing your analysis of the Big-O running time of your algorithm. Address the usual issues such as main operations, input size, etc. Team Your team may contain up to four members. We would prefer larger teams. Pick a three-letter name for your
  • 7. team (e.g., “ABX”). [For the next project, teams can be changed.] C. Siska February 3, 2019 Page 1 of 3 335 — Algorithm Engineering — Cella Rule 90 Project Reports Tasks (WBS): Slice the project up into tasks. List each such task. If a task needs to be split into sub-tasks, the list these and indicate which task they are a sub-task of. At the beginning, this does not have to be accurate or final -- it changes as you develop and need to make changes to the list of tasks. Progress Board: Which WBS tasks have been A) Begun, by whom? B) Completed (and can be demonstrated) by whom, when? C) Verified (QA'd) by whom, when? Include the current Progress Board file at the end of each Standup Status report. Standup Status, twice weekly. The Standup Status Report is due Sunday by 11pm and on the day before the last class session of the week at 11pm. One report per team. It should contain, for each team member, their Standup answers to the 3 standard Standup questions: Q1. What task(s) have you completed since last status? Q2. What task(s) do you plan to complete by next status? Q3. What obstacles are blocking your progress (on which task(s))? Consider sub-dividing a WBS task into "Half- Day" sub-tasks so as to be able to have a task completion (or more) for each status. Note that if a team member takes on a WBS task and sub-tasks it, then the
  • 8. sub-tasks should be added to the WBS and shown on the Progress Board. Also, note that keeping track of tasks, new/old sub-tasks, and completions takes effort, but can be streamlined. Don't forget that merging your completed task code into the team's mainline code requires integration testing. Tasks that have gone through QA should be demonstrable in class. These documents should be delivered as .pdf files, and each filename should include your course number, your team name, the doc type (WBS, Progbrd, Standup), and the date in YYMMDD format. E.g., “543-ABX- Standup-190212.pdf”. Readme File You should provide a README.txt text file. Be clear in your instruction on how to build and use the project by providing instructions a novice programmer would understand. If there are any external dependencies for building, the README must also list them and how to find and incorporate them. Usage should include an example invocation. A README would cover the following: • Class number • Project number and name • Team name and members • Intro (including the algorithm used) • Contents: Files in the .zip submission • External Requirements (None?) • Setup and Installation (if any) • Sample invocation • Features (both included and missing) • Bugs (if any)
  • 9. Academic Rules Correctly and properly attribute all third party material and references, lest points be taken off. Submission All Necessary Files: Your submission must, at a minimum, include a plain ASCII text file called README.txt, all project documentation files (except those already delivered), all necessary source files to allow the submission to be built and run independently by the instructor. [For this project, no unusual files are expected.] Note, the instructor not use use your IDE or O.S. Headers: All source code files must include a comment header identifying the author, author’s contact info (please, no phone numbers), and a brief description of the file. No Binaries: Do not include any IDE-specific files, object files, binary executables, or other superfluous files. Project Folder: Place your submission files in a folder named X- pY_teamname. Where X is the class number and Y is the project number. For example, if your team name is ABC and this is for project #2 in class CS-123, then name the folder ”123-p2_ABC”. Project Zip File: Then zip up this folder. Name the .zip file the same as the folder name. Turn in by 11pm on the due date (as specified in the bulletin- board post) by sending me email (see the Syllabus C. Siska February 3, 2019 Page 2 of 3
  • 10. 335 — Algorithm Engineering — Cella Rule 90 for the correct email address) with the zip file attached. The email subject title should include the folder name. ZAP file: If your emailer will not email a .zip file, then change the file extension from .zip to .zap, attach that, and tell me so in the email. Email Body: Please include your team members' names and campus IDs at the end of the email. Project Problems: If there is a problem with your project, don't put it in the email body – put it in the README.txt file. The Cloud: Do not provide a link to Dropbox, Gdrive, or other cloud storage. Note, cloud files (e.g., G- drive) are not accepted. Grading • 75% for compiling and executing with no errors or warnings • 10% for clean and well-documented code (Rule #5(Clean)) • 10% for a clean and reasonable documentation files • 5% for successfully following Submission rules C. Siska February 3, 2019 Page 3 of 3 <Sample> CS-411 Project-1 Zeta – Standup Status Report <Sample> Standup Status: CS-411 Project-1 Zeta <Sample from Zeta project>
  • 11. Team: ABX = Alice Allison, Bob Robertson, Eve Evans Alice: 1. Completed: #4 (Initialize Zeta Array), #12-Verified 2. Plan to complete: #7 (Move Glider Object) 3. Obstacles: None Bob: 1. Completed: None, still working #6 (Check for Fixed Collision) 2. Plan to complete: #6 (Check for Fixed Collision) 3. Obstacles: Trouble sub-tasking #6 <Sub-tasking so as to have a demoable result takes practice.> Eve: 1. Completed: #12 (Paint Background), #13 (Draw Walls) 2. Plan to complete: #14 (Draw Dragon Lair) 3. Obstacles: Waiting on format for Fixed Object Structure Progress Board <Sample from Cella project> <NB, Dotted task numbers to show dependencies can get in the way of Rule #0(Fast).> <NB, Not all tasks have been "fleshed out", yet.> Ready: #2 Setup Initial Layout (nested on #2.*, dep on #1) #2.2 Setup Project Info #3 Run Cella #3.1 Generate next row (nested on #3.*) Working: #4 Draw XY cell color (Wk by Alice, 11/3) <Where's Bob and Eve? Are they working on something?> Done: #11 Get XY cell next state (Wk by Bob, 11/2-11/2) <”Wk” = “Working/Worked”> #12 Get color from state (was #6, Wk by Alice, 10/30-10/30) <Always write a task title before you start working on
  • 12. something. Change the title later, if needed.> Verified: #1 Setup Infrastructure Demo (QA by Alice, Wk by Bob 10/30-10/31) #2.1 Setup Cella Grid (QA by Eve, Wk by Alice 10/30-11/1) Issues: <Tech Debt, Fix-later Defects, Issues that may need to be Resolved> o- Do we need an FSM object to “hold” the Cella rules? o- Grid gen code is very ugly OBE: <To connect with earlier status-reported task names. Renaming is flexible.> #6 Get XY cell next color ==> replaced by #11 (...next state) and #12 (...next color) #2 Setup Cell Board ==> renamed Setup Initial Layout C. Siska February 4, 2019 Page 1 of 1 READNE: Notes on an HTML + CSS + JS example Time-stamp: <2019-02-03 20:31:18 Chuck Siska> ------------------------------------------------------------ How to handle the JS-1 files to get results: 1. Main HTML file is js-1.html, a web page. 2. Sibling folder (at same level as .html) is "assets".
  • 13. (You can move this folder elsewhere if you change js-1.html accordingly.) 3. Web page links to (loads) assets/styles.css, a very simple CSS file. 4. Web page has some HTML markup for title, header and text. 5. After body, web page loads a script file from assets with fcns. 6. After that, another Script section defines another function. 7. And then runs some "loose" Javascript commands. How to show (and run) the web page: 8. Drag and drop the html file onto a browser to see what it does. (*) Key: use fcn key F12 to open a "javascript console" in your browser and see what might be going wrong: errors and warnings. Playing the HTML canvasTime-stamp: