From kirby.urner at gmail.com Wed Aug 3 13:13:26 2016 From: kirby.urner at gmail.com (kirby urner) Date: Wed, 3 Aug 2016 10:13:26 -0700 Subject: [Edu-sig] rounding out a Python course... Message-ID: Having explored Jupyter Notebooks, our next task was to dissect a simple Flask application, with an API published here: http://thekirbster.pythonanywhere.com The goal with my campers is to get them used to self-hosting, serving solo, with a server process on localhost, then deploy, most straightforwardly from Anaconda Spyder to Pythonanywhere in my experience, though I also enjoy Eclipse, Pycharm and other IDEs. https://flic.kr/p/EebhmS When working with Python beginners, I don't insist on bringing in Github or any version control right away. Unittesting with Pyunit, yes, we got to that (in a Jupyter Notebook): http://nbviewer.jupyter.org/github/4dsolutions/Python5/blob/master/Atoms%20in%20Python.ipynb Shortened: http://goo.gl/nek3Uf But actively using Github, in a 40 hour course on Python, is not required. Pythonanywhere lets us copy files from localhost to the server with a capable GUI all its own. My Flask application carries on with the Periodic Table of Elements, fleshed out as lists, tuples, namedTuples, then as a class (with __getitem__ to mirror namedTuple behavior). We study I/O in terms of reading/writing JSON files, with a quick look at pickle (just for contrast, of what it's like to archive full Python objects). I emphasize the security aspects of JSON: in being so low level, it's not about sneaking in runnable code. The advantage of stretching to Flask, is that whereas all the running code the students look at is pure Python, I show them where the JavaScript would go, in /static/js, to be imported by the html5 / jinja2 templates (as well as the css). PythonAnywhere is already set up to host Flask applications. They only take minutes to set up. One of my students had an application going within the course of the 3-lab session. I told the students it was OK to mess up the periodic table with bogus data and indeed one of the elements has 1009 protons I think it is. We were able to POST to the SQLite database with code this simple (you're welcome to try, just for fun (the data may go away when I swap in a new copy, or I may change the "secret security word" -- there's no login). It won't accept elements already posted. Simple client (programmaticly POST, no actual browser form used). # -*- coding: utf-8 -*- """ Created on Fri Jul 29 17:35:58 2016 @author: Kirby Urner Post a chemical element to the Periodic Table. Goes into sqlite DB Periodic_table.Elements API: HTML views /elements /elements/H /elements/Si ... /elements/all JSON output /api/elements?elem=H /api/elements?elem=O ... /api/elements?elem=all Requires: flask_app.py <--- uses flask (conda install flask) connector.py Databases (SQLite) glossary.db <--- these may need to go in home dir periodic_table.db Jinja2 templates /templates/ home.html elements.html elem_page.html all_elems.html glossary.html """ import requests data = {} data["protons"]=81 data["symbol"]="Tl" data["long_name"]="Thallium" data["mass"]=204.3833 data["series"]="Post-transition metal" data["secret"]="DADA" # <--- primitive authentication # the_url = 'http://localhost:5000/api/elements' the_url = 'http://thekirbster.pythonanywhere.com/api/elements' r = requests.post(the_url, data=data) print(r.status_code) print(r.content) PS: here's from my review of decorators from last night, written live while I chatted: # -*- coding: utf-8 -*- """ Created on Tue Aug 2 20:58:29 2016 @author: kurner """ def UFO(arg): def eater(f): f.note = arg return f return eater @UFO("I've been abucted") def innocent_bystander(): print("Hello world") print(innocent_bystander()) print(innocent_bystander.note) ==== # -*- coding: utf-8 -*- """ Created on Tue Aug 2, 2016 Course: PYT-PR (Saisoft.net) Session 09 Kirby Urner Instructor: kirby.urner at gmail.com @thekirbster Audio Check (6:15 PM PDT) Introduction: Python in the Ecosystem (continued) PythonAnywhere + Github + Flask Jupyter Notebooks Batteries Included: SQLite (sqlite3) Web Dev: Dissecting a Flask application LAB 1: get a Flask application up & running on localhost Reviewing Decorators LAB 2: use Flask client to add to Periodic_table.db Another look at Pythons "scaffolding" (__rib__ cage): The Permutation class ("word scrambles") (more concepts through Cryptography & Group Theory) LAB 3: doodle period: encode and decode various phrases Play with web app more. Pythonanywhere anyone? Summary of Session 09 """ -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Fri Aug 5 17:10:34 2016 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 5 Aug 2016 14:10:34 -0700 Subject: [Edu-sig] mixed messages about math... Message-ID: I was just drafting another blog post for CERM Academy, which manages streams of thought pieces going out to subscribers, then warehoused in a WordPress site. [1] As a former high school math teacher, my question is about the likely fate of that profession, in the light of two messages coming loud and strong from the adult world: 1) the US President, Bill Gates, Mark Zuckerberg and many others, including hip hop stars, say "learning to code" is a great door opener, a ticket to the 21st Century and 2) in order to respond to this demand, we're going to need a new army of CS teachers, very much in short supply at the moment. Scientific American has another article on that theme in this August's issue. [2] What's being said, then, is: 3) whatever this "learning to code" thing is, it cannot be math, as we presently do have a lot of math teachers, eager to innovate, but only a few "coding teachers" ergo "CS is not Math". That's quite a devastating message to be broadcasting. Math already has a relevance problem, with books like 'The Math Myth' chipping away at its lifeblood, its required status. "So what if we swapped out math for CS?" is the question that inevitably arises, once we tell the world they're really different. What if the school can't produce? "Stay home and learn"? Who gets to do that? That's an interesting question. Before we go too far down this road however, it may pay to look ahead. Won't those hypothetical new coding classes include stuff about vectors and spatial geometry? Luciano's OSCON talk was a lot about writing a vector class in fluent Python. Isn't that what CAD is all about? Look at Pi3D. Algorithms for finding primes.... Understanding RSA entails learning about Euler's Theorem, a generalization of Fermat's Little, and so on. Is 'The Art of Computer Programming' not-mathematical simply by virtue of being only semi-numerical? In saying all these actually relevant topics belong to this new discipline, and that math teachers are not qualified to teach it, is stripping away their last shred of credibility. The real weak link in this chain is not the math teachers, but the fact that they're ball and chained to computer illiterate textbooks. In the US, they're commanded to toe the line and teach to the tests. But the tests have no use for hexadecimals (Common Core is base 10 only). Finally, right when functions become "top level citizens", (hooray) it turns out math teachers no longer get to teach exactly what that means, as the examples are all in JavaScript or other "not math" languages. The real message we're sending to is that mathematics involves calculation, because in math class we use calculators and don't code, whereas computer science involves computation. Math is for calculator people. Computer science is for computer people. It's TI versus Pi. We seem prepared to move ahead on such thin ice, akin to saying data science is not really math, not statistics, because there's coding involved. Somehow the mere act of coding marks a mythical boundary, around which we're happy to design our civilization? Anyway, subscribers here are already veterans of such discussions. I ruminate more in this recent blog post: http://worldgame.blogspot.com/2016/08/accelerated-learning.html Kirby [1] http://cermacademy.com/ [2] https://flic.kr/p/KCTvvU -------------- next part -------------- An HTML attachment was scrubbed... URL: From david at handysoftware.com Fri Aug 5 20:52:50 2016 From: david at handysoftware.com (David Handy) Date: Fri, 5 Aug 2016 20:52:50 -0400 (EDT) Subject: [Edu-sig] mixed messages about math... In-Reply-To: References: Message-ID: <1470444770.623726384@apps.rackspace.com> You haven't heard me on this list for a while, but I've been lurking! About Math and CS - I remember the time (when I was in high school, early 1980s) that there were several Math textbooks that included short computer programs right in the text. Students were encouraged to type these programs into some nearby microcomputer and try them out. The language: BASIC. Students were encouraged to read the code and figure out what it did, and write more of their own. On, say, an Apple ][ or TRS-80 type machine. Again, these were Math textbooks, not programming nor electronics nor science textbooks. The first time I saw a computer in school (1979, it was a Commodore PET) was in my pre-Algrebra Math class. 7th grade. In Hillsboro, Oregon. We were encouraged to take a few minutes at the end of Math class time, on a regular basis, to write whatever code our hearts desired. We would write code on paper at home (and look up examples in magazines) and bring it to Math class to type in. Amazingly, Kirby, what you are saying is that things have gone backwards since the early 1980s in terms of integrating Math and Computer Science. David H On Friday, August 5, 2016 5:10pm, "kirby urner" said: I was just drafting another blog post for CERM Academy,which manages streams of thought pieces going out to subscribers, then warehoused in a WordPress site. [1]As a former high school math teacher, my question is about the likely fate of that profession, in the light of two messages coming loud and strong from the adult world:1) the US President, Bill Gates, Mark Zuckerberg and many others, including hip hop stars, say "learning to code" is a great door opener, a ticket to the 21st Century and 2) in order to respond to this demand, we're going to need a new army of CS teachers, very much in short supply at the moment. Scientific American has another article on that theme in this August's issue. [2]What's being said, then, is: 3) whatever this "learning to code" thing is, it cannot bemath, as we presently do have a lot of math teachers, eager to innovate, but only a few "coding teachers" ergo "CS is not Math".That's quite a devastating message to be broadcasting. Math already has a relevance problem, with books like 'The Math Myth' chipping away at its lifeblood, its required status. "So what if we swapped out math for CS?" is the question that inevitably arises, once we tell the world they're really different. What if the school can't produce? "Stay home and learn"? Who gets to do that? That's an interesting question.Before we go too far down this road however, it may pay to look ahead. Won't those hypothetical new coding classes include stuff about vectors and spatial geometry? Luciano's OSCON talk was a lot about writing a vector class in fluent Python. Isn't that what CAD is all about? Look at Pi3D. Algorithms for finding primes.... Understanding RSA entails learning about Euler's Theorem, a generalization of Fermat's Little, and so on. Is 'The Art of Computer Programming' not-mathematical simply by virtue of being only semi-numerical? In saying all these actually relevant topics belong to this new discipline, and that math teachers are not qualified to teach it, is stripping away their last shred of credibility. The real weak link in this chain is not the math teachers, but the fact that they're ball and chained to computer illiterate textbooks. In the US, they're commanded to toe the line and teach to the tests. But the tests have no use for hexadecimals (Common Core is base 10 only). Finally, right when functions become "top level citizens", (hooray) it turns out math teachers no longer get to teach exactly what that means, as the examples are all in JavaScript or other "not math" languages.The real message we're sending to is that mathematicsinvolves calculation, because in math class we use calculators and don't code, whereas computer science involves computation. Math is for calculator people. Computer science is for computer people. It's TI versus Pi. We seem prepared to move ahead on such thin ice, akin to saying data science is not really math, not statistics, because there's coding involved. Somehow the mere act of coding marks a mythical boundary, around which we're happy to design our civilization? Anyway, subscribers here are already veterans of such discussions. I ruminate more in this recent blog post: [ http://worldgame.blogspot.com/2016/08/accelerated-learning.html ]( http://worldgame.blogspot.com/2016/08/accelerated-learning.html ) Kirby [1] [ http://cermacademy.com/ ]( http://cermacademy.com/ ) [2] [ https://flic.kr/p/KCTvvU ]( https://flic.kr/p/KCTvvU ) -------------- next part -------------- An HTML attachment was scrubbed... URL: From carl at nextdayvideo.com Fri Aug 5 22:59:47 2016 From: carl at nextdayvideo.com (Carl Karsten) Date: Fri, 5 Aug 2016 21:59:47 -0500 Subject: [Edu-sig] mixed messages about math... In-Reply-To: References: Message-ID: I pretty much disagree with your conclusion about "what is said. .. CS is not Math" and all the conclusions and predictions. Math classes and math teachers are not going to be replaced by anything. In HS my CS teacher was a trained musician. He did fine teaching Basic, but had no idea how to teach or program Pascal to the 5 or so of us in the advanced class. I suspect a few years later he figured it out, and can now teach it just fine. There is the problem of hours in a day, and hours you can keep a person in class. those are fixed, so if you want to add a minute teaching CS you do need to decide what you will take a minute away from. Language? PE, lunch... I'm glad this is not my problem. On Fri, Aug 5, 2016 at 4:10 PM, kirby urner wrote: > > I was just drafting another blog post for CERM Academy, > which manages streams of thought pieces going out to > subscribers, then warehoused in a WordPress site. [1] > > As a former high school math teacher, my question is > about the likely fate of that profession, in the light of two > messages coming loud and strong from the adult world: > > 1) the US President, Bill Gates, Mark Zuckerberg and > many others, including hip hop stars, say "learning to code" > is a great door opener, a ticket to the 21st Century > > and > > 2) in order to respond to this demand, we're going to > need a new army of CS teachers, very much in short > supply at the moment. Scientific American has another > article on that theme in this August's issue. [2] > > What's being said, then, is: > > 3) whatever this "learning to code" thing is, it cannot be > math, as we presently do have a lot of math teachers, > eager to innovate, but only a few "coding teachers" ergo > "CS is not Math". > > That's quite a devastating message to be broadcasting. > Math already has a relevance problem, with books like > 'The Math Myth' chipping away at its lifeblood, its > required status. > > "So what if we swapped out math for CS?" is the question > that inevitably arises, once we tell the world they're > really different. What if the school can't produce? > "Stay home and learn"? Who gets to do that? That's > an interesting question. > > Before we go too far down this road however, it may > pay to look ahead. Won't those hypothetical new > coding classes include stuff about vectors and spatial > geometry? Luciano's OSCON talk was a lot about > writing a vector class in fluent Python. Isn't that what > CAD is all about? Look at Pi3D. > > Algorithms for finding primes.... Understanding RSA > entails learning about Euler's Theorem, a generalization > of Fermat's Little, and so on. > > Is 'The Art of Computer Programming' not-mathematical > simply by virtue of being only semi-numerical? > > In saying all these actually relevant topics belong to this > new discipline, and that math teachers are not qualified > to teach it, is stripping away their last shred of credibility. > The real weak link in this chain is not the math teachers, > but the fact that they're ball and chained to computer > illiterate textbooks. In the US, they're commanded to > toe the line and teach to the tests. But the tests have > no use for hexadecimals (Common Core is base 10 only). > > Finally, right when functions become "top level citizens", > (hooray) it turns out math teachers no longer get to > teach exactly what that means, as the examples are all > in JavaScript or other "not math" languages. > > The real message we're sending to is that mathematics > involves calculation, because in math class we use > calculators and don't code, whereas computer science > involves computation. > > Math is for calculator people. Computer science is for > computer people. It's TI versus Pi. > > We seem prepared to move ahead on such thin ice, akin to > saying data science is not really math, not statistics, because > there's coding involved. > > Somehow the mere act of coding marks a mythical boundary, > around which we're happy to design our civilization? > > Anyway, subscribers here are already veterans of such > discussions. I ruminate more in this recent blog post: > > http://worldgame.blogspot.com/2016/08/accelerated-learning.html > > Kirby > > [1] http://cermacademy.com/ > > [2] https://flic.kr/p/KCTvvU > > > > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > https://mail.python.org/mailman/listinfo/edu-sig > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From calcpage at aol.com Fri Aug 5 23:44:45 2016 From: calcpage at aol.com (A. Jorge Garcia) Date: Fri, 5 Aug 2016 23:44:45 -0400 Subject: [Edu-sig] mixed messages about math... In-Reply-To: References: Message-ID: <1565df3f834-6d2e-5919@webprd-a31.mail.aol.com> Kirby, as usual you hit the nail right on its proverbial head! When I started teaching in the 1980s, student enrolments and math positions were on the decline. I had to find a new position every year for the first 5 years as a Math Teacher. As such, I saw how several schools handed CS curriculae. Invariably, at least in NYS, it was the Math Dept that taught CS. And Math Teachers encouraged students to program. In the mid 1970s and early 1980s it was BASIC on an IBM PC. Then APCS started in 1984. In the 1990s it was TI-BASIC on a Graphing Calculator too! However, nowadays, most Math Teachers don't have the background or the interest or the time to do so. It's a very sad state of affairs if you ask me! Sincerely, A. Jorge Garcia Applied Math, Physics & CS http://shadowfaxrant.blogspot.com http://www.youtube.com/calcpage2009 2015 NYS Secondary Math http://PAEMST.org Nominee From calcpage at aol.com Sat Aug 6 00:08:38 2016 From: calcpage at aol.com (A. Jorge Garcia) Date: Sat, 6 Aug 2016 00:08:38 -0400 Subject: [Edu-sig] mixed messages about math... In-Reply-To: <1565df3f834-6d2e-5919@webprd-a31.mail.aol.com> Message-ID: <1565e09d605-1022-6936@webprd-a67.mail.aol.com> SORRY, HAD TO FIX TYPOS FROM MY PHONE: Hi Kirby, et al, As usual you hit the nail right on its proverbial head!? When I started teaching in the 1980s, student?enrollments?and math positions were on the decline.? I had to find a new position every year for the first 5 years as a Math?Teacher.? As such, I saw how several schools handed CS curriculae.? Invariably, at least in NYS, it was the Math Dept that taught CS,? ... and Math Teachers encouraged students to program.? In the mid 1970s it was C on UNIX on PDP11/780s,? ...and early 1980s it was BASIC on DOS on IBM PCs.? Then APCS started in 1984: Pascal, C++ and Java.? In the 1990s it was TI-BASIC on a Graphing Calculator too!? However, nowadays, most Math Teachers don't have the background or the interest or the time to do so.? It's a very sad state of affairs if you ask me!? Sincerely,? A. Jorge Garcia? Applied Math, Physics & CS? http://shadowfaxrant.blogspot.com http://www.youtube.com/calcpage2009? 2015 NYS Secondary Math?http://PAEMST.org?Nominee? -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Sat Aug 6 01:12:48 2016 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 5 Aug 2016 22:12:48 -0700 Subject: [Edu-sig] mixed messages about math... In-Reply-To: References: Message-ID: On Fri, Aug 5, 2016 at 7:59 PM, Carl Karsten wrote: > I pretty much disagree with your conclusion about "what is said. .. CS is > not Math" and all the conclusions and predictions. > > Math classes and math teachers are not going to be replaced by anything. > > Most of the articles I see begin with the premise that "Math is not CS" i.e. if we're to have more coding in the schools, that's not because math classes will need to change to include more coding. Math will stay the way it is now. Mainly with the TI calculators. That seems to be a widely shared vision. Coding as an activity is usually presented as something outside of math. Given increasing pressure to teach coding skills, schools have to decide in a hurry if that has anything to do with updating the math curriculum. I think that's a question we should not just bleep over. I'm not saying I have all the answers as to how things might go. To the extent the answer is "no, we can't expect more sharing of coding savvy to come from the math teachers", the message then is: math and coding are separate disciplines. I'm suggesting, contrary to this conclusion, that existing math teachers, if permitted to innovate, and given professional development classes, could probably rise to the occasion, and that's a solution we should explore. The Bootstrap project has been looking into this issue. You're likely familiar with Shiriam Krishnamurti's work. I'm lurking on the discussion list around Pyret, more active than math-thinking-l these days. https://www.wpi.edu/news/20156/mathcsci.html > In HS my CS teacher was a trained musician. He did fine teaching Basic, > but had no idea how to teach or program Pascal to the 5 or so of us in the > advanced class. I suspect a few years later he figured it out, and can now > teach it just fine. > > Can he teach math as well? More power to him if so. I'm thinking of Peter Farrell's book for example: Hacking Math Class. It has many of the usual calculus and pre-calculus topics. Students learn about trigonometry through coding. It's a step up from graphing calculators, in terms of technology. Imagine learning what composition of functions means in terms of Python. In math class. For math credit. From a math teacher. > There is the problem of hours in a day, and hours you can keep a person in > class. those are fixed, so if you want to add a minute teaching CS you do > need to decide what you will take a minute away from. Language? PE, > lunch... I'm glad this is not my problem. > My question is more like: should we bother teaching CS as a separate high school subject, if instead we might converge it with math. Is the decision to treat these as two separate disciplines appropriate? Isn't this rather a golden opportunity to show the relevance of mathematics to everyday life? Why not just keep teaching these newer skills under the heading of math and give math teachers the tools they need to add coding? That doesn't mean other subject teachers shouldn't update their skills as well. While teaching where the commas and periods go, and the semi-colons, we might as well add HTML, stuff about fonts, unicode and typography. That's all "Communications Arts" or whatever. In my Python classes we use the Periodic Table of Elements a lot, as a typical data structure. In other words, coding (including markup languages) might be shared more throughout STEM (or STEAM), not just in math class. I'm more explicit how I'm coming to look at it in this Youtube shared through my blog: http://controlroom.blogspot.com/2016/04/a-pep-talk-of-my-own.html Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Sat Aug 6 18:03:51 2016 From: kirby.urner at gmail.com (kirby urner) Date: Sat, 6 Aug 2016 15:03:51 -0700 Subject: [Edu-sig] after 40 hours.... (generic Python course) Message-ID: What level of Python do I expect students to read by Session 10 of 10? (40 hours, 2x week using Zoom.us) https://twitter.com/4DsolutionsPDX/status/762044675880394752 (links to Jupyter Notebook on Github via Twitter) This was for State of California. I think Oregon's math teachers would benefit from courses like this. That's a topic I tweet about using #CodeCastle as a hash tag. I do sometimes get the attention of state legislators and fellow traveler lobbyists per Facebook etc. We're gaining traction. Suggested reading from CERM Academy: https://digiday.com/publishers/survey-uk-us-publishers-believe-video-will-top-revenue-driver-differ-header-bidding/ http://www.advertisingweek.com/360/article/-the-gig- economy-is-all-about-hustling http://www.marketwatch.com/story/america-desperately- needs-to-redefine-college-and-career-ready-2016-08-05 Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Tue Aug 9 16:46:00 2016 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 9 Aug 2016 13:46:00 -0700 Subject: [Edu-sig] mixed messages about math... In-Reply-To: References: Message-ID: On Fri, Aug 5, 2016 at 2:10 PM, kirby urner wrote: > > I was just drafting another blog post for CERM Academy, > which manages streams of thought pieces going out to > subscribers, then warehoused in a WordPress site. [1] > > Update Aug 9: Here's a link to the article I ended up publishing, not through CERM as it turns out (Greg thought it maybe too specialized to a specific readership) but in a more "find its own way" environment: https://twitter.com/4DsolutionsPDX/status/762797526802059264 (a tweet that goes to my essay 'The Plight of High School Math Teachers', if curious). << SNIP >> [1] http://cermacademy.com/ Down at the moment, Greg expects it up and running in 24 hours. The code school featured by Greg's daughter Margaux for WorkingIT.com held it's Monday Night Flying Circus again last night: http://mybizmo.blogspot.com/2016/08/at-circus.html [ Here are some thumbnail profiles of personnel, by Margaux, Greg's daughter: http://workingit.com/blog/category/thought-leadership/ Introduces the director and her two daughters, a few years older than Margaux ] I like that we're eclectic, devoting whole evenings to JavaScript as much as Python. It's the synergies in this ecosystem that give us leverage, whereas "Python in a bottle" (no discussion of context) is too "night in a museum" right? Pays to "play well with others" (for real). If in Portland, swing by... https://www.flickr.com/photos/kirbyurner/albums/72157664766721643 (2626 SW Corbett) and also visit Portland Python User Group @ Urban Airship, interesting building in SW Portland: https://www.flickr.com/photos/kirbyurner/albums/72157655578412223 (ironically none of the buildings depicted, but still good for context) Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From funcalculus at gmail.com Wed Aug 10 14:51:02 2016 From: funcalculus at gmail.com (Peter Farrell) Date: Wed, 10 Aug 2016 11:51:02 -0700 Subject: [Edu-sig] Edu-sig Digest, Vol 157, Issue 6 In-Reply-To: References: Message-ID: Great links, Kirby, Love reading the stories of how the young programmers got their start on a website just to build worlds for their virtual pets. And the comment that programming is like solving a puzzle, and the great feeling you get when you solve a problem. Thanks, Peter On Wed, Aug 10, 2016 at 9:00 AM, wrote: > Send Edu-sig mailing list submissions to > edu-sig at python.org > > To subscribe or unsubscribe via the World Wide Web, visit > https://mail.python.org/mailman/listinfo/edu-sig > or, via email, send a message with subject or body 'help' to > edu-sig-request at python.org > > You can reach the person managing the list at > edu-sig-owner at python.org > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Edu-sig digest..." > > > Today's Topics: > > 1. Re: mixed messages about math... (kirby urner) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Tue, 9 Aug 2016 13:46:00 -0700 > From: kirby urner > To: "edu-sig at python.org" > Subject: Re: [Edu-sig] mixed messages about math... > Message-ID: > gmail.com> > Content-Type: text/plain; charset="utf-8" > > On Fri, Aug 5, 2016 at 2:10 PM, kirby urner wrote: > > > > > I was just drafting another blog post for CERM Academy, > > which manages streams of thought pieces going out to > > subscribers, then warehoused in a WordPress site. [1] > > > > > Update Aug 9: > > Here's a link to the article I ended up publishing, not through > CERM as it turns out (Greg thought it maybe too specialized > to a specific readership) but in a more "find its own way" > environment: > > https://twitter.com/4DsolutionsPDX/status/762797526802059264 > > (a tweet that goes to my essay 'The Plight of High School > Math Teachers', if curious). > > << SNIP >> > > [1] http://cermacademy.com/ > > Down at the moment, Greg expects it up and running in 24 hours. > > The code school featured by Greg's daughter Margaux for > WorkingIT.com held it's Monday Night Flying Circus again > last night: > > http://mybizmo.blogspot.com/2016/08/at-circus.html > > [ > > Here are some thumbnail profiles of personnel, by > Margaux, Greg's daughter: > > http://workingit.com/blog/category/thought-leadership/ > > Introduces the director and her two daughters, a few years > older than Margaux > > ] > > I like that we're eclectic, devoting whole evenings to JavaScript > as much as Python. It's the synergies in this ecosystem that > give us leverage, whereas "Python in a bottle" (no discussion > of context) is too "night in a museum" right? > > Pays to "play well with others" (for real). > > If in Portland, swing by... > > https://www.flickr.com/photos/kirbyurner/albums/72157664766721643 > (2626 SW Corbett) > > and also visit Portland Python User Group @ Urban Airship, > interesting building in SW Portland: > > https://www.flickr.com/photos/kirbyurner/albums/72157655578412223 > > (ironically none of the buildings depicted, but still good for context) > > Kirby > -------------- next part -------------- > An HTML attachment was scrubbed... > URL: 20160809/3700a3eb/attachment-0001.html> > > ------------------------------ > > Subject: Digest Footer > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > https://mail.python.org/mailman/listinfo/edu-sig > > > ------------------------------ > > End of Edu-sig Digest, Vol 157, Issue 6 > *************************************** > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jurgis.pralgauskis at gmail.com Mon Aug 15 05:05:35 2016 From: jurgis.pralgauskis at gmail.com (Jurgis Pralgauskis) Date: Mon, 15 Aug 2016 12:05:35 +0300 Subject: [Edu-sig] PyCharm EDU Message-ID: Hi, It proposes interesting approach with tasks/exercises course with automated checking. https://blog.jetbrains.com/pycharm/2016/08/welcome-pycharm-edu-3/ https://www.jetbrains.com/pycharm-edu/quickstart/ -- Jurgis Pralgauskis tel: 8-616 77613; Don't worry, be happy and make things better ;) http://galvosukykla.lt -------------- next part -------------- An HTML attachment was scrubbed... URL: From urner at alumni.princeton.edu Wed Aug 17 11:54:15 2016 From: urner at alumni.princeton.edu (Kirby Urner) Date: Wed, 17 Aug 2016 08:54:15 -0700 Subject: [Edu-sig] rounding out a Python course... In-Reply-To: References: Message-ID: On Wed, Aug 3, 2016 at 10:13 AM, kirby urner wrote: > > Having explored Jupyter Notebooks, our next task > was to dissect a simple Flask application, with an > API published here: > > http://thekirbster.pythonanywhere.com > > I'm providing more documentation and the source code these days, FYI. http://controlroom.blogspot.com/2016/08/dissecting-flask-app.html This is like a textbook example students might clone and hack on, to develop their skills. I'm featuring WSGI-Flask with a DB2 API to SQLite. The Flask app models returning both HTML and JSON, suggesting both human browsers and machines as clients. Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From amitsaha.in at gmail.com Wed Aug 17 20:03:35 2016 From: amitsaha.in at gmail.com (Amit Saha) Date: Thu, 18 Aug 2016 10:03:35 +1000 Subject: [Edu-sig] Doing Math with Python at PyCon Education Seminar Message-ID: Hey all, I spoke at the PyCon Australia Education Seminar. I really loved the energy of all the speakers. All the talks are here at: https://www.youtube.com/playlist?list=PLs4CJRBY5F1Jh6fFqT1p5TZRx5q06CcaR My talk is here: https://www.youtube.com/watch?v=XJOt4QQgx0A with the slides and demos here at https://github.com/doingmathwithpython/pycon-au-2016 Best Wishes, Amit. -- http://echorand.me From kirby.urner at gmail.com Thu Aug 18 14:33:35 2016 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 18 Aug 2016 11:33:35 -0700 Subject: [Edu-sig] Doing Math with Python at PyCon Education Seminar In-Reply-To: References: Message-ID: Great talk Amit! You were great dealing with an overtaxed kernel under time pressure, and really moved through a lot of substantive material, not wasting any time at all. Here's a screen shot exhibit of me tweeting to followers about your talk just now, with a link both to Youtube and back to here, this edu-sig archives: https://flic.kr/p/Km1ZZ7 "Math is an endless source of things to program and programming in itself is a useful skill-building activity" is my soft sell. The hard sell being "programming opens more doors into mathematics than other media, and aids the imagination more directly". Especially true when we add such as Pi3D and VPython, along with ray tracing (e.g. POV-ray [1]) to graphical equation plotting, thereby getting into Mandelbulb territory (a kind of 3D Mandelbrot). The graphical and the lexical blend together. Python helps us make "math cartoons" (that's not the only thing it does, but I've found it helpful in getting me there). Also good job showing off MathJax rendering mathematics with beautiful typography, in a way many self-respecting mathematicians hope to see it. [2] Kirby [1] http://4dsolutions.net/ocn/numeracy0.html [2] http://jupyter-notebook.readthedocs.io/en/latest/examples/Notebook/Typesetting%20Equations.html On Wed, Aug 17, 2016 at 5:03 PM, Amit Saha wrote: > Hey all, > > I spoke at the PyCon Australia Education Seminar. I really loved the > energy of all the speakers. All the talks are here at: > https://www.youtube.com/playlist?list=PLs4CJRBY5F1Jh6fFqT1p5TZRx5q06CcaR > > My talk is here: https://www.youtube.com/watch?v=XJOt4QQgx0A with the > slides and demos here at > https://github.com/doingmathwithpython/pycon-au-2016 > > Best Wishes, > Amit. -------------- next part -------------- An HTML attachment was scrubbed... URL: From amitsaha.in at gmail.com Fri Aug 19 02:09:01 2016 From: amitsaha.in at gmail.com (Amit Saha) Date: Fri, 19 Aug 2016 16:09:01 +1000 Subject: [Edu-sig] Doing Math with Python at PyCon Education Seminar In-Reply-To: References: Message-ID: Hello Kirby, On Fri, Aug 19, 2016 at 4:33 AM, kirby urner wrote: > > Great talk Amit! > > You were great dealing with an overtaxed kernel under time pressure, and > really moved through a lot of substantive material, not wasting any time at > all. > > Here's a screen shot exhibit of me tweeting to followers about your talk > just now, with a link both to Youtube and back to here, this edu-sig > archives: > > https://flic.kr/p/Km1ZZ7 Thank you! I think i have to start using Jupyter more so that I know how to make the best use of it or troubleshoot it when it hangs and even a kernel restart won;t help! But really love how it allows me to show the code and output together. I started using a custom.css file to increase the font size, so definitely improvement for me. > > "Math is an endless source of things to program and programming in itself is > a useful skill-building activity" is my soft sell. > > The hard sell being "programming opens more doors into mathematics than > other media, and aids the imagination more directly". > > Especially true when we add such as Pi3D and VPython, along with ray tracing > (e.g. POV-ray [1]) to graphical equation plotting, thereby getting into > Mandelbulb territory (a kind of 3D Mandelbrot). > > The graphical and the lexical blend together. Python helps us make "math > cartoons" (that's not the only thing it does, but I've found it helpful in > getting me there). > > Also good job showing off MathJax rendering mathematics with beautiful > typography, in a way many self-respecting mathematicians hope to see it. [2] Indeed, you add very nice points! I discovered the typography and the ability to zoom in while I was working on this. Best Wishes, Amit. > > Kirby > > [1] http://4dsolutions.net/ocn/numeracy0.html > > [2] > http://jupyter-notebook.readthedocs.io/en/latest/examples/Notebook/Typesetting%20Equations.html > > > > On Wed, Aug 17, 2016 at 5:03 PM, Amit Saha wrote: >> >> Hey all, >> >> I spoke at the PyCon Australia Education Seminar. I really loved the >> energy of all the speakers. All the talks are here at: >> https://www.youtube.com/playlist?list=PLs4CJRBY5F1Jh6fFqT1p5TZRx5q06CcaR >> >> My talk is here: https://www.youtube.com/watch?v=XJOt4QQgx0A with the >> slides and demos here at >> https://github.com/doingmathwithpython/pycon-au-2016 >> >> Best Wishes, >> Amit. > > -- http://echorand.me From kirby.urner at gmail.com Fri Aug 19 14:45:53 2016 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 19 Aug 2016 11:45:53 -0700 Subject: [Edu-sig] Fwd: Doing Math with Python at PyCon Education Seminar In-Reply-To: References: Message-ID: On Thu, Aug 18, 2016 at 11:09 PM, Amit Saha wrote: > > Thank you! I think i have to start using Jupyter more so that I know > how to make the best use of it or troubleshoot it when it hangs and > even a kernel restart won;t help! But really love how it allows me to > show the code and output together. I started using a custom.css file > to increase the font size, so definitely improvement for me. > > Yes, Jupyter is a part of the puzzle, when it comes to workflow, among students and teachers. I imagine students each booting the same Notebook on localhost while a teacher walks them through it on a big screen, demonstrating how it might be used and underlining what it teaches. However this model presumes each student has some localhost to boot jupyter-notebooks on. Is that a given. Will Chromebooks work? Can I run Anaconda on a Pi? This model could all be in lieu of, and/or in addition to, turning to page such and such in a non-interactive textbook, where no coding language is communicated, other than in non-executing typography. My attitude is not "here's how you must organize the workflow" so much as "lets innovate and experiment and learn all we can from each other, compare notes". However, creating a climate wherein innovation and experimentation are encouraged is no simple matter. We start with a stereotypical classroom wherein a single teacher is running in place on a treadmill (figuratively), with a set curriculum. There's plenty to do, a full plate, and "learning to code" is neither expected nor rewarded. The curriculum is the one thing a busy math teacher maybe doesn't need to spend extra time on, as the curriculum is handed down from above. That's the rock. The school district picks the textbook, not the teacher. I'm thinking we need keep a lot of "the rock" in terms of topics and their interconnections (what passes for highs school mathematics in our day) but then slide in this new tool layer based on Jupyter Notebooks in place of a scientific calculator, per your talk. That's a challenge however, and I think we need to broaden the consensus that "learning to code" and "learning math" are indeed consistent goals, synergetic in fact (whole > parts). The New Math cohort in 1960s US, was too "top down" in retrospect. I benefited from that curriculum (briefly, before transferring to Junior English School of Rome), a complete overhaul of the curriculum in reaction to Sputnik. The US had panic attack, ala War of the Worlds with Orson Welles.[1] But today, with China having just launched a first satellite aimed at testing quantum encryption technology, we're not just in some "history repeats itself" cycle. History spirals more than circles. For a shift in the math curriculum to happen (yet again), we need to stop "waiting for superman" in the guise of some army of computer scientists that will suddenly show up to develop an entirely new high school track called "computer science". Yes, we have AP CS, but it's nothing mainstream, doesn't come with math credit in most states, and is really more just Java-based computer science, not really high school mathematics with Jupyter Notebooks and Python. By expanding the mathematics offerings to include these "math through coding" experiments, we have the ability to leverage existing resources, meaning teachers already in the math teaching profession. That's close enough to work with. This was never a static field. Ultimately the goal is to rescue mathematics from its current status as "mandatory yet off-putting". I'm wanting math teachers themselves to drive the process, so grass-roots, not top-down. They'll be better positioned having made this investment. Learning to code is a positive career move for them as well. A somewhat different approach is to start with a different STEM subject, such as chemistry or physics, and using Jupyter Notebooks to teach that. I'm on a listserv for Physics teachers and have posted links to my Notebooks, for those maybe unfamiliar with this option. The scipy stack will then follow them on into college. Kirby I tweet this out every so often, including @MAAnow and @Teacher2Teacher etc. https://medium.com/@kirbyurner/the-plight-of-high-school-math-teachers- c0faf0a6efe6#.nfc8qv4hg -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Thu Aug 25 13:26:47 2016 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 25 Aug 2016 10:26:47 -0700 Subject: [Edu-sig] a Raspbian recipe for geometry teachers Message-ID: You might wonder what this has to do with Python, see notes at the end for a pure Python code stash. We also tend to think of the Raspberry Pi as a "Python computer" so anything Raspbian is of potential interest. Antiprism will convert OFF (geometry) files to POV (ray tracing) files. The Python + POV-ray synergy is still viable, though I've not attempted that. Looks like my next project, following the recipe here: https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=100529 In the meantime, lets do a workout using basic development tools: Unzip Adrian's tar.gz file from antiprism.com or clone his Github repository, and then install a GLUT clone if you don't already have one (the configure step will say it can't build antiview if you don't). sudo apt-get install freeglut3-dev g++ Then configure / compile / install: CPPFLAGS="-fsigned-char" ./configure make sudo make install-strip sudo ldconfig Read the docs and look at the many screen shots on his website for what you'll be able to do after that. In my case the Pi may simply generate OFF files, transform them into POV files, then offload to another machine for actual rendering. Screen shots: https://flic.kr/p/Ln3zeL https://flic.kr/p/Lom9uH Notes: I started with a plain vanilla Jessie distro of Raspbian. The steps above, including the need to maybe run ldconfig are spelled out in Adrian's README, which I suggest you go to first thing, if undertaking this cooking exercise. For math teachers new to "gnu math": some of the steps in the above recipe take quite awhile, starting with that very first process: getting a free OpenGL implementation. I went out and did yard and gardening work during the make step. Partake of some school-approved beverage and kick back. During ./configure, the script may appear to hang at some point at: fi (the end of a bash script if block i.e. if .... fi marks a block) and you'll maybe wonder if it's up to you to perform an intervention. Have faith, the script will say done when it's finished. The CPPFLAGS="-fsigned-char" relates to this issue: http://blog.cdleary.com/2012/11/arm-chars-are-unsigned-by-default/ Adrian diagnosed the issue only hours ago. Without that switch, it'll compile, and all the --help switches will work, but the many programs will report a command line error and not actually do the work. Adrian was able to grok the problem even without owning a Pi. He used this emulator instead: https://wiki.debian.org/RaspberryPi/qemu-user-static Many thanks to Adrian Rossiter for this brilliant and well-maintained spatial geometry library. He also has a large stash of free Python programs that cover some of this same territory: https://github.com/antiprism/antiprism_python/blob/master/README.md Kirby Urner @4DsolutionsPDX Portland Knowledge Lab VLM (a type of PWS) in Portland, Oregon -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Fri Aug 26 02:05:38 2016 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 25 Aug 2016 23:05:38 -0700 Subject: [Edu-sig] another Raspbian Recipe Message-ID: I did get povray 3.7 to compile on the Jessie distro that came with my Pi2. I'll link to another location for the details as this is not 100% about Python. Note however my link to the POV-Ray + Python stuff at my Oregon Curriculum Network website. https://www.raspberrypi.org/forums/viewtopic.php?p=1029037#p1029037 Adrian has written back to say the Github repo for Antiprism (linked from antiprism.com) no longer requires that special CPPFLAGS switch. Just ./configure should do the job (see previously posted Raspbian Recipe). These resources complement the Pi3D library, which is more like VPython (which might compile also?, now that I have boost?). Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Fri Aug 26 15:41:38 2016 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 26 Aug 2016 12:41:38 -0700 Subject: [Edu-sig] high school "Pythonic math": Vector as pivotal (+ addendum on recent recipes) Message-ID: Per these paragraphs to a listserv for Physics teachers -- to which I was invited by one Dr. Bob Fuller, a former AAPT chairman -- I'm underlining a Vector type as one of the hallmarks of high school math: === [ posted about 2.5 hours ago ] === Your remarks on fluency are well taken. I'm just about to post something to edu-sig about the Vector class (class as in "type of object") and its pivotal role in grades 9-12 (as we say in this namespace). That'd be along both the delta and lambda tracks, continuous and discrete. Luciano Ramalho has recently published the book 'Fluent Python' which is appearing in several languages (I've met the guy a few times, been in his workshops or seen them on video). Luciano does a really fluent Vector type, as many dimensions as you want. With operator overloading, you can add them (v1 + v2), scale them (3 * v1), multiply them by matrices to get more vectors. You could say, when applying a rotation matrix, that "it's the same vector, just moved" but more disciplined functional programmers prefer immutable objects begetting new immutable objects, minimizing hidden (contained) state. Even with OO languages, there's something called programming in a more functional way. 'Functional Python' by Mertz is another popular title. The sympy library has a Clifford Algebra bivector submodule that I've not played with yet. === ... continuing that thought ... Once you have the bare bones model, the mathematical Vector, then you get to wire it up to different strategies for rendering. A simple and mathematically correct approach has all Vectors originating at the origin, pointing to points, such that the edges of a Polyhedron around said origin are each defined by two endpoint Vectors. e = Edge(v0, v1). Rendering edges, vertexes and faces (E, V, F) is a common theme, regardless of rendering back and, be that ray tracer, Pi3D or what have you. This was my approach in stickworks.py -- separate model from visualization code to some degree. I experimented with tighter and looser coupling. Like if you can interactively make graphics happen in a window, from a REPL in real time, so much the better. http://4dsolutions.net/ocn/python/stickworks.py (source) https://youtu.be/4iMSGKXJ_Ds (Youtube intro) A wrinkle in my curriculum writing is we may go on to re-implement the Vector concept using "quadray coordinates" (see Wikipedia) per this Jupyter notebook: ' http://nbviewer.jupyter.org/github/4dsolutions/Python5/blob/master/Polyhedrons%20101.ipynb ' I'm thinking lots of math teachers might like to go this route, not necessarily starting with my source code or anyone else's in particular (maybe Luciano's) as an exercise in learning / teaching pure Python. --------------------------------- Addendum re Raspberry Pi, as a polyhedrons rendering machine (the theme of my last two posts): I'm still working with Adrian Rossiter on OpenGL issues. His antiview runs but is not yet rendering properly https://flic.kr/p/KBCcqy (messed up antiview view in upper right) probably because Pi use OpenGL ES, not what he'd coded for? I may see a fix? https://www.raspberrypi.org/forums/viewtopic.php?f=78&t=63264 However, when it comes to this pipeline: antiprism generating program -> OFF file -> off2pov -> POV -> povray things are working great: https://flic.kr/p/LoXhEG Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: