From vceder at canterburyschool.org Fri May 1 21:12:50 2009 From: vceder at canterburyschool.org (Vern Ceder) Date: Fri, 01 May 2009 15:12:50 -0400 Subject: [Edu-sig] PyCon poster session and Edu-sig pages In-Reply-To: References: <7528bcdd0904270912j64ff8390p30709ef4164d15e@mail.gmail.com> Message-ID: <49FB49B2.9080907@canterburyschool.org> Hi Kirby, Andre, everyone, Sorry for the late reply - things have been busy here... I was also thinking we need a short mention and a link on the edu-sig home page to some info about the PyCon education/poster session. I haven't pitched this to the PyCon organizers yet, so we don't need to act immediately, but I'm thinking/hoping to have something more formed by the middle of the summer. Then we can link from the the edu-sig page to a wiki page on the PyCon site. The general idea is to provide a space at PyCon for educators to show off what they've been doing with Python, whether or not they can attend PyCon. This not only would raise the profile of Python in education, but would also give us all a target to aim for and a way of recording/sharing our gains. Right now what I'm thinking about suggesting/asking for is: 1. Display space in fairly public place. I'm thinking space for posters, a few tables for demos, some standing-around-and-talking space, etc. 2. Offer poster spots to anyone with an educational project, whether they can attend or not. Of course, if they can attend and stand around their poster during a designated session time, so much the better. OTOH, if they can't attend they might be able to recruit a stand-in from those attending, and at the very least they will be able to get the word out about what they are doing. BTW, I would see a "poster space" being anything from a chunk of wall space for displaying a couple of posters to some table space for demos, etc. The details of that will depend on what the PyCon organizers will be able (and willing) to offer. Other ideas include graffiti posters for attendees to add projects, notes and comments, ala PyOhio (see http://wiki.python.org/moin/PyOhio2008/PosterSession), encouraging lightning talks, and submitting a "State of Python in Education" talk for consideration in the regular program. Cheers, Vern kirby urner wrote: > Another thought is maybe edu-sig page is appropriate place to > provide contact info for Vern Ceder. The thought there is to have > someone to help coordinate a more academically flavored poster space > wherein we showcase interesting applications of Python where the > sponsor (helping pay for hotel floorspace) might not be a private > company booth exhibitor but a university or NGO or publisher or > whatever. > > User groups might have their own contests why not? > > I'm not saying the edu-sig page should get into all this, as it aims > to stay brief and uncluttered, just thinking we need some way to > suggest the "science fair" aspect of future Pycons (the idea > originates with Steve Holden in response to BOF-expressed desires to > get teachers more involved, Pycon having a predominantly business > flavor, with Jeff Rush going so far as to suggest a whole separate > EduPycon, which idea I've continued to float, as worthy of > consideration, including in edu-sig threads why not? > > These slides from some random GIS conference in Oregon, where I talked > about Python (familiar through ESRI), show what a conference is like > when split between private companies and academia, I'm sure a familiar > site to most of you already, just not quite what Pycon has been like > (which is where Vern comes in): > > http://worldgame.blogspot.com/2009/04/gis-2009.html > > Somewhat unrelated, I'd welcome any comments on my What is a Scripting > Language? answer, something I might point to in a kind of FAQ mode > (emailed question about Python being "a scripting language"). > > BTW I'm glad the edu-sig page still points to Software Carpentry under > Miscellaneous (where we also link to my stuff) as I think we're also a > gateway for system administrator types who choose a non-CS degree path > (similar to the math track people we're tagging with the aforesaid > title mentioned below). > > http://controlroom.blogspot.com/2009/04/whats-scripting-language.html > > CP4E and/or P4E never meant turning everyone into CS majors right? We > should make sure that the "education" in edu-sig is far broader than > CS departments reaching out, advertising they teach in that language > (among others), although they're welcome to do that of course (we > welcome "converts" or whatever). > > Kirby > > > On Mon, Apr 27, 2009 at 9:15 AM, kirby urner wrote: >> Both, per the back cover: >> >> """ >> Some students may choose to study AP Computer Science in high school, >> or major in CS in college. Others may decide to go into math, >> science, law, art, social sciences, or humanities. Regardless of your >> goals, Mathematics for the Digital Age and Programming in Python will >> help you gain a better understanding of the computerized world around >> you. >> """ >> >> ... definitely looking at high school in Oregon, on a math track, not >> a CS track per se, as the Silicon Forest lobby here is working with >> our state legislature to have discrete math alternatives that segue to >> college and private industry tracks, e.g. we could use this in place >> of Algebra 2. >> >> Kirby >> >> >> On Mon, Apr 27, 2009 at 9:12 AM, Andre Roberge wrote: >>> >>> On Mon, Apr 27, 2009 at 1:07 PM, kirby urner wrote: >>>> http://www.skylit.com/mathandpython.html >>>> >>>> I have desk review copy, think many will appreciate the quasi-seamless >>>> blend of old and gnu world typographies, i.e. sigma and set notation, >>>> with concepts of iterator, types, functions etc. >>> Would this be appropriate for high school students, or as a first CS course >>> for non Computer Science majors ? >>> >>> Andr? >>> >>>> Reminiscent of 'Concrete Mathematics' though less difficult and >>>> explicitly Python based. >>>> >>>> For those training to read algebra, higher math, this is a friendly >>>> introduction (no cartoons or comics though -- gets you prepared for >>>> the somber dryness of the ambient literature). >>>> >>>> Kirby >>>> _______________________________________________ >>>> Edu-sig mailing list >>>> Edu-sig at python.org >>>> http://mail.python.org/mailman/listinfo/edu-sig >>> > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig From aharrin at luc.edu Fri May 1 23:02:22 2009 From: aharrin at luc.edu (Andrew Harrington) Date: Fri, 1 May 2009 16:02:22 -0500 Subject: [Edu-sig] PyCon poster session and Edu-sig pages In-Reply-To: <49FB49B2.9080907@canterburyschool.org> References: <7528bcdd0904270912j64ff8390p30709ef4164d15e@mail.gmail.com> <49FB49B2.9080907@canterburyschool.org> Message-ID: +1 Andy On Fri, May 1, 2009 at 2:12 PM, Vern Ceder wrote: > Hi Kirby, Andre, everyone, > > Sorry for the late reply - things have been busy here... > > I was also thinking we need a short mention and a link on the edu-sig > home page to some info about the PyCon education/poster session. > > I haven't pitched this to the PyCon organizers yet, so we don't need to > act immediately, but I'm thinking/hoping to have something more formed > by the middle of the summer. Then we can link from the the edu-sig page to > a wiki page on the PyCon site. > > The general idea is to provide a space at PyCon for educators to show > off what they've been doing with Python, whether or not they can attend > PyCon. This not only would raise the profile of Python in education, but > would also give us all a target to aim for and a way of recording/sharing > our gains. > > Right now what I'm thinking about suggesting/asking for is: > > 1. Display space in fairly public place. I'm thinking space for posters, > a few tables for demos, some standing-around-and-talking space, etc. > > 2. Offer poster spots to anyone with an educational project, whether > they can attend or not. Of course, if they can attend and stand around > their poster during a designated session time, so much the better. OTOH, if > they can't attend they might be able to recruit a stand-in from those > attending, and at the very least they will be able to get the word out about > what they are doing. > > BTW, I would see a "poster space" being anything from a chunk of wall space > for displaying a couple of posters to some table space for demos, etc. The > details of that will depend on what the PyCon organizers will be able (and > willing) to offer. > > Other ideas include graffiti posters for attendees to add projects, notes > and comments, ala PyOhio (see > http://wiki.python.org/moin/PyOhio2008/PosterSession), encouraging > lightning talks, and submitting a "State of Python in Education" talk for > consideration in the regular program. > > Cheers, > Vern > > > -- Andrew N. Harrington Director of Academic Programs Computer Science Department Loyola University Chicago 512B Lewis Towers (office) Snail mail to Lewis Towers 416 820 North Michigan Avenue Chicago, Illinois 60611 http://www.cs.luc.edu/~anh Phone: 312-915-7982 Fax: 312-915-7998 gpd at cs.luc.edu for graduate administration upd at cs.luc.edu for undergrad administration aharrin at luc.edu as professor -------------- next part -------------- An HTML attachment was scrubbed... URL: From andre.roberge at gmail.com Sat May 2 00:32:18 2009 From: andre.roberge at gmail.com (Andre Roberge) Date: Fri, 1 May 2009 19:32:18 -0300 Subject: [Edu-sig] PyCon poster session and Edu-sig pages In-Reply-To: <49FB49B2.9080907@canterburyschool.org> References: <7528bcdd0904270912j64ff8390p30709ef4164d15e@mail.gmail.com> <49FB49B2.9080907@canterburyschool.org> Message-ID: <7528bcdd0905011532h7f4127d9wdd7c5a704010ef24@mail.gmail.com> On Fri, May 1, 2009 at 4:12 PM, Vern Ceder wrote: > Hi Kirby, Andre, everyone, > > Sorry for the late reply - things have been busy here... > > I was also thinking we need a short mention and a link on the edu-sig > home page to some info about the PyCon education/poster session. > This (and the more detailed information below) sounds like a great idea. I will try to work on the edu-sig home page again soon, incorporating additional links to book (and probably reorganizing the book and tutorial section). However, if may take a little while (perhaps a couple of weeks) as this is a busy time of the year for my regular "day" job. Rather than bore you with details, I'll leave it up to your imagination (for those that know what I do). Andr? > > I haven't pitched this to the PyCon organizers yet, so we don't need to > act immediately, but I'm thinking/hoping to have something more formed > by the middle of the summer. Then we can link from the the edu-sig page to > a wiki page on the PyCon site. > > The general idea is to provide a space at PyCon for educators to show > off what they've been doing with Python, whether or not they can attend > PyCon. This not only would raise the profile of Python in education, but > would also give us all a target to aim for and a way of recording/sharing > our gains. > > Right now what I'm thinking about suggesting/asking for is: > > 1. Display space in fairly public place. I'm thinking space for posters, > a few tables for demos, some standing-around-and-talking space, etc. > > 2. Offer poster spots to anyone with an educational project, whether > they can attend or not. Of course, if they can attend and stand around > their poster during a designated session time, so much the better. OTOH, if > they can't attend they might be able to recruit a stand-in from those > attending, and at the very least they will be able to get the word out about > what they are doing. > > BTW, I would see a "poster space" being anything from a chunk of wall space > for displaying a couple of posters to some table space for demos, etc. The > details of that will depend on what the PyCon organizers will be able (and > willing) to offer. > > Other ideas include graffiti posters for attendees to add projects, notes > and comments, ala PyOhio (see > http://wiki.python.org/moin/PyOhio2008/PosterSession), encouraging > lightning talks, and submitting a "State of Python in Education" talk for > consideration in the regular program. > > Cheers, > Vern > > > kirby urner wrote: > >> Another thought is maybe edu-sig page is appropriate place to >> provide contact info for Vern Ceder. The thought there is to have >> someone to help coordinate a more academically flavored poster space >> wherein we showcase interesting applications of Python where the >> sponsor (helping pay for hotel floorspace) might not be a private >> company booth exhibitor but a university or NGO or publisher or >> whatever. >> >> User groups might have their own contests why not? >> >> I'm not saying the edu-sig page should get into all this, as it aims >> to stay brief and uncluttered, just thinking we need some way to >> suggest the "science fair" aspect of future Pycons (the idea >> originates with Steve Holden in response to BOF-expressed desires to >> get teachers more involved, Pycon having a predominantly business >> flavor, with Jeff Rush going so far as to suggest a whole separate >> EduPycon, which idea I've continued to float, as worthy of >> consideration, including in edu-sig threads why not? >> >> These slides from some random GIS conference in Oregon, where I talked >> about Python (familiar through ESRI), show what a conference is like >> when split between private companies and academia, I'm sure a familiar >> site to most of you already, just not quite what Pycon has been like >> (which is where Vern comes in): >> >> http://worldgame.blogspot.com/2009/04/gis-2009.html >> >> Somewhat unrelated, I'd welcome any comments on my What is a Scripting >> Language? answer, something I might point to in a kind of FAQ mode >> (emailed question about Python being "a scripting language"). >> >> BTW I'm glad the edu-sig page still points to Software Carpentry under >> Miscellaneous (where we also link to my stuff) as I think we're also a >> gateway for system administrator types who choose a non-CS degree path >> (similar to the math track people we're tagging with the aforesaid >> title mentioned below). >> >> http://controlroom.blogspot.com/2009/04/whats-scripting-language.html >> >> CP4E and/or P4E never meant turning everyone into CS majors right? We >> should make sure that the "education" in edu-sig is far broader than >> CS departments reaching out, advertising they teach in that language >> (among others), although they're welcome to do that of course (we >> welcome "converts" or whatever). >> >> Kirby >> >> >> On Mon, Apr 27, 2009 at 9:15 AM, kirby urner >> wrote: >> >>> Both, per the back cover: >>> >>> """ >>> Some students may choose to study AP Computer Science in high school, >>> or major in CS in college. Others may decide to go into math, >>> science, law, art, social sciences, or humanities. Regardless of your >>> goals, Mathematics for the Digital Age and Programming in Python will >>> help you gain a better understanding of the computerized world around >>> you. >>> """ >>> >>> ... definitely looking at high school in Oregon, on a math track, not >>> a CS track per se, as the Silicon Forest lobby here is working with >>> our state legislature to have discrete math alternatives that segue to >>> college and private industry tracks, e.g. we could use this in place >>> of Algebra 2. >>> >>> Kirby >>> >>> >>> On Mon, Apr 27, 2009 at 9:12 AM, Andre Roberge >>> wrote: >>> >>>> >>>> On Mon, Apr 27, 2009 at 1:07 PM, kirby urner >>>> wrote: >>>> >>>>> http://www.skylit.com/mathandpython.html >>>>> >>>>> I have desk review copy, think many will appreciate the quasi-seamless >>>>> blend of old and gnu world typographies, i.e. sigma and set notation, >>>>> with concepts of iterator, types, functions etc. >>>>> >>>> Would this be appropriate for high school students, or as a first CS >>>> course >>>> for non Computer Science majors ? >>>> >>>> Andr? >>>> >>>> Reminiscent of 'Concrete Mathematics' though less difficult and >>>>> explicitly Python based. >>>>> >>>>> For those training to read algebra, higher math, this is a friendly >>>>> introduction (no cartoons or comics though -- gets you prepared for >>>>> the somber dryness of the ambient literature). >>>>> >>>>> Kirby >>>>> _______________________________________________ >>>>> Edu-sig mailing list >>>>> Edu-sig at python.org >>>>> http://mail.python.org/mailman/listinfo/edu-sig >>>>> >>>> >>>> _______________________________________________ >> Edu-sig mailing list >> Edu-sig at python.org >> http://mail.python.org/mailman/listinfo/edu-sig >> > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirby.urner at gmail.com Sat May 2 21:18:29 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sat, 2 May 2009 12:18:29 -0700 Subject: [Edu-sig] PyCon poster session and Edu-sig pages In-Reply-To: <7528bcdd0905011532h7f4127d9wdd7c5a704010ef24@mail.gmail.com> References: <7528bcdd0904270912j64ff8390p30709ef4164d15e@mail.gmail.com> <49FB49B2.9080907@canterburyschool.org> <7528bcdd0905011532h7f4127d9wdd7c5a704010ef24@mail.gmail.com> Message-ID: Thanks Andre. I don't see any big rush, as it's not like we're sitting on exclusive information. Python.org is primarily about the actual Python releases and the docs that go with them, the rest being icing on the cake (good icing though, with edu-sig page just getting better and better). Thanks for stepping up to the plate Vern. I think it'll change the flavor of Pycon for the better to have more of the unsung heroes present by poster, if not in person. We've had more CS profs than in the early days, as Python slowly catches on in that subculture, but lets not forget our roots. What we have in PacNW area are a lot of Mercy Corps type operations that wanna field geeks almost like those old "comm guys" in the war movies (lugging radar, usually blown to bits in an early scene, always a replacement ready, until the equipment itself breaks, at which point our hero... anyway, Rambo movies suck so fahgeddaboutit). OSCON has the booths to sign up at. Domestic options available. I'm thinking civilian civil service is still an attraction option for a high school grad seeking challenges, cybertool mastery giving a whole new point of entry, next to doctors without borders for example, as treatment really makes no sense without charting i.e. it's not a "one time through" line-up, but a repeat visit regime (if it's a real clinic, not just some made-for-TV fund raising gimmick). Then you come back from the field more ready to pick a degree track, having seen some front lines. Take our CFO for example (talking Coffee Shops again), she trained in an Uzbek leper colony before heading into real estate and owning Fine Grind, worked for orphans (is one). Or take our CSO, went to Antioch only after serving as code cracker for NSA in a forward position. Academics comes later, but you need Python, other FOSS boss skills, right out of the box, no time for CS degree before deployment, maybe only a little foreign language (e.g. creole, if heading into post-Katrina). I like that Richard Stallman visited Sri Lanka and both Tamil and Sinhalese have a foothold in Unicode, meaning native language source code in both places, a possibility anyway, with OLPC. You want XO-style mesh networking to frustrate gang control of comms, where you think you have a right to choose other peoples' friends (some tyrannical state). What keeps ethnicities polarized is as old as West Side Story and Romeo & Juliet: family feuds. I'm thinking OS Bridge will be a good place for networking, but it's advance planning for conferences that's often the real work, as I've discovered with Quakers, doing Future of Friends last year. Rewarding though. My role with OS Bridge thus far has been much lighter (seems like that marketing guy is really working hard), a lot of it chronicled in open source archives like this one, sometimes blog-linked for future reference, e.g.: http://mybizmo.blogspot.com/search?q=%22OS+Bridge%22 Anyway, edu-sig is looking just great these days, basking in the reflected glory of Python itself -- a good place to be, so lets make the most of it. Kirby On Fri, May 1, 2009 at 3:32 PM, Andre Roberge wrote: > > > On Fri, May 1, 2009 at 4:12 PM, Vern Ceder > wrote: >> >> Hi Kirby, Andre, everyone, >> >> Sorry for the late reply - things have been busy here... >> >> I was also thinking we need a short mention and a link on the edu-sig >> home page to some info about the PyCon education/poster session. > > This (and the more detailed information below) sounds like a great idea.? I > will try to work on the edu-sig home page again soon, incorporating > additional links to book (and probably reorganizing the book and tutorial > section).? However, if may take a little while (perhaps a couple of weeks) > as this is a busy time of the year for my regular "day" job.? Rather than > bore you with details, I'll leave it up to your imagination (for those that > know what I do). > > Andr? > From kirby.urner at gmail.com Tue May 5 17:46:35 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 5 May 2009 08:46:35 -0700 Subject: [Edu-sig] Update on my PSF doings Message-ID: I've been enjoying learning something of the internal organs involved in British education, thanks to working with Dr. Ian Benson on various proposals before the PSF regarding some math through programming initiatives (actually, just the one proposal at the moment, dubbed NiceTime [tm], a kind of wordplay if you know said organs (which I don't, or just barely)).[0] Anyway, for those of you into math teaching (just a few of us on edu-sig), the counterpart of the USA's NCTM (following me on Twitter since the BOF at the last conference), is the ATM, founded by Caleb Gattegno and at one time a vector (in the CDC sense) for a positive strain of math teaching centered around those colored blocks or bricks we associate with the name cuisenaire (Belgian guy) -- not to be confused with Cuisinart if you're an American).[1] Given Dr. Ian has been to my last too Chicago presentations, he's well aware that OCN is in the math education business. In the Portland context, I keep at cube a CubeSpace for intermittent use, which is our geek hogwarts for adult professional, home of Portland Barcamp, most the user group meetings (not OpenGIS though). Our geek hogwarts for middle schoolers is Winterhaven, where I taught Python at the 8th grade level using some GIS concepts ("hello world" means booting up Google Earth and saying "hello" -- or stick in a push-pin and grab the KML more likely).[2] A few pilot schools have staying with Gattegno's original concepts more or less and have qualified for special attention. They're eying Python among other FOSS offerings as possibly contiguous, now that their students are all algebra savvy and chomping at the bit for more challenges. But of course our audience is teachers and empowering them. This is where the NiceTime proposal comes in. As many of you know, OCN is into futuristic stuff, sort of at the other end of the spectrum from ultra-conservative. I use the "rib cage" operations of __add__, __mul__ and their inverses with multiple "math objects" in order to generate an algebraic sense of group, ring and field properties. When you define the "same" operations across matrices, rational numbers (Q objects), integers modulo N etc., you end up grasping higher level mathematics more successfully, or at least that's the theory. [3] We want this layer of abstraction so our dive into RSA and/or Diffie-Hellman-Merkle doesn't feel like some out of the blue math club activity or after school foray. We want abstract algebra more intrinsic to the curriculum and think Python, operator overloading in particular, will make this doable. Of course this early in the game and it's by no means obvious: (a) that NiceTime will be approved (this is a 2nd pass already, Steve's attitude being "if at first you don't succeed..." -- he's been encouraging of Dr. Ian's process, knows he's just one more voice in the directorship, albeit the chairman) (b) that exotic Made in Oregon content will be what teachers are wanting to tackle, this being a UK project after all. My materials are already FOSS and on the Web, including as videos, so it's not like I really need to lift a finger or anything (the Web is like magical in that way, wouldn't have much FOSS without it). What I'm pretty sure the teachers won't want, because too futuristic, is my Sqlite + Vpython lesson plans, where I take related tables stuffed with vector coordinates of polyhedra and draw those on screen. Gattegno's curriculum is called AlgebraFirst for a reason (Ian also works with algebra.org in NY), whereas at OCN I'm into GeometryFirst, tempting Montessori schools with my Mites, Sytes and Kites, sometimes using CubeIt! (from Huntar company), other manipulables.[4] This is what got me in hot water with NCTM years ago when they changed their logo from looking like an octet-truss (relates to this geometry) to an infinity symbol with stronger lawyer protections (like PSF, they were worried about losing control of their branding, actually were losing control in this case).[5] The politics here is Bucky Fuller was a cold warrior type, honored by then president Reagan with a Medal of Freedom but hated and feared by just about everyone else (except artists, hippies, other "live in the moment" types). To this day, if you talk about space-filling Mites in a math teaching context, you're likely to get run out of town (unless the town is Portland, in which case you're allowed to teach this material through Saturday Academy, with the blessings of Silicon Forest -- but this town is unusual in that respect, a FOSS capital).[6] So for now I'm mostly sticking to algebra and the transferable "rib cage" concept, thinking to walk teachers through these "math objects" with interactive capabilities. Having this new discrete math title (brought to my attention by Software Association of Oregon, which has designs similar to mine, in terms of FOSS in the schools) is a boost, especially the section on polynomials and their treatment as algebraic objects (i.e. you can add and multiply two polynomials no problem, with closure in both cases). I'm pretty sure NiceTime is on board with the cryptography stuff at least in storyboard. Dr. Ian supplied a short video clip to my 3 hour workshop (first 57 minutes syndicated through Blip TV) authorized for that one viewing only, regarding DHM use at Amazon. It was a kid-friendly Discovery channel segment, about public key cryptography more generally, so also suitable for RSA, which is what I've been going over (Andy Harrington supplied some improvements as well).[7] One example of a high school project that might merit a poster at Pycon someday would be to dig through the Mozilla code base and find the https bits, maybe convert those to running Python. It's possible to take lower level C code and recast it as inanely verbose and unpythonic Python that nevertheless runs and, by imitating the C, gives Python readers a first inkling of what a lower level language is like (many won't know). Anyway, that's one idea. I've been very up front with both Steve (holdenweb.com) and Dr. Ian though: I'm still pretty focused on South Africa and Lesotho (my family HQS was the latter mountain kingdom for like 7 years, transferring from another mountain kingdom in the Himalayas). Archbishop Tutu (like Dr. Ian, a King's College grad) was in town last night, yakking about ubuntu and all that good stuff, inspiring my home sickness for Cape Town. Jackalope is looking good by the way. But it's not either/or is it? My role in all this, as a noob with PSF (incoming Class of '09), is simply to look over Steve's shoulder and watch the process. I'm not being asked to vote and there's nothing in the proposed budget to buy any of my services. I've got other irons in the fire when it comes to teacher trainings, but really like this idea that the UK is looking at FOSS outside any strictly CS teaching context (which I think way too narrow, unlike CP4E's). Kirby 4D [0] http://www.ncetm.org.uk/ (i.e. NiCETiMe) [1] http://worldgame.blogspot.com/search?q=cuisenaire http://www.cuisinart.com/ (not to be confused with) [2] http://www.4dsolutions.net/ocn/winterhaven/ (FOSS @ geek hogwarts) [3] example explanation in math teaching context: http://mathforum.org/kb/plaintext.jspa?messageID=6692550 [4] http://controlroom.blogspot.com/2009/03/matrix-of-sytes.html (re manipulables, I haven't even opened my shrink wrapped StrangeAttractors because the factory burned to the ground, making it a collector's item -- told Chris Brooks of SAO it was "my retirement" at Bagdad lunch meeting -- being somewhat facetious (I did the box graphics using Python + POV-Ray, actually got paid for it). We had an all-6th grade assembly at geek hogwarts to learn about this geometry, build left and right A modules as a group process: http://mybizmo.blogspot.com/search?q=sixth+grade [5] http://www.grunch.net/synergetics/ncmtmemo.html (hah hah, I'm still such a noob back then, don't even get the acronym right in the URL, but you see the old logo there). [6] "cold warrior" in the sense of American industrial complex in competition with USSR's (didn't help matters that Fuller's primary collaborator on his magnum opus, dubbed "Sonny" because of their close relationship, was also a well-known cold warrior in his own right). Dr. Ian and Steve kindly joined my last day of Pycon to see 'Starting with the Universe' at Chicago Museum of Contemporary Art, per slides. More on "suspicion of Bucky" (occasional hatred) in the new bio on H.S.M. Coxeter (Canadian), to whom 'Synergetics' is dedicated (they were friends in the end), 'The King of Infinite Space' (lots more gossip via CSN if interested). [7] Dr. Ian is in touch with Whit, CSO for Sun these days (he is also well connected at SU ( http://stanford.edu/~ibenson/ )) See: http://osgarden.appspot.com/motd.html for some additional context. From kirby.urner at gmail.com Tue May 5 18:55:00 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 5 May 2009 09:55:00 -0700 Subject: [Edu-sig] Update on my PSF doings In-Reply-To: References: Message-ID: On Tue, May 5, 2009 at 8:46 AM, kirby urner wrote: > I've been enjoying learning something of the internal organs involved > in British education, thanks to working with Dr. Ian Benson on various > proposals before the PSF regarding some math through programming > initiatives (actually, just the one proposal at the moment, dubbed > NiceTime [tm], a kind of wordplay if you know said organs (which I > don't, or just barely)).[0] And now I get to interleave into my own post, noticing typos (sigh). I expect by a year from now I'll have a much better handle on the UK scene. I started out with London Knowledge Lab on my radar from some years back (summit meeting with Alan Kay et al), coming back to Portland (PDX, not in Maine) all hot to trot, started Portland Knowledge Lab on 8th & Main at our DWA office (my late wife's studio, repurposed, then closed owing to anemic Wifi, long story). > Anyway, for those of you into math teaching (just a few of us on > edu-sig), the counterpart of the USA's NCTM (following me on Twitter > since the BOF at the last conference), is the ATM, founded by Caleb > Gattegno and at one time a vector (in the CDC sense) for a positive > strain of math teaching centered around those colored blocks or bricks > we associate with the name cuisenaire (Belgian guy) -- not to be > confused with Cuisinart if you're an American).[1] The NCTM BOF I'm referring to is something I tracked through the blogs, not saying I was there (I wasn't). Here's a link: http://worldgame.blogspot.com/2009/04/discrete-math-track.html (previously posted to this archive) > Given Dr. Ian has been to my last [two] Chicago presentations, he's well > aware that OCN is in the math education business. ?In the Portland > context, I keep [a] cube [at] CubeSpace for intermittent use, which is our > geek hogwarts for adult professional[s], home of Portland Barcamp, most > the user group meetings (not OpenGIS though). ?Our geek hogwarts for > middle schoolers is Winterhaven, where I taught Python at the 8th > grade level using some GIS concepts ("hello world" means booting up > Google Earth and saying "hello" -- or stick in a push-pin and grab the > KML more likely).[2] > Link to Cubespace: http://cubespacepdx.com/ Helps to have Calagator if you really want to stay up on events, see right margin of CSN blog (all the PPUGers know about it). http://coffeeshopsnet.blogspot.com > A few pilot schools have staying with Gattegno's original concepts > more or less and have qualified for special attention. ?They're eying > Python among other FOSS offerings as possibly contiguous, now that > their students are all algebra savvy and chomping at the bit for more > challenges. ?But of course our audience is teachers and empowering > them. ?This is where the NiceTime proposal comes in. > > As many of you know, OCN is into futuristic stuff, sort of at the > other end of the spectrum from ultra-conservative. ?I use the "rib > cage" operations of __add__, __mul__ and their inverses with multiple > "math objects" in order to generate an algebraic sense of group, ring > and field properties. ?When you define the "same" operations across > matrices, rational numbers (Q objects), integers modulo N etc., you > end up grasping higher level mathematics more successfully, or at > least that's the theory. [3] Of course this could all seem ultra-conservative in retrospect, but in 2009 this all seems breath-takingly avant-garde. The "group theory for children" idea is in retreat, with everyone focused on remediating a borked precalculus track which almost everyone hates, but ETS keeps nailed, turning NCTM schools into slave ships. How sad for them. They don't even allow YouTube in many schools, not even for teachers projecting math-related content (there's *a lot* plus assigning students to make them gives them important video editing skills, video being the native language of youth culture in many ways -- why we put such stress on these skills in our leadership trainings through LAAP/AFSC (another long success story)). Dark ages were us. > We want this layer of abstraction so our dive into RSA and/or > Diffie-Hellman-Merkle doesn't feel like some out of the blue math club > activity or after school foray. ?We want abstract algebra more > intrinsic to the curriculum and think Python, operator overloading in > particular, will make this doable. > This whole idea of doing "computer clubs" around the edges while meanwhile the stupid hamster-brained calculators enjoy a quasi-monopoly over computer programming in math is just one more "canary in a mineshaft" indicator. Obviously the Obama administration's promised "world class education" is going to upset this applecart, if we have any hope of competing with the rest of the world ("we" being USAers -- like what's on my passport). That's what the NCTM BOF was about, how to really make use of the new technologies, not just give lip service to "technology in the classroom" (as if calculators were all that could possibly mean). > Of course this early in the game and it's by no means obvious: > > (a) that NiceTime will be approved (this is a 2nd pass already, > Steve's attitude being "if at first you don't succeed..." -- he's been > encouraging of Dr. Ian's process, knows he's just one more voice in > the directorship, albeit the chairman) > > (b) that exotic Made in Oregon content will be what teachers are > wanting to tackle, this being a UK project after all. ?My materials > are already FOSS and on the Web, including as videos, so it's not like > I really need to lift a finger or anything (the Web is like magical in > that way, wouldn't have much FOSS without it). > I've been recommending the documentary 'Revolution OS' which I excerpt in my Saturday Academy classes. Here's a synopsis (quoting from one of my recent emails): """ Not sure if you've seen 'Revolution OS' (documentary film, show excerpts in my classes sometimes) with extended interviews with Stallman, also Torvalds, many other top players (MVPs), but it pays to understand the ambivalence twixt grad students doing all the hard CS work, building Unix, only to be kicked out the door with degree, made to fend for themselves in high licensing fee world, Unix unaffordable, yet really their home, which they'd build. FreeBSD, not just Linux, was the subversive reaction developed with fanatical red gleam of revenge for shabby treatment, and Mac OS X piggy backs on that I understand, though inherits from NeXT as well and who knows what all, haven't read many books on it yet. We're talking POSIX in any case, with Windows hard pressed to play outlier, especially on the server side, but really has a nice desktop -- and cygwin. Microsoft and IBM have their own interesting history with abortive OS/2, lots of bad blood actually, which might also add to IBM's glee in watching Linux trounce MS in many a strategic area (but then lots of us have been enjoying that, not just IBM). In any case, going back to the FOSS story per 'Revolution OS', a lot of academics, CS professors in particular, were clearly not about to lift a finger against proprietary software, had comfy positions and if having to pay high fees to use Unix was a big barrier to entry, so much the better, more job security for them, never mind their students were getting shoved into an unforgiving world sans the very tools they'd worked hardest on to produce. Hence GNU. See it as backlash (against some projection of the university as shill for unearned power, AT&T or whatever) and you'll understand better. Wolfram versus Cal Tech follows much the same lines. Bill Gates left Harvard early. A theme here: FOSS is creating its own culture *in parallel* with sell-outs still on the inside. The impulse, now that we're strong and hardy, is to turn on the hand that didn't feed us when it mattered (the smug faculties who didn't teach *ethics* -- Stallman is an ethical philosopher) -- and kill it. """ > What I'm pretty sure the teachers won't want, because too futuristic, > is my Sqlite + Vpython lesson plans, where I take related tables > stuffed with vector coordinates of polyhedra and draw those on screen. > ?Gattegno's curriculum is called AlgebraFirst for a reason (Ian also > works with algebra.org in NY), whereas at OCN I'm into GeometryFirst, > tempting Montessori schools with my Mites, Sytes and Kites, sometimes > using CubeIt! (from Huntar company), other manipulables.[4] > It's not that the SQL based approach is controversial -- that's actually a pretty good idea I expect many will copy -- it's the volumes column most teachers won't like. I use simple whole numbers (integers actually) in place of the floating points they're used to for these same shapes, and that makes them angry. > This is what got me in hot water with NCTM years ago when they changed > their logo from looking like an octet-truss (relates to this geometry) > to an infinity symbol with stronger lawyer protections (like PSF, they > were worried about losing control of their branding, actually were > losing control in this case).[5] > What's an octet-truss? Glad you asked: http://www.grunch.net/synergetics/octet.html > The politics here is Bucky Fuller was a cold warrior type, honored by > then president Reagan with a Medal of Freedom but hated and feared by > just about everyone else (except artists, hippies, other "live in the > moment" types). ?To this day, if you talk about space-filling Mites in > a math teaching context, you're likely to get run out of town (unless > the town is Portland, in which case you're allowed to teach this > material through Saturday Academy, with the blessings of Silicon > Forest -- but this town is unusual in that respect, a FOSS > capital).[6] When I say "cold warrior" I don't mean he hated Russians or anything (he actually worked closely with Russian planners, lots at Synchronofile.com on that, maybe at the web site, also at SU). >From an Annapolis standpoint (looking at naval power etc. -- he went there for officer training) he actually thought the Russians were winning (per Critical Path). He did focus on "great game" type literature, focusing on Afghanistan a lot, like the rest of 'em plus he actually had that dome in Kabul in 1959, which the USSR's Khrushchev really admired, smart cookie that he was, more on that here: http://mybizmo.blogspot.com/2009/02/news-and-views.html "Sonny" was of course E.J. Applewhite. The early problem with H.S.M. Coxeter was over patents for the radomes in Canada. Dr. Loeb was also suspicious but later defected to the Bucky camp by contributing to said magnum opus and, more important, by coaching Amy Edmundson through the process of writing a more Springer-Verlag type treatment, which was not well received given Fuller's pariah status in academia (never mind the 11 doctorates etc.). Marshall McLuhan, a big Bucky fan per Synergetics Dictionary (compiled by Applewhite), was likewise razzed by the gulag professoriate. """ Marshall McLuhan told me the first day he met me -- on one of the early Doxiadis cruises -- 'I am your disciple.' He held up copies of No More Secondhand God and Nine Chains to the Moon and said 'I've joined your conspiracy!' McLuhan has never made any bones about his indebtedness to me as the original source of most of his ideas. """ E.J. Applewhite, Synergetics Dictionary, Vol 2, pg. 592, card 4. ISBN 0-8240-8729-1 (one typo fixed) -- my copy a gift from the author. Lots of interesting history, if we ever get time for it. > So for now I'm mostly sticking to algebra and the transferable "rib > cage" concept, thinking to walk teachers through these "math objects" > with interactive capabilities. ?Having this new discrete math title > (brought to my attention by Software Association of Oregon, which has > designs similar to mine, in terms of FOSS in the schools) is a boost, > especially the section on polynomials and their treatment as algebraic > objects (i.e. you can add and multiply two polynomials no problem, > with closure in both cases). > Polynomials don't necessarily have inverses though, form a ring, not a field: http://www.mathresources.com/products/mathresource/maa/polynomial_ring.html > I'm pretty sure NiceTime is on board with the cryptography stuff at > least in storyboard. ?Dr. Ian supplied a short video clip to my 3 hour > workshop (first 57 minutes syndicated through Blip TV) authorized for > that one viewing only, regarding DHM use at Amazon. ?It was a > kid-friendly Discovery channel segment, about public key cryptography > more generally, so also suitable for RSA, which is what I've been > going over (Andy Harrington supplied some improvements as well).[7] > I use an already cracked RSA number (Germans cracked it), enjoying the realism Python provides. The Javascript based demos of RSA I've seen on the web tend to use small integers, which I think loses the flavor. > One example of a high school project that might merit a poster at > Pycon someday would be to dig through the Mozilla code base and find > the https bits, maybe convert those to running Python. ?It's possible > to take lower level C code and recast it as inanely verbose and > unpythonic Python that nevertheless runs and, by imitating the C, > gives Python readers a first inkling of what a lower level language is > like (many won't know). ?Anyway, that's one idea. > I'm not sure the "inane Python" part is a good idea, but I do like encouraging students to dig into code piles actually looking for implementations. The danger with FOSS is we won't encourage students to study their heritage. They'll just take it for granted. And I'm not saying you need to be a CS major to take a healthy interest in such things (on the contrary). > I've been very up front with both Steve (holdenweb.com) and Dr. Ian > though: ?I'm still pretty focused on South Africa and Lesotho (my > family HQS was the latter mountain kingdom for like 7 years, > transferring from another mountain kingdom in the Himalayas). > Archbishop Tutu (like Dr. Ian, a King's College grad) was in town last > night, yakking about ubuntu and all that good stuff, inspiring my home > sickness for Cape Town. ?Jackalope is looking good by the way. ?But > it's not either/or is it? > Tutu's visit (he was awarded a doctorate by University of Portland): http://worldgame.blogspot.com/2009/05/time-for-reconciliation.html > My role in all this, as a noob with PSF (incoming Class of '09), is > simply to look over Steve's shoulder and watch the process. ?I'm not > being asked to vote and there's nothing in the proposed budget to buy > any of my services. ?I've got other irons in the fire when it comes to > teacher trainings, but really like this idea that the UK is looking at > FOSS outside any strictly CS teaching context (which I think way too > narrow, unlike CP4E's). > > Kirby > 4D << FOOTNOTES SNIPPED >> From droujkova at gmail.com Tue May 5 19:40:57 2009 From: droujkova at gmail.com (Maria Droujkova) Date: Tue, 5 May 2009 13:40:57 -0400 Subject: [Edu-sig] Update on my PSF doings In-Reply-To: References: Message-ID: On Tue, May 5, 2009 at 12:55 PM, kirby urner wrote: > > The "group theory for children" idea is in retreat, with everyone > focused on remediating a borked precalculus track which almost > everyone hates, but ETS keeps nailed, turning NCTM schools into slave > ships. > > How sad for them. This relates to two conversations, going on at other lists at the moment. One is a talk among several parents working on group theory with little kids, on the Living Math list (http://groups.yahoo.com/group/LivingMathForum/). I translated a sixties Russian book episode about an "imaginary number carousel" (powers of i, as a rotation group), and a mother shared her experiences with her 7yo son, for example: "We started by making out own rotating around a point triangle (a triangle of one color attached with a tack and secured with a piece of eraser to sheet of paper of contrasting color) marking its original position and naming all 3 rotations. Then, after a couple of initial questions (about the angles of rotation which M. happily computed; commutation, inverse) we filled out the first part of the multiplication table." We also looked at an online toy about rotation groups a father made for his young kids, called "The flippy triangle thing": http://www.leftoverpi.com/play/flippy/ The second conversation is at IAEP (http://lists.sugarlabs.org/archive/iaep/2009-May/005466.html and http://lists.sugarlabs.org/archive/iaep/2009-May/005484.html), about the value of "similarities over differences" as a rare, remarkable cultural accompishment: http://learningevolves.wikispaces.com/nonUniversals I think "group theory for kids" is an excellent example of a higher-order similarity among many different ideas and objects (numbers, rotations, etc). Refusing to work with high-order similarities is a huge step backwards, culturally. -- Cheers, MariaD Make math your own, to make your own math. http://www.naturalmath.com social math site http://groups.google.com/group/naturalmath our email group http://www.phenixsolutions.com empowering our innovations From kirby.urner at gmail.com Mon May 11 05:34:16 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sun, 10 May 2009 20:34:16 -0700 Subject: [Edu-sig] Update on my PSF doings In-Reply-To: References: Message-ID: > > The second conversation is at IAEP > (http://lists.sugarlabs.org/archive/iaep/2009-May/005466.html and > http://lists.sugarlabs.org/archive/iaep/2009-May/005484.html), about > the value of "similarities over differences" as a rare, remarkable > cultural accompishment: > http://learningevolves.wikispaces.com/nonUniversals I think "group > theory for kids" is an excellent example of a higher-order similarity > among many different ideas and objects (numbers, rotations, etc). > Refusing to work with high-order similarities is a huge step > backwards, culturally. > Coming up for air. Good threads. Thanks for the links. I signed into the Coworking group with Google, seeing the Cubespace connection, also ActiveSpace. Both experiments are working well in Portland, but what might be a more rural analog -- if we like the word "rural" for Oregon's high desert. The "group theory for kids" meme is an old one with me (also "clifford algebra for kids" though I've done less with that one). A key connection is polyhedra i.e. most introductions dwell on symmetry groups and we've already got lots going with those. ** In transitioning from tiny postage stamp screens (calculators) to full sized LCDs (or XO sized notebook screen) there's a natural appetite for more colorful polyhedra (using the term loosely, to mean "worlds" of all kinds -- Second Life, Sims... Uru). So we need a curriculum willing and able to map in that space ("beyond flatland" I used to call it, e.g. 1997 ISEPP Math Summit, Corvallis, Oregon 1997, Sir Roger Penrose and Dr. Ralph Abraham among the luminaries). Telling it autobiographically helps personalize the story, but we're talking megatrends, lots of stories, all inter-weaving. Not saying my details are that important, just wondering if my predications are on target: bigger screens, more programming, more group theory, more polyhedra (which ones?). Given I'm from the international school circuit, I have an easy time imagining bringing in some of these reforms through such venues. I used to chat with some guy in France on that topic, but we couldn't find a shared wavelength. Some of these other connections have worked better over the long term. Lately, I've been looking at the Philippines, joined the user group (just for lurking). They're into Django just like everyone else over there. But as Kaplan-Moss is very clear: there's no point being into Django if you're not also into Python more generally. The Philippines is doing a strong business exporting math teachers wanting to see more of the world, given the demand for Anglophone speakers who know math teaching. Lots in the news about this. So... step one is giving permission to teachers to explain how the Web works, as basic infrastructure (e.g. tcp/ip), not wait until college, as a part of math class if not (also?) geography class. Step two is making it all more concrete via a school intranet (a place for yearbooks, school plays, science fair posters). If you're lucky, your school will have one. That's a "foot in the door" approach, after which we unfold the more full-blown digital mathematics sequence(s). Note that "digital mathematics" means much the same thing as "discrete mathematics" but may have better hooks in some zip codes (it's DM either way, conveniently). The preface to Litvins is good in this regard: """ If we could build a time machine and bring Euclid over for a visit, he would find it comforting amid the chaos of modern technologies that geometry familiar to him is still taught in schools. Old rivals Newton and Leibniz would both find great satisfaction in the fact that tens of thousands of 11th and 12th graders are learning how to take derivatives and use integrals. But George Boole, a visitor from the more recent past, would have to search through dozens of school textbooks before he could find his algebra of propositions mentioned even in passing, despite the fact that his name is immortalized in every modern computer programming language. As for John von Neumann, a brilliant mathematician and one of the fathers of computer technology... well, with his usual optimism he would predict that within 20 years or so, every elementary school student will learn about the AND, OR, and NOT gates. And why not? """ [ the entire preface is on-line here: http://www.skylit.com/mathandpython.html ] Too little too late perhaps, but that's another discussion. Anyone remember Rocky's Boots? Pretty fun: http://en.wikipedia.org/wiki/Rocky%27s_Boots (we've discussed it before I think...) http://www.warrenrobinett.com/rockysboots/ (something similar on XO these days?) There's no requirement to standardize on any one tool set, though FOSS in general will likely continue dominating, given we're also teaching community (aka ubuntu). Joining some "secret team" might come later, but in grade school you needed opportunities to develop those team player skills (cyberspace is another sports arena in that regard, and competitive even when open). The emphasis is on learning new tools (including for working with "math objects") and combining them, not getting too comfortable with any one tool set. Python is maybe stabilizing at its core, but the libraries (including 3rd party modules), APIs to remote devices, is just going to get more varied and capable, if history is any guide. Kirby > -- > Cheers, > MariaD > > Make math your own, to make your own math. > > http://www.naturalmath.com social math site > http://groups.google.com/group/naturalmath our email group > http://www.phenixsolutions.com empowering our innovations > ** per my class notes in Pycon Chicago, the approach to polyhedra I'm exporting from Portland via OCN, is a confluence of several schools of thought, more coming in from Gattegno's these days. Jay Kappraff's 'Connections: The Geometric Bridge Between Art and Science" was back in my writings today on another list. We're happy about some of the curriculum writing we're getting out of Minnesota these days. I tend to dis the Lower48 in my political rhetoric (yawn), but not in such a way as to preclude working with star teachers. http://www.4dsolutions.net/ocn/ does have an Alaska bias though, I admit it -- look closely at the logo. From da.ajoy at gmail.com Tue May 12 21:20:15 2009 From: da.ajoy at gmail.com (Daniel Ajoy) Date: Tue, 12 May 2009 14:20:15 -0500 Subject: [Edu-sig] Considering Python for an algebra course In-Reply-To: References: Message-ID: > From: Maria Droujkova > > Geogebra was created specifically for the type of projects I want to run. It > is easy enough to start, for kids. I find its specialization to be a > limiting factor, though - it would be nice if kids saw the environment's > potential beyond math. > > With Python, I have more questions than answers, because I am just starting > to learn it. Do you think it will work for my purpose? Do I need to get a > real programmer involved, or can I learn enough Python in a few months to > help kids well enough, without being a specialist? What questions do I not > know to ask? > > I would appreciate any pointers. You speak about the "the type of projects you want to run". What are those? Maybe with that information the pointers could be more specific. Do you want to publish your projects online? I think a good question is: how to do that with python. Daniel From echerlin at gmail.com Tue May 12 22:47:00 2009 From: echerlin at gmail.com (Edward Cherlin) Date: Tue, 12 May 2009 13:47:00 -0700 Subject: [Edu-sig] Considering Python for an algebra course In-Reply-To: References: Message-ID: On Tue, May 12, 2009 at 12:20 PM, Daniel Ajoy wrote: >> From: Maria Droujkova >> >> Geogebra was created specifically for the type of projects I want to run. It >> is easy enough to start, for kids. I find its specialization to be a >> limiting factor, though - it would be nice if kids saw the environment's >> potential beyond math. >> >> With Python, I have more questions than answers, because I am just starting >> to learn it. Do you think it will work for my purpose? NumPy and SciPy can do any math you will need. I am working on a project to teach algebra with analytic geometry in Turtle Art, which is written in Python. I can graph anything I can construct in TA now, and I intend to use the programmable block in TA to add more Python code. >> Do I need to get a >> real programmer involved, or can I learn enough Python in a few months to >> help kids well enough, without being a specialist? Wrong question, actually. The community will pitch in. You can learn enough Python to handle the math, no question. You may need other programming help if you want to create an application that you can distribute. Talk to us when any such issues arise. You can also talk to the Sugar Labs development people about anything that you might want to offer for the OLPC XO, and get Python help there. lists.sugarlabs.org/ or /join #sugar on irc. >> What questions do I not >> know to ask? Best question I know of, but hard to answer at the beginning. Tell us what you want to accomplish, and we can tell you the relevant questions and some of the answers. >> I would appreciate any pointers. > > > You speak about the "the type of projects you want to run". What are those? Maybe with that information the pointers could be more specific. > > Do you want to publish your projects online? I think a good question is: how to do that with python. > > Daniel > > > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > -- Silent Thunder (??/???????????????/????????????? ?) is my name And Children are my nation. The Cosmos is my dwelling place, The Truth my destination. http://earthtreasury.org/worknet (Edward Mokurai Cherlin) From kirby.urner at gmail.com Wed May 13 03:16:29 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 12 May 2009 18:16:29 -0700 Subject: [Edu-sig] random fragments (pre May PPUG meeting) Message-ID: So does the new turtle canvas save to a PNG, using PIL maybe, or do we still need to hack that? I think wxPython's canvas has PIL output, but it's been awhile. Robin Dunn's work was a topic with Synovate for a thread, me bungling the answer about EMF files, Patrick getting it right (he's the master, I'm the stoopid noob in a qyoob). The reason I ask is we're wanting 7-circuit labyrinth drawings for Junior Friends (youngish Quakers), meaning we can't get federal funding exactly, but FOSS to the rescue maybe. I could see turtles for drawing and turtles for walking. A labyrinth isn't a maze by the way, has only the one path. What's important is to get the classic curves, although you'll find many variations and I'm not thinking to squelch ethnic diversity (on the contrary). http://www.hypnosis.org/catalog/images/ClassicLeftHanded.gif http://www.labyrinthcompany.com/view_series.php?category_id=1&series_id=5 Anyway, if anyone runs across the right Logo (I could translate to .py)... or I might get to it. My wife led workshops on this topic, at Annual Session in South Africa for example, using chalk and/or lime on the grass -- the stuff used for soccer fields and like that. Did I mention how excited Archbishop Tutu is about the World Cup coming there? He was in Portland the other night, blogged about it. http://worldgame.blogspot.com/2009/05/time-for-reconciliation.html Putting on PSF cap: I got to watch the process wherein NiceTime came through for a second look, this being a UK based initiative to use Python directly in maths teaching, but with a lower age range in focus. It didn't go through, could post mortem ad nauseum but from my angle had to do with low name recognition on Gattegno, especially on this side of Atlantic, as confirmed by this card catalog lookup: http://www.flickr.com/photos/17157315 at N00/3522646219/ Sea turtles in VPython, other OpenGL, remain of interest, i.e. we'd like to draw Icosahedra with turtle commands. I've done a lot of this work on my own, publishing through Oregon Curriculum Network, e.g. the L-system stuff. Although I've not had time to get back to it, I know we have another generation looking for ways to cut teach, and 4D Logo is one way to go (4D is a brand, though we could also talk dimensions sometime, on another list maybe). http://www.4dsolutions.net/ocn/numeracy3.html (scroll down for L-systems, turtle-based) I've had some followup threads with SAO (an Oregon industries lobby) plus all three invoices out the door today were Python related, so I feel good about our ethnicity today, like being a Pythoneer (yes, Pythonista is starting to default to female gendered, fight it if you like but Latin carries a lot of inertia -- discuss?). Does anyone else like "goose typing" for "even more loosey goosey than duck typing"? Meeting of Portland Pythonistas tonight (...fighting back). Our topic: distributing version control systems, woo hoo (love that hg). Is that Litvins' book cover too scary? I said I thought it might be in one email, as many people are already afraid of math, so adding a snake on the front maybe doesn't help matters? Looking at it again, I take it back. More like southwestern American bead work, showing of "geometry in nature" (a well-known meme in math circles, so students should embrace it, not run from it). http://www.skylit.com/mathandpython.html Snakes (including ours in particular) connote intelligence and wisdom. Athena has a Python familiar / friend per Nashville HQS -- one to remember I think, good for our brand: http://www.flickr.com/photos/17157315 at N00/3526413823/ (photo by Mary Welchance) Kirby 4D From kirby.urner at gmail.com Fri May 15 19:12:36 2009 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 15 May 2009 10:12:36 -0700 Subject: [Edu-sig] more pythonic algebra Message-ID: In a mathy approach to Python, it makes sense to go: a) welcome to the shell, (print("Hello World!") etc. b) this is a tool bench (for adults, cycle shop talk (more below)) c) import math The reasoning is this: we're in a POSIX or unixy context and want to get across the "many tools each doing one simple thing well". We're not afraid of bash at this level i.e. this is not an immersive environment where we seek to protect from the nasty evil bare OS API. On the contrary, we like futzing in C. So the "tool bench" metaphor (or "work bench") inherits from there, where "cycle shop talk" means like for bicycle repair. Unixy geeks have this no nonsense kind of retro workbench aesthetic that feels rather wood-worky, you probably know what I mean, and these overtones matter when we start making the cartoons, comix (e.g. xkcd). ** In notes for the teacher, lets make clear this isn't like PLT Scheme where the aim is to start with a "simplified" version of the language and gradually add features. The bootup space of __builtins__ is full of professional tools, but minimalist and not "just the easy to understand ones" or something like that. The idea that a fresh boot into the shell puts you in "beginner-ville" is somewhat antithetical to Python's design and story of origin, so lets not encourage that misconception among teachers. However, this is algebra, so right away it's on to (c) and import math, at which point other lesson plans kick in. The idea with 'import math' is we're doing a dir( ) both "before" and "after" in the shell. The concept of "namespace" is going to be integral within mathematics itself, moving forward. So-called "dot notation" is a core concept here (you'd be amazed how many algebra books avoid it, to their lasting detriment after a certain cut-off date, given their competition). The first day of math class probably involves lots of 'import x from y as z' versus just 'import x' versus 'import some.package.primegens' or whatever i.e. getting that syntax all clarified. Then we jump into functions right away, per Litvins, e.g. f(x) -- meaning another hour on args (that could be day 2 or 3 maybe -- or spread it out more, per Saxon). Next I'll archive a recent interaction with the J-software community, another math teaching language used for algebra in some schools, coffee shops or whatever. Kirby ** example cartoon: key concept: "to import a module is like typing everything in it at your shell, adding to your namespace" animation: normal kid suddenly superhumanly fast, rattling keys 300/minute, entering 'import this' or whatever, say something really long (lots of variations -- the point is to emphasize top-to-bottom execution of .py upon import with .pyc generation, presuming CPython, and adding to top-level namespace -- yes, this is more like 'import *'). From kirby.urner at gmail.com Fri May 15 19:19:38 2009 From: kirby.urner at gmail.com (kirby urner) Date: Fri, 15 May 2009 10:19:38 -0700 Subject: [Edu-sig] Jsoftware, PDF geometry animations (ReportLab?) Message-ID: Speaking of function args, this recent thread with another guy in Canada (you know him Andre?). :) You'll find me writing about J going way back in this very archive, more recently joined by Ed Cherlin in singing its praises. For those of you looking for a way cool use of Python's ReportLab, I so far have permission to release this one example "PDF flipbook" showing how geometry concepts might be communicated using this simple animation technique: http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf I've been sharing this as a teaser with Software Association of Oregon as well, knowing Ron has a lot more where that came from (I'm suppose to download a half-gig PDF next time in Pauling House for a bored er board meeting). Kirby ---------- Forwarded message ---------- From: kirby urner Date: Tue, May 12, 2009 at 1:52 PM Subject: Re: Arg names in J To: Gilles Kirouac Cc: kirby at 4dsolutions.net Thanks, I might keep the old notation, as that's what matches the historical date stamp on my writing, don't want to pretend to clairvoyance, however I do have more current writing suggesting we form closer ties with the J-software community, owing to our shared interest in having computer languages for math teaching. http://www.4dsolutions.net/presentations/p4t_notes.pdf is some of my most current thinking on this, note Iverson is front and center, with B. Fuller on the last page (rarely cited by 1900s authors but a contemporary favorite in some circles), emerging links to Wolfram (whom Kenneth didn't get along with especially -- never met the man personally). Kirby On Tue, May 12, 2009 at 1:34 PM, Gilles Kirouac wrote: > Kirby > > ?In a recent thread of the J forum, someone mentioned your work > ( http://www.jsoftware.com/pipermail/chat/2009-May/001811.html ). > > ?I recall very well your name in the forum a decade or so ago. > > ?I looked briefly at your pages and have a suggestion following > the evolution of J. Since version 6.01 of J, names x., y. (and > others) are replaced by x and y in user definitions > (http://www.jsoftware.com/help/user/previous601.htm). Thus where > you have explicit defs (v.g. Lecture Four on Bernouilli Numbers), > a note or adjustment would be welcome. There is a global option > to ease the transition, see 9!:48 and 9!:49 with V6.01 and V6.02. > > ?Regards, > > ?~ Gilles, Qu?bec, Canada > From gregor.lingl at aon.at Sun May 17 15:35:04 2009 From: gregor.lingl at aon.at (Gregor Lingl) Date: Sun, 17 May 2009 15:35:04 +0200 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: References: Message-ID: <4A101288.4000209@aon.at> kirby urner schrieb > For those of you looking for a way cool use of Python's ReportLab, I > so far have permission to release this one example "PDF flipbook" > showing how geometry concepts might be communicated using this simple > animation technique: > > http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf > Very impressive and instructive! Is there a description somewhere, how 'flipbooks' like these can be produced? With me this way of communicating geometry concepts worked rather well, as you can see in the attachment. Regards, Gregor > I've been sharing this as a teaser with Software Association of Oregon > as well, knowing Ron has a lot more where that came from (I'm suppose > to download a half-gig PDF next time in Pauling House for a bored er > board meeting). > > Kirby > > -------------- next part -------------- An embedded and charset-unspecified text was scrubbed... Name: trigeo.py URL: From echerlin at gmail.com Sun May 17 18:06:18 2009 From: echerlin at gmail.com (Edward Cherlin) Date: Sun, 17 May 2009 09:06:18 -0700 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: <4A101288.4000209@aon.at> References: <4A101288.4000209@aon.at> Message-ID: On Sun, May 17, 2009 at 6:35 AM, Gregor Lingl wrote: > kirby urner schrieb >> >> For those of you looking for a way cool use of Python's ReportLab, I >> so far have permission to release this one example "PDF flipbook" >> showing how geometry concepts might be communicated using this simple >> animation technique: >> >> http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf Yes, the Python version below works much better for me. I'm not up for clicking 1264 times to view the PDF. > Very impressive and instructive! Is there a description somewhere, how > 'flipbooks' like these > can be produced? > > With me this way of communicating geometry concepts worked rather well, as > you can see in the > attachment. > > Regards, > Gregor >> >> I've been sharing this as a teaser with Software Association of Oregon >> as well, knowing Ron has a lot more where that came from (I'm suppose >> to download a half-gig PDF next time in Pauling House for a bored er >> board meeting). >> >> Kirby > > # uses turtle module from Python 2.6 > # hint from Kirby, 15. 5. 09 > # http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf > > from turtle import Turtle, Screen, Vec2D, mainloop > import math > > A = 50. ?# adjust this to your needs > > SHS = A / 20 > SF = 1.0 > DSF = 1.0038582416 > e = Vec2D(3**.5/2, 0.5) > > def dsin(angle): > ? ?return math.sin(angle*math.pi/180) > > def lines(l): > ? ?for i in range(6): > ? ? ? ?d.fd(l) > ? ? ? ?d.bk(l) > ? ? ? ?d.left(60) > > class TriTurtle(Turtle): > ? ?def __init__(self, c, r, tritype): > ? ? ? ?Turtle.__init__(self, shape="triangle") > ? ? ? ?self.c = c > ? ? ? ?self.r = r > ? ? ? ?self.speed(0) > ? ? ? ?self.pencolor(0,0,0) > ? ? ? ?if tritype == 1: > ? ? ? ? ? ?self.basecolor = (1.0, 0.80392, 0.0) > ? ? ? ? ? ?self.f = -1 > ? ? ? ? ? ?self.left(30) > ? ? ? ?else: > ? ? ? ? ? ?self.basecolor = (0.43137, 0.43137, 1.0) > ? ? ? ? ? ?self.f = 1 > ? ? ? ? ? ?self.left(90) > ? ? ? ?self.fillcolor(self.basecolor) > ? ? ? ?self.pu() > ? ? ? ?self.goto(c*A, r*A*3**.5/3) > ? ? ? ?self.shapesize(SHS, SHS, 1) > ? ? ? ?self.D = self.distance(0,0) > ? ? ? ?self.e = (1/self.D)*self.pos() > ? ?def setturn(self, phi): > ? ? ? ?self.goto(SF*self.D*dsin(90-phi)*self.e) > ? ? ? ?self.settiltangle(phi*self.f) > ? ? ? ?self.shapesize(SHS*SF) > ? ? ? ?if abs(self.c) + abs(self.r) > 2: > ? ? ? ? ? ?self.fillcolor([x + (1-x)*phi/360 for x in self.basecolor]) > ? ? ? ? ? ?bc = phi/360. > ? ? ? ? ? ?self.pencolor(bc, bc, bc) > > > s = Screen() > s.reset() > s.tracer(0) > d = Turtle(visible=False) > lines(500) > > triangles = [] > for c in range(-5,6,2): > ? ?triangles.append(TriTurtle(c, 1, 1)) > ? ?triangles.append(TriTurtle(c, -1, 2)) > for c in range(-4,5,2): > ? ?triangles.append(TriTurtle(c, 2, 2)) > ? ?triangles.append(TriTurtle(c, -2, 1)) > ? ?triangles.append(TriTurtle(c, -4, 2)) > ? ?triangles.append(TriTurtle(c, 4, 1)) > for c in range(-3,4,2): > ? ?triangles.append(TriTurtle(c, 5, 2)) > ? ?triangles.append(TriTurtle(c, -5, 1)) > ? ?triangles.append(TriTurtle(c, -7, 2)) > ? ?triangles.append(TriTurtle(c, 7, 1)) > for c in range(-2,3,2): > ? ?triangles.append(TriTurtle(c, 8, 2)) > ? ?triangles.append(TriTurtle(c, -8, 1)) > s.tracer(1) > > for phi in range(1,361): > ? ?SF = SF*DSF > ? ?s.tracer(0) > ? ?for t in triangles: > ? ? ? ?t.setturn(phi) > ? ?s.tracer(1) > > mainloop() > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > > -- Silent Thunder (??/???????????????/????????????? ?) is my name And Children are my nation. The Cosmos is my dwelling place, The Truth my destination. http://earthtreasury.org/worknet (Edward Mokurai Cherlin) -------------- next part -------------- # uses turtle module from Python 2.6 # hint from Kirby, 15. 5. 09 # http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf from turtle import Turtle, Screen, Vec2D, mainloop import math A = 50. # adjust this to your needs SHS = A / 20 SF = 1.0 DSF = 1.0038582416 e = Vec2D(3**.5/2, 0.5) def dsin(angle): return math.sin(angle*math.pi/180) def lines(l): for i in range(6): d.fd(l) d.bk(l) d.left(60) class TriTurtle(Turtle): def __init__(self, c, r, tritype): Turtle.__init__(self, shape="triangle") self.c = c self.r = r self.speed(0) self.pencolor(0,0,0) if tritype == 1: self.basecolor = (1.0, 0.80392, 0.0) self.f = -1 self.left(30) else: self.basecolor = (0.43137, 0.43137, 1.0) self.f = 1 self.left(90) self.fillcolor(self.basecolor) self.pu() self.goto(c*A, r*A*3**.5/3) self.shapesize(SHS, SHS, 1) self.D = self.distance(0,0) self.e = (1/self.D)*self.pos() def setturn(self, phi): self.goto(SF*self.D*dsin(90-phi)*self.e) self.settiltangle(phi*self.f) self.shapesize(SHS*SF) if abs(self.c) + abs(self.r) > 2: self.fillcolor([x + (1-x)*phi/360 for x in self.basecolor]) bc = phi/360. self.pencolor(bc, bc, bc) s = Screen() s.reset() s.tracer(0) d = Turtle(visible=False) lines(500) triangles = [] for c in range(-5,6,2): triangles.append(TriTurtle(c, 1, 1)) triangles.append(TriTurtle(c, -1, 2)) for c in range(-4,5,2): triangles.append(TriTurtle(c, 2, 2)) triangles.append(TriTurtle(c, -2, 1)) triangles.append(TriTurtle(c, -4, 2)) triangles.append(TriTurtle(c, 4, 1)) for c in range(-3,4,2): triangles.append(TriTurtle(c, 5, 2)) triangles.append(TriTurtle(c, -5, 1)) triangles.append(TriTurtle(c, -7, 2)) triangles.append(TriTurtle(c, 7, 1)) for c in range(-2,3,2): triangles.append(TriTurtle(c, 8, 2)) triangles.append(TriTurtle(c, -8, 1)) s.tracer(1) for phi in range(1,361): SF = SF*DSF s.tracer(0) for t in triangles: t.setturn(phi) s.tracer(1) mainloop() From kirby.urner at gmail.com Sun May 17 20:53:02 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sun, 17 May 2009 11:53:02 -0700 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: References: <4A101288.4000209@aon.at> Message-ID: On Sun, May 17, 2009 at 9:06 AM, Edward Cherlin wrote: > On Sun, May 17, 2009 at 6:35 AM, Gregor Lingl wrote: >> kirby urner schrieb Brilliant work Gregor, ran yours just now (I have 2.5, 2.6 and 3.0 all installed on Ubuntu Dell Jackalope laptop, WinXP KTU3 lagging in its number of Pythons). Happy birthday to me! (literally -- turning 51 today) I think Ron will be quite pleased with such a quick turnaround, and such a faithful reproduction, right down to the colors. If we have a "sea turtles" model, then maybe they'll render his "rotating egg" flipbook as well, the topic of the half-gig one I downloaded @ Linus Pauling House yesterday, my CSO present in case anyone thought they could steal this IP (half joking, Glenn was there just to hang out and talk about stuff). Having this uber-teacher in Vienna managing Python's turtle assets is one of the best developments lately, liked your Blip .tv and sharing a BOF etc. Glad we could finally overlap in person a little (Pycons are great for that). Ron is fighting for his life BTW, in medical therapy, gives himself 50-50 odds of making it to a next chapter (he's based in Brooklyn, we've never met personally, but I have lots of street cred in the same Bucky circles he travels, we're getting along well). This will be better than a "get well soon" card I'm thinking. His website is here: ronresch.com (lots of great ideas, he says only 20% of his geometry research has been unveiled to date). >>> >>> For those of you looking for a way cool use of Python's ReportLab, I >>> so far have permission to release this one example "PDF flipbook" >>> showing how geometry concepts might be communicated using this simple >>> animation technique: >>> >>> http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf > > Yes, the Python version below works much better for me. I'm not up for > clicking 1264 times to view the PDF. > Yes Ed, same problem over here, especially with this half gig PDF focusing on Ron's trademark "egg" (an ellipsoidal tiling, highly mathematically defined -- he outputs these frame directly from hand-written PostScript that takes forever to debug, given this language's rather primitive IDE). I was thinking ReportLab (Python's most developed direct-to-PDF FOSS package) but Gregor has opened my eyes (as Daniel Ajoy did, in terms of appreciating Logo's nuances -- not that this is your grandmother's Logo anymore, now that we're in Vienna's circle). Ron's workshop features these big honkin' video cards where you just hold down the down arrow key (page down), and watch the action unfold. But not everyone has a video card that capable, including me since my nVidia for KTU3 suffered a meltdown. I was too disappointed to bother finding the receipt -- having this crap break all the time is a real pain, partly why I'm on my Dell so much, as it suffers less problems, plus of course Linux is more secure). >> Very impressive and instructive! Is there a description somewhere, how >> 'flipbooks' like these >> can be produced? >> I'm hoping Ron divulges more of his IP. He knows hand-writing PostScript won't be everyone's chosen method, reminds people he was inspired to these levels long before we had today's tools. He taught himself to work with what he had. When Bucky Fuller came to town (traveling roadshow circus), he was still computing domes the old fashioned way, with lots of spherical trig. Ron checked out huge piles of books on the subject and basically self-invented a vector-based way of doing it much more easily, which he shared with Fuller's whistle-stop train crew. Fuller tending to accept any contribution (he'd circulate a box after some lectures, take home a pile of student papers) and then toss the results to the world as leaflets out the back of his choo choo, while running for president of Design Science Incorporated. He was open sourcing and patenting at the same time, playing FOSS boss and IP king. Quite the Dymaxion Clown act. He alienated some people with this style of showmanship, but Fuller himself thought only an express train could work at this time, people could go back later and put the pieces together, so he made a lot of detailed notes (now warehoused in Stanford University) and we have puzzle assemblers crawling through it, putting together (computing) all kinds of new stories. Kirby >> With me this way of communicating geometry concepts worked rather well, as >> you can see in the attachment. >> >> Regards, >> Gregor >>> >>> I've been sharing this as a teaser with Software Association of Oregon >>> as well, knowing Ron has a lot more where that came from (I'm suppose >>> to download a half-gig PDF next time in Pauling House for a bored er >>> board meeting). >>> >>> Kirby >> >> # uses turtle module from Python 2.6 >> # hint from Kirby, 15. 5. 09 >> # http://www.4dsolutions.net/presentations/pdf_animation_by_ron_resch.pdf >> >> from turtle import Turtle, Screen, Vec2D, mainloop >> import math >> >> A = 50. ?# adjust this to your needs >> >> SHS = A / 20 >> SF = 1.0 >> DSF = 1.0038582416 >> e = Vec2D(3**.5/2, 0.5) >> >> def dsin(angle): >> ? ?return math.sin(angle*math.pi/180) >> >> def lines(l): >> ? ?for i in range(6): >> ? ? ? ?d.fd(l) >> ? ? ? ?d.bk(l) >> ? ? ? ?d.left(60) >> >> class TriTurtle(Turtle): >> ? ?def __init__(self, c, r, tritype): >> ? ? ? ?Turtle.__init__(self, shape="triangle") >> ? ? ? ?self.c = c >> ? ? ? ?self.r = r >> ? ? ? ?self.speed(0) >> ? ? ? ?self.pencolor(0,0,0) >> ? ? ? ?if tritype == 1: >> ? ? ? ? ? ?self.basecolor = (1.0, 0.80392, 0.0) >> ? ? ? ? ? ?self.f = -1 >> ? ? ? ? ? ?self.left(30) >> ? ? ? ?else: >> ? ? ? ? ? ?self.basecolor = (0.43137, 0.43137, 1.0) >> ? ? ? ? ? ?self.f = 1 >> ? ? ? ? ? ?self.left(90) >> ? ? ? ?self.fillcolor(self.basecolor) >> ? ? ? ?self.pu() >> ? ? ? ?self.goto(c*A, r*A*3**.5/3) >> ? ? ? ?self.shapesize(SHS, SHS, 1) >> ? ? ? ?self.D = self.distance(0,0) >> ? ? ? ?self.e = (1/self.D)*self.pos() >> ? ?def setturn(self, phi): >> ? ? ? ?self.goto(SF*self.D*dsin(90-phi)*self.e) >> ? ? ? ?self.settiltangle(phi*self.f) >> ? ? ? ?self.shapesize(SHS*SF) >> ? ? ? ?if abs(self.c) + abs(self.r) > 2: >> ? ? ? ? ? ?self.fillcolor([x + (1-x)*phi/360 for x in self.basecolor]) >> ? ? ? ? ? ?bc = phi/360. >> ? ? ? ? ? ?self.pencolor(bc, bc, bc) >> >> >> s = Screen() >> s.reset() >> s.tracer(0) >> d = Turtle(visible=False) >> lines(500) >> >> triangles = [] >> for c in range(-5,6,2): >> ? ?triangles.append(TriTurtle(c, 1, 1)) >> ? ?triangles.append(TriTurtle(c, -1, 2)) >> for c in range(-4,5,2): >> ? ?triangles.append(TriTurtle(c, 2, 2)) >> ? ?triangles.append(TriTurtle(c, -2, 1)) >> ? ?triangles.append(TriTurtle(c, -4, 2)) >> ? ?triangles.append(TriTurtle(c, 4, 1)) >> for c in range(-3,4,2): >> ? ?triangles.append(TriTurtle(c, 5, 2)) >> ? ?triangles.append(TriTurtle(c, -5, 1)) >> ? ?triangles.append(TriTurtle(c, -7, 2)) >> ? ?triangles.append(TriTurtle(c, 7, 1)) >> for c in range(-2,3,2): >> ? ?triangles.append(TriTurtle(c, 8, 2)) >> ? ?triangles.append(TriTurtle(c, -8, 1)) >> s.tracer(1) >> >> for phi in range(1,361): >> ? ?SF = SF*DSF >> ? ?s.tracer(0) >> ? ?for t in triangles: >> ? ? ? ?t.setturn(phi) >> ? ?s.tracer(1) >> >> mainloop() >> >> _______________________________________________ >> Edu-sig mailing list >> Edu-sig at python.org >> http://mail.python.org/mailman/listinfo/edu-sig >> >> > > > > -- > Silent Thunder (??/???????????????/????????????? ?) is my name > And Children are my nation. > The Cosmos is my dwelling place, The Truth my destination. > http://earthtreasury.org/worknet (Edward Mokurai Cherlin) > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > > From gregor.lingl at aon.at Sun May 17 22:58:32 2009 From: gregor.lingl at aon.at (Gregor Lingl) Date: Sun, 17 May 2009 22:58:32 +0200 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: References: <4A101288.4000209@aon.at> Message-ID: <4A107A78.1040304@aon.at> kirby urner schrieb: > On Sun, May 17, 2009 at 9:06 AM, Edward Cherlin wrote: > >> On Sun, May 17, 2009 at 6:35 AM, Gregor Lingl wrote: >> >>> kirby urner schrieb >>> > > > Brilliant work Gregor, ran yours just now (I have 2.5, 2.6 and 3.0 all > installed on Ubuntu Dell Jackalope laptop, WinXP KTU3 lagging in its > number of Pythons). > > Happy birthday to me! (literally -- turning 51 today) > Yeah, happy birthday to you. Hope you are celabrating it instead of reading this mail just now. > I think Ron will be quite pleased with such a quick turnaround, and > such a faithful reproduction, right down to the colors. > Danke f?r die Blumen, as we say in German. > If we have a "sea turtles" model, then maybe they'll render his > "rotating egg" flipbook as well, the topic of the half-gig one I > downloaded @ Linus Pauling House yesterday, my CSO present in case > anyone thought they could steal this IP (half joking, Glenn was there > just to hang out and talk about stuff). > > Having this uber-teacher in Vienna managing Python's turtle assets is > one of the best developments lately, liked your Blip .tv and sharing a > BOF etc. Glad we could finally overlap in person a little (Pycons are > great for that). > > Maybe there will be another opportunity. I'm going to give another talk on the turtle module at Europython in Birmingham and also a tutorial if there will be at least seven (or so) attendees. Laura was (and I hope will be) supporting me very strongly. My ambition is to make the turtle module more popular, as I'm convinced that is easy to use and very versatile as well as powerful. I've done a few bug-fixes and a few new features for Python 3.1 an it is gone into the (one and only) beta already. You can read about them at the end of the docs http://docs.python.org/dev/py3k/library/turtle.html#changes-since-python-3-0 You can download the new version separately here: http://svn.python.org/view/python/branches/py3k/Lib/turtle.py?view=log And there are two new examples in the demo directory. One of them is the nim game (I showed it at pycon during the open space). The other one -- tdemo_round_dance.py -- is new, needs the new version and is really nice to view. You'll find them here: http://svn.python.org/view/python/branches/py3k/Demo/turtle/ Have a nice party!! Gregor From echerlin at gmail.com Tue May 19 00:15:57 2009 From: echerlin at gmail.com (Edward Cherlin) Date: Mon, 18 May 2009 15:15:57 -0700 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: References: <4A101288.4000209@aon.at> Message-ID: On Sun, May 17, 2009 at 11:53 AM, kirby urner wrote: > Fuller tending to accept any contribution (he'd circulate a box after > some lectures, take home a pile of student papers) and then toss the > results to the world as leaflets out the back of his choo choo, while > running for president of Design Science Incorporated. ?He was open > sourcing and patenting at the same time, playing FOSS boss and IP > king. ?Quite the Dymaxion Clown act. We need more of him. > He alienated some people with this style of showmanship, but Fuller > himself thought only an express train could work at this time, people > could go back later and put the pieces together, so he made a lot of > detailed notes (now warehoused in Stanford University) and we have > puzzle assemblers crawling through it, putting together (computing) > all kinds of new stories. Is anybody working on getting this material online and inviting the world to crawl it and create new stories? I know some people in Science Commons who would like to talk to you about such a thing. I suspect that there are people and organizations about who would like to fund such a project. > Kirby -- Silent Thunder (??/???????????????/????????????? ?) is my name And Children are my nation. The Cosmos is my dwelling place, The Truth my destination. http://earthtreasury.org/worknet (Edward Mokurai Cherlin) From kirby.urner at gmail.com Tue May 19 04:42:27 2009 From: kirby.urner at gmail.com (kirby urner) Date: Mon, 18 May 2009 19:42:27 -0700 Subject: [Edu-sig] PDF geometry animations (ReportLab?) - and turtle module In-Reply-To: References: <4A101288.4000209@aon.at> Message-ID: On Mon, May 18, 2009 at 3:15 PM, Edward Cherlin wrote: ... RE Bucky Fuller: > Is anybody working on getting this material online and inviting the > world to crawl it and create new stories? I know some people in > Science Commons who would like to talk to you about such a thing. I > suspect that there are people and organizations about who would like > to fund such a project. > Yes Ed, thank you for asking. SU has been pretty diligent in getting some of the materials on-line, including a few videos and photographs. I've not set foot in the place yet, but judging from my tour of the Linus and Ava Pauling special collection at OSU, it likely takes up lots of floorspace (do they have the sliding shelves?). Here's a screen shot of what the inner sanctum looks like, but you have to create a login for yourself to actually see the video (Alan Watts in this one): http://mybizmo.blogspot.com/2009/01/romp-in-archive.html (SU video link) http://controlroom.blogspot.com/2008/12/fuller-archive.html (another example) Fuller made self documentation a core aspect of his life's work, called it the "Guinea Pig B" experiment, B for Bucky of course. He kept lots of trivia, like speeding tickets, details of his relationships with his team, it goes on and on. People with axes to grind or looking for dirt are among the first in line, simply because they're motivated. The idle grad student just randomly thinking about topics is less likely to tackle such an intimidating mountain of stuff. However, it's important to not get sidetracked into thinking everything under-valued and under-appreciated is behind closed doors or awaiting a visit to the scanner. In addition to the collection at Stanford, there's the Buckminster Fuller Institute (BFI), for which I was first webmaster, colluding with Kiyoshi Kuromiya on getting bfi.org registered / claimed. For some of the state of the art PR put out by this Institute, check this embedded YouTube in my blog. http://mybizmo.blogspot.com/2009/05/new-bfi-pr.html Also, note the strong links from BFI back to Python (and PSF) given I'm in the intersection of both: http://bfi.org/bfi_community/pythonic_mathematics_talk_by_kirby_urner (my embedded mplayer isn't doing much interesting with that London Knowledge Lab video, me enroute to TSF meeting, then FWCC, YMMV). >> Kirby > > -- > Silent Thunder (??/???????????????/????????????? ?) is my name > And Children are my nation. > The Cosmos is my dwelling place, The Truth my destination. > http://earthtreasury.org/worknet (Edward Mokurai Cherlin) > From gerry.lowry at abilitybusinesscomputerservices.com Wed May 20 16:56:21 2009 From: gerry.lowry at abilitybusinesscomputerservices.com (gerry_lowry (alliston ontario canada)) Date: Wed, 20 May 2009 10:56:21 -0400 Subject: [Edu-sig] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) Message-ID: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> http://www.acm.org/ Regards, Gerry From kirby.urner at gmail.com Wed May 20 23:08:41 2009 From: kirby.urner at gmail.com (kirby urner) Date: Wed, 20 May 2009 14:08:41 -0700 Subject: [Edu-sig] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) In-Reply-To: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> References: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> Message-ID: Hey thanks for the pointer Gerry, I'll be interested in others' opinions of that analysis. Mine is somewhat different in that I think real tangible evidence of a positive future is a threat to moneyed interests pushing a different agenda, otherwise we'd have seen XOs on Tony the Tiger cereal boxes by now, whereas they're only just getting around to sharing free memory stix: http://www.flickr.com/photos/17157315 at N00/3535504824/ http://www.flickr.com/search/?w=17157315%40N00&q=grunch&m=text (more cereal box pix) Not that you'd get an actual XO in the box (too heavy), but it's a really fascinating story that could've been shared on a voluntary basis by companies interested in boosting the OLPC agenda e.g. Kellogg's and like that. Lots more in my blogs, where the XO is faithfully marketed (plus I have two, one for the roadshow, one on loan to a young child on a rotating basis -- like a library): http://www.flickr.com/search/?q=XO&w=17157315%40N00 Kirby On Wed, May 20, 2009 at 7:56 AM, gerry_lowry (alliston ontario canada) wrote: > http://www.acm.org/ > > > > Regards, > Gerry > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > From echerlin at gmail.com Thu May 21 01:10:54 2009 From: echerlin at gmail.com (Edward Cherlin) Date: Wed, 20 May 2009 16:10:54 -0700 Subject: [Edu-sig] [IAEP] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) In-Reply-To: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> References: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> Message-ID: I wrote a reply on the Web site. It is being reviewed by the editors before posting. http://cacm.acm.org/magazines/2009/6/28497-one-laptop-per-child-vision-vs-reality/comments On Wed, May 20, 2009 at 7:56 AM, gerry_lowry (alliston ontario canada) wrote: > http://www.acm.org/ > > > > Regards, > Gerry > _______________________________________________ > IAEP -- It's An Education Project (not a laptop project!) > IAEP at lists.sugarlabs.org > http://lists.sugarlabs.org/listinfo/iaep > -- Silent Thunder (??/???????????????/????????????? ?) is my name And Children are my nation. The Cosmos is my dwelling place, The Truth my destination. http://earthtreasury.org/worknet (Edward Mokurai Cherlin) From kirby.urner at gmail.com Fri May 22 00:41:57 2009 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 21 May 2009 15:41:57 -0700 Subject: [Edu-sig] [IAEP] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) In-Reply-To: References: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> Message-ID: Thanks Ed. I twittered scoping this ACM page in advance of your comment, which then appeared for analysis. Nice one. I think you're right on the "too early to tell" plus it's really interesting how, when I flash my XOs around town, you'll get these angry faces when I mentioned you can't just go to the neighborhood retail outlet and get one, at any price. It's that "any price" that sticks in the craw for some, as there's this sense of entitlement many have, especially if carrying Visa. The XO-2 may be even harder to get, maybe Taliban only, not sure yet. :) Kirby On Wed, May 20, 2009 at 4:10 PM, Edward Cherlin wrote: > I wrote a reply on the Web site. It is being reviewed by the editors > before posting. > > http://cacm.acm.org/magazines/2009/6/28497-one-laptop-per-child-vision-vs-reality/comments > > On Wed, May 20, 2009 at 7:56 AM, gerry_lowry (alliston ontario canada) > wrote: >> http://www.acm.org/ >> >> >> >> Regards, >> Gerry >> _______________________________________________ >> IAEP -- It's An Education Project (not a laptop project!) >> IAEP at lists.sugarlabs.org >> http://lists.sugarlabs.org/listinfo/iaep >> > > > > -- > Silent Thunder (??/???????????????/????????????? ?) is my name > And Children are my nation. > The Cosmos is my dwelling place, The Truth my destination. > http://earthtreasury.org/worknet (Edward Mokurai Cherlin) > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > From kirby.urner at gmail.com Sun May 24 03:49:27 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sat, 23 May 2009 18:49:27 -0700 Subject: [Edu-sig] eduPycon on conferences list (proposal) Message-ID: Some of you will maybe have seen David Goodger's announcement of a new Python community list focused on Python conferences: http://mail.python.org/mailman/listinfo/conferences I was hanging out at the virtual water cooler with PSF's Jeff Rush, mentioning his eduPycon idea, thinking we might have discussions on edu-sig, but maybe this new venue is more apropos? Here's our water cooler exchange in cyberspace FYI: http://mail.python.org/pipermail/portland/2009-May/date.html Kirby From kirby.urner at gmail.com Sun May 24 04:43:22 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sat, 23 May 2009 19:43:22 -0700 Subject: [Edu-sig] more on "variable names" Message-ID: I filed the following quick comment after viewing a six minute tutorial on variables and values at ShowMeDo. The video: http://showmedo.com/videotutorials/video?name=6950010&fromSeriesID=695 My comment: """ idea that values are "stored into" a variable is less the metaphor in Python, which is more about assigning or binding names to objects with the assignment operator (=). The problem with "store into" is then its hard to picture many names for the same object, yet that's easy when you think of a balloon with many strings. """ Yikes it posted three times dammit, makes me the foolish dweeb. Anyway, based on our longish threads here awhile back, I think "we who consider ourselves Python teachers" should actively check ourselves against using the verbs "to store in" or "store into" with respect to objects and their top-level names. The reason is, once you picture a dog in a doghouse, with the variable name as the doghouse, then it's hard to visualize how other doghouses could contain the same dog (the same value) without there being multiple copies of the same dog (clones?). A better image is balloons on strings. I realize it's not customary to have one helium balloon with two or more strings, different hands holding each string, sharing the same balloon, but there's nothing conceptually difficult about it (feels kind of ubuntu), whereas with that dog in the doghouse... that way madness lies. As several teaching professionals were noting on this list, a Python name is a lot more like a C pointer in the sense that it neither grows nor shrinks with respect to that which it names, i.e. the "size of object" is not a name's concern (another way to break the hold of the container-contained imagery). I think when we teach low level (including but not limited to children), we actually mess with (rewire) basic associations, a common technique in pedagogy (called "mnemonics"). For example, the so-called "equal sign" (=) would be better called an "assignment operator" as most of us here do. To make this link stick we could explain how the two parallel lines represent "opening a channel to" i.e. now this name (on the left) will be able to communicate with the object on the right (some result of evaluation). Why "open a channel to"? Because now we have "dot notation" i.e. our little API "control panel" at the near end of the string, our little "interface words" (triggers, attributes, methods with args)... our "messages" (to use Smalltalky talk). We don't really want s = 3 to be read "s equals 3" in Python. It's closer to "s names 3" or "s represents 3" or even "s speaks for 3". Not "s stores 3", nor "s contains 3". Probably the idea of "garbage collection" should be introduced right at this juncture, with arched eyebrows ala Spock if we forget to mention it. That's a really good way to anchor the many-to-one strings-to-balloon metaphor, with the idea of a reference counter on the object. Dogs in doghouses don't have reference counters, plus we wouldn't want them garbage collected. Balloons, on the other hand, go pop, which'd be a convenient way to represent "freeing up memory". Kirby PS: do Python's where Prada? http://fashionshops.wordpress.com/2009/05/18/prada-ad-campaign-ss-2009/ From kirby.urner at gmail.com Sun May 24 18:16:43 2009 From: kirby.urner at gmail.com (kirby urner) Date: Sun, 24 May 2009 09:16:43 -0700 Subject: [Edu-sig] more on "variable names" In-Reply-To: References: Message-ID: On Sat, May 23, 2009 at 7:43 PM, kirby urner wrote: > I filed the following quick comment after viewing a six minute > tutorial on variables and values at ShowMeDo. > > The video: > > http://showmedo.com/videotutorials/video?name=6950010&fromSeriesID=695 > > My comment: > """ > idea that values are "stored into" a variable is less the metaphor in > Python, which is more about assigning or binding names to objects with > the assignment operator (=). ?The problem with "store into" is then > its hard to picture many names for the same object, yet that's easy > when you think of a balloon with many strings. > """ > > Yikes it posted three times dammit, makes me the foolish dweeb. > Someone took care of this, not sure why I'm anonymous as I used my name -- probably because not logged in? I added another comment supportive of his idea to make the model clear using garbage collection: http://showmedo.com/videotutorials/video?name=6950010&fromSeriesID=695 > A better image is balloons on strings. ?I realize it's not customary > to have one helium balloon with two or more strings, different hands > holding each string, sharing the same balloon, but there's nothing > conceptually difficult about it (feels kind of ubuntu), whereas with > that dog in the doghouse... that way madness lies. > Someone pointed out off list that it *is* customary to have one helium balloon with two or more strings. In parades! http://images.google.com/images?hl=en&q=parade+balloons You might use these in the classroom, in slides, in tutorials. Each string-holder is a different variable name whereas the balloon itself is the object. So when do we get a Python balloon? Could be virtual I suppose. I think it's fine to talk about "Python's economy" i.e. there's an economy that is Python's, and includes memory management, the search path, other environment variables (if you've set them). Python then "paves the way" for these office buildings (many of them free) such as Zope and Twisted -- just download and go to town, plant them in your CBD (central business district) and put 'em to work (do some reading first -- takes time to become a FOSS boss (like the mayor of a virtual city, an economy)). Python is economical in not adding to the number of memory-hog objects gratuitously, simply as a result of assignment operations. For this reason, we avoid "dog in a doghouse" or "thing in a box" type metaphors when describing top-level naming. Even data structures such as lists are best approached with string (versus containment) metaphors. Given a primary notion of "string" already in popular consciousness is the URL (a handle), we can start thinking of objects as "servers" in the background, with variable names more like "clients" (with a channel open: client = server). Or instead of a web service, there's maybe a remote control engine on a track someplace, weighs a ton (literally) and several people have monitors with APIs for controlling it or at least displaying its location and status (moving?). When you go mystring = yourstring, you don't want the suggestion of cloning or copying something gigantic in memory -- you'd need to import from a different module for that, maybe do a deepcopy (more like a DVCS based approach). I use 'Code Guardian' (a short downloadable movie -- also on Youtube) to talk about controllable objects sometimes (these are big ones, giant robots by someone who knows movies really well) -- but mostly to talk about render time versus real time animation (this is render time). I run a course for Saturday Academy focused on animation concepts as this is ToonTown after all (we make lots of animations in Portland, especially when you count in the commercials e.g. Nike, Weiden+Kenney (http://www.wk.com/) http://www.cee-gee.net/Movies/Movies.htm (the source for the movie, others too) http://mybizmo.blogspot.com/2007/05/class-notes-session-three.html (suppose the robots aren't AI, but Python puppets)... Hey, big food fight on math-teach over whether to teach more SQL on a digital math track alternative to the continuous math track (analog) used by the calculus mountain people. I think I scored some points for DM. Litvins is helping by the way (its mere existence, snake cover not "too scary" -- reminds me of Prada). DM vs CM (DM winning): http://mathforum.org/kb/thread.jspa?threadID=1933378&tstart=0 Kirby 4D From da.ajoy at gmail.com Mon May 25 05:01:35 2009 From: da.ajoy at gmail.com (Daniel Ajoy) Date: Sun, 24 May 2009 22:01:35 -0500 Subject: [Edu-sig] Pythonic Math must include... Message-ID: I've some other candidates that I have included in my Logo Functional Extensions (LogoFE). * A function that receives a math function and plots it. * A function that receives a math equation and an interval and finds a root in that interval * A function that receives a math function and an interval and calculates the area under that curve * The Ruffini algorithm * A function that receives a math function and a X coordinate and finds the derivative at that point. Or returns the derivative function if you like. * Set arithmetic. Including set product. This, together with "join" and list comprehensions is all you need instead of SQL * Functions that produce permutations and combinations of a tuple. Daniel From kirby.urner at gmail.com Tue May 26 02:41:02 2009 From: kirby.urner at gmail.com (kirby urner) Date: Mon, 25 May 2009 17:41:02 -0700 Subject: [Edu-sig] Pythonic Math must include... In-Reply-To: References: Message-ID: On Sun, May 24, 2009 at 8:01 PM, Daniel Ajoy wrote: > I've some other candidates that I have included in my Logo Functional > Extensions (LogoFE). > > * A function that receives a math function and plots it. > * A function that receives a math equation and an interval and finds a root > in that interval > * A function that receives a math function and an interval and calculates > the area under that curve > * The Ruffini algorithm > * A function that receives a math function and a X coordinate and finds the > derivative at that point. Or returns the derivative function if you like. > > * Set arithmetic. Including set product. This, together with "join" and > list comprehensions is all you need instead of SQL > > * Functions that produce permutations and combinations of a tuple. > > > Daniel > > All excellent. One reflex is to "jump to" and start contributing examples, ala PyWhip. Another reflex is just to agree with the other pros on this list, that we've got a great list, and then suggest anyone working to cut teeth, in mathematics not just computer languages, try their hand at at least a few of these, if not all of them. On the subject of permutations, I was just happening to share Python with a noob recently, not that unusual, and wrote the following, which we all know is "not efficient" and yet conceptually fun, and we cut ourselves slack here, like what's a few microseconds or even seconds. If the thing blows up, we know how to kill it. So what I'm doing in the snippet below is "stuffing a stocking" with all permutations of 'A', 'B', 'C', 'D' or "four pool balls" (imagine using all 15: 1 + 2 + 3 + 4 + 5: http://images.google.com/images?hl=en&q=pool+balls+triangle using the technique of repeated shuffling and using the "set" data structure (one among many in this philosophy) to screen out the dupes. We already know the expected number (not cheating, no), so use this code merely to get the list, which I should bother to sort in the end... is this the "best way to do it"? Might be, if you're wanting to work with the random module for awhile, do some of those Pascal's Triangle things with the bell curve and so on. I left in the error about "hashable" as we're definitely in MD5 territory etc. i.e. unique mapping indexes, auto-generated from the content, small chance of collision). No need to turn up one's nose at "brute force" at every turn, as this new meaning, involving delicate silicon, is hardly that brutish (IMO). """ IDLE 1.2.1 >>> from random import shuffle >>> emptyset = set() >>> thecombo = ['A','B','C','D'] >>> # number of sorts: 4*3*2*1 == 24 >>> bagosorts = set() >>> shuffle(thecombo) >>> thecombo ['B', 'C', 'D', 'A'] >>> len(bagosorts) 0 >>> while len(bagosorts) < 24: bagosorts.add(thecombo) shuffle(thecombo) Traceback (most recent call last): File "", line 2, in bagosorts.add(thecombo) TypeError: list objects are unhashable >>> # shit! >>> while len(bagosorts) < 24: bagosorts.add(tuple(thecombo)) shuffle(thecombo) >>> len(bagosorts) 24 >>> print bagosorts set([('B', 'A', 'D', 'C'), ('A', 'D', 'B', 'C'), ('A', 'C', 'D', 'B'), ('B', 'C', 'D', 'A'), ('B', 'D', 'C', 'A'), ('C', 'D', 'B', 'A'), ('C', 'A', 'B', 'D'), ('D', 'B', 'A', 'C'), ('B', 'A', 'C', 'D'), ('A', 'D', 'C', 'B'), ('D', 'C', 'A', 'B'), ('C', 'A', 'D', 'B'), ('C', 'B', 'A', 'D'), ('D', 'A', 'B', 'C'), ('A', 'B', 'D', 'C'), ('D', 'C', 'B', 'A'), ('C', 'B', 'D', 'A'), ('A', 'B', 'C', 'D'), ('B', 'D', 'A', 'C'), ('B', 'C', 'A', 'D'), ('D', 'B', 'C', 'A'), ('D', 'A', 'C', 'B'), ('A', 'C', 'B', 'D'), ('C', 'D', 'A', 'B')]) """ Kirby -------------- next part -------------- An HTML attachment was scrubbed... URL: From Scott.Daniels at Acm.Org Tue May 26 18:37:35 2009 From: Scott.Daniels at Acm.Org (Scott David Daniels) Date: Tue, 26 May 2009 09:37:35 -0700 Subject: [Edu-sig] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) In-Reply-To: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> References: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> Message-ID: gerry_lowry (alliston ontario canada) wrote: F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) > http://www.acm.org/ Also note, in this issue Mark Guzdial has a "Viewpoints" article entitled "Education Teaching Computing to Everyone." The article discusses Georgia Tech's policy of "all undergraduates students must take a CS course" experiences for the last ten years. They talk a lot about the success they've had, but at the cost of making several distinct courses. The requirement they used was, "students would 'be able to make algorithmic and data structure choices' when writing programs." Initially they used a course that had a success rate (end wit C or better) of 78% overall, but architecture, management, and public policy majors were at below 50%. Also, females failed at twice the rate of males. After moving to the newer cross-developed courses, they had those three groups all at over 85% success. They did three basic courses, the ongoing CS course, a MATLAB-based course for engineers, and a "media computation" (manipulate sound and images (really, at the level of pixel manipulation, not just crop and bind) using Python. The media course used Python as the language. The new media course achieved an 85% success rate for the three groups above, and had women succeeding at "the same or better rates than the male students." Apparently Guzdial wrote the thextbook for the media course, "Introduction to Computing and Programming in Python, a Multimedia Approach," Prentice Hall, 2005. This change was so successful that, second courses for both engineering and media are now in place (the demand was high), and they've introduced a CS minor. --Scott David Daniels Scott.Daniels at Acm.Org From kirby.urner at gmail.com Tue May 26 18:57:26 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 26 May 2009 09:57:26 -0700 Subject: [Edu-sig] F.Y.I.: this month's cover story for CACM is "OLPC: Vision vs. Reality" (cross posted) In-Reply-To: References: <88EE78086D514E608EE57A0392C52C74@zentrumvegan> Message-ID: Scott: > The media course > used Python as the language. ?The new media course achieved an 85% > success rate for the three groups above, and had women succeeding at > "the same or better rates than the male students." Interesting stuff Scott. My eldest did a combined theater-CS major in Tennessee (Clarksville, close to Nashville) plus we have titles discussing the interface in a theatrical context, almost impossible to think "API" and not think "puppet" (if you're a theater person). Given we don't have CS pre-college, at least not in PPS (Portland Public), yet a strong interest in theater, there's some thought to expand the theatrical track with Python in at least a few areas, with "people as objects" in the Sims / Avatar sense (been looking at this with Lindsey a little, Perl heritage, strong SVG skills). Another cohort: the phys ed teachers. Using these Google Streets cameras one has the ability the survey an ecosystem like Oaks Bottom (near Winterhaven) then start molding raw data and footage into GIS presentations, again using Python perhaps. I'm hoping some of these projects reach Vern Ceder's desk, even before the next Pycon. A dodecacam in Montana might be nice (an NPYM pipe dream at the moment, though I've met the CTO). Yo ho! I noticed a follow-up to Cherlin's by someone who seemed on the clueless side, assuming the severely under-served (in terms of electrification) would remain so, i.e. the background setting seemed static in his mind and in either/or competition with XOs i.e. "if you spend money on XOs, then you'll not be able to have any vaccines" or other trade-offs of a Draconian nature (reminds me of Pink Floyd's "how can you have any pudding if you don't eat your meat?!" -- one of those fuddy dud types). I posted about Jeff's eduPycon idea @ conferences list (Python.org), look forward to more thinking, also was nudged into Facebook groups by the leadership, admit to being a dweeb over here, spinning on my butt like that OSCON-purchased EuroPenguin with the Pythonic API and voice synthesizer (need to dust him off again? -- the new software does even more they tell me). Kirby From echerlin at gmail.com Wed May 27 02:28:28 2009 From: echerlin at gmail.com (Edward Cherlin) Date: Tue, 26 May 2009 17:28:28 -0700 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: References: Message-ID: On Sat, May 23, 2009 at 7:43 PM, kirby urner wrote: > I filed the following quick comment after viewing a six minute > tutorial on variables and values at ShowMeDo. > > The video: > > http://showmedo.com/videotutorials/video?name=6950010&fromSeriesID=695 > > My comment: > """ > idea that values are "stored into" a variable is less the metaphor in > Python, Yes, it is a relic of assembly language. A variable is not a section of memory. It is a pronoun which can have different referents at different times. One object can be referred to by many different personal names and a variety of pronouns at the same time. This is easier to explain in Japanese, which has numerous and ever-shifting sets of pronouns. "I" in English can currently correspond to o watashi o atashi o atai o boku o ore Historically, people could also have three, four, even a dozen personal names, some chosen for various private or public purposes, some awarded by teachers, some (rarely) awarded by the Emperor, and so on. > which is more about assigning or binding names to objects with > the assignment operator (=). ?The problem with "store into" is then > its hard to picture many names for the same object, yet that's easy > when you think of a balloon with many strings. > """ > For example, the so-called "equal sign" (=) would be better called an > "assignment operator" as most of us here do. We would do better to use a different symbol entirely. The only reason for the massive overloading practiced in conventional programming languages is the utterly obsolete ASCII character set. APL has used the left-pointing arrow '?' for assignment for decades, and treated '=' as a Boolean function returning a truth value. Just as APL has used the correct '?' and '?' rather than overloading ASCII characters further. J distinguishes the function '=' from assignment '=.'. > To make this link stick we could explain how the two parallel lines > represent "opening a channel to" i.e. now this name (on the left) will > be able to communicate with the object on the right (some result of > evaluation). -1 > Kirby > > PS: ?do Python's where Prada? > http://fashionshops.wordpress.com/2009/05/18/prada-ad-campaign-ss-2009/ > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig -- Silent Thunder (??/???????????????/????????????? ?) is my name And Children are my nation. The Cosmos is my dwelling place, The Truth my destination. http://earthtreasury.org/worknet (Edward Mokurai Cherlin) From kirby.urner at gmail.com Wed May 27 03:19:05 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 26 May 2009 18:19:05 -0700 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: References: Message-ID: On Tue, May 26, 2009 at 5:28 PM, Edward Cherlin wrote: > On Sat, May 23, 2009 at 7:43 PM, kirby urner wrote: >> I filed the following quick comment after viewing a six minute >> tutorial on variables and values at ShowMeDo. >> >> The video: >> >> http://showmedo.com/videotutorials/video?name=6950010&fromSeriesID=695 >> >> My comment: >> """ >> idea that values are "stored into" a variable is less the metaphor in >> Python, > > Yes, it is a relic of assembly language. > Or maybe it works well for many other languages too, as it's certainly a commonplace in CS, to talk about variables as little boxes, with value contents. I guess you could say C, FORTRAN etc. are just glorified assembly language, so your point remains. I like teaching that to each language their corresponds a set of short "cartoons" laying out ways to visualize that won't get you in trouble. It's not the case that every language is an approximation to the same underlying concepts, but rather that each clear and expressive language has a unique take, a strong individuality. PHP has a whole different idea of copying, when stuff in memory duplicates or doesn't. I was surprised when I started reading about it. "This isn't Python" I was thinking. But why should have that surprised me? APL isn't Python either. Only Python is Python. > A variable is not a section of memory. It is a pronoun which can have > different referents at different times. One object can be referred to > by many different personal names and a variety of pronouns at the same > time. This is easier to explain in Japanese, which has numerous and > ever-shifting sets of pronouns. "I" in English can currently > correspond to > > o watashi > o atashi > o atai > o boku > o ore > > Historically, people could also have three, four, even a dozen > personal names, some chosen for various private or public purposes, > some awarded by teachers, some (rarely) awarded by the Emperor, and so > on. > Hmmmm, not used to thinking of names as pronouns, but yeah, handles, I think of X-box remotes, other game consoles, in that now that I've got a handle ----- (string) ----> to some parade balloon, I'm able to query it as to air pressure, altitude, even have a small amount of write access (steering responsibility). In client = server, I'm thinking it's pull more than push, i.e. when I name an object, I'm not expecting things to "just happen to me" so much as my code gets to puppet the object or at least read its attributes (when it gets around to it, per flow of control). Python is more the standard imperative language in that way. On the other hand, with callbacks and sockets, everything gets a lot more "springy" i.e. every client is like a server (responsive) and every serve like a client (inquisitive). I think what you say about multiple identities is way more true today of your "average cyberian" in that we have our multiple monikers or handles or facebook identities, of necessity given the technology, so a world of masks, more like kabuki if that makes any sense (you sound way more knowledgeable about Japan). >> which is more about assigning or binding names to objects with >> the assignment operator (=). ?The problem with "store into" is then >> its hard to picture many names for the same object, yet that's easy >> when you think of a balloon with many strings. >> """ > >> For example, the so-called "equal sign" (=) would be better called an >> "assignment operator" as most of us here do. > > We would do better to use a different symbol entirely. The only reason Not sure who the "we" is, but I'm guessing you're right that a significantly sized subculture would wanna do that. > for the massive overloading practiced in conventional programming > languages is the utterly obsolete ASCII character set. APL has used > the left-pointing arrow '?' for assignment for decades, and treated > '=' as a Boolean function returning a truth value. Just as APL has > used the correct '?' and '?' rather than overloading ASCII characters > further. J distinguishes the function '=' from assignment '=.'. > Dunno that Latin-1 is "utterly obsolete" is just literally bottom-of-barrel bit patterns with lots of invested hours, so keeping it working is likely a high priority in many a silo. However, green field development with native naming, sprinkling of Python keywords, is very doable in 3.x, what I've been playing with along with an invisible army of nameless others I'm sure. osgarden.appspot.com was a meager attempt, is actually just 2.5 so I'm cheating. But then you're talking about sky's the limit whole other languages with not a lick of Latin-1, and yeah, I expect more of those too. Lots of biodiversity. These industrial strength languages are a lot of work though, huge time sinks, like pyramids, so tossing a little language out there and expecting it to snowball needn't be "every kids dream". Just having some hard fun in a lexical sandbox is an end in itself, is one of our little commercial messages. That's preaching to the choir in geekdom, but helping strangers take delight in our tools sometimes takes clever packaging (the XO is very clever packaging for Python, the way I see it). >> To make this link stick we could explain how the two parallel lines >> represent "opening a channel to" i.e. now this name (on the left) will >> be able to communicate with the object on the right (some result of >> evaluation). > > -1 > Assuming -1 because you don't like the metaphor, aren't really expecting Python to adopt APL like new syntax (unlikely -- Guido doesn't seem to fight his Latin-1 heritage the way some do). Kirby >> Kirby >> >> PS: ?do Python's where Prada? >> http://fashionshops.wordpress.com/2009/05/18/prada-ad-campaign-ss-2009/ >> _______________________________________________ >> Edu-sig mailing list >> Edu-sig at python.org >> http://mail.python.org/mailman/listinfo/edu-sig > > -- > Silent Thunder (??/???????????????/????????????? ?) is my name > And Children are my nation. > The Cosmos is my dwelling place, The Truth my destination. > http://earthtreasury.org/worknet (Edward Mokurai Cherlin) > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > From kirby.urner at gmail.com Wed May 27 06:15:37 2009 From: kirby.urner at gmail.com (kirby urner) Date: Tue, 26 May 2009 21:15:37 -0700 Subject: [Edu-sig] Simple Stats (curriculum fragment...) Message-ID: """ Simple randomizer and tally machine. Drop a ball 'howmany' times so it falls left or right for 'howmany' rows of pegs -- like Pachinko http://www.4dsolutions.net/ocn/graphics/randtrianim.gif (c) GPL, 4D OCN 2009 Python 3.0.1 (r301:69556, Mar 14 2009, 14:06:26) [GCC 4.2.4 (Ubuntu 4.2.4-1ubuntu3)] on linux2 """ from random import randint def leftright(): """ spit out L or R (left or right) until the cows come home """ while True: yield ['R','L'][randint(0,1)] def the_fall(howfar): """ drop from the top: go left or right for however far """ mypath = [] for i in range(howfar): mypath.append(next(y)) # using da generator return mypath def many_falls(howmany, howfar): """ dropping the ball, building a dictionary (sample) Order of Ls and Rs in a single fall leads to same final position, so index by string e.g. LLLLRRR """ counters = {} for i in range(howmany): thepath = "".join((sorted(the_fall(howfar)))) counters[thepath] = counters.setdefault(thepath,0) + 1 return counters def display(sample): """ spit out the fall strings in alpha order with associated counts """ thekeys = sorted(sample.keys()) for i in thekeys: print("%s : %4d" % (i, sample[i])) def test(): """ run a sample, display the results """ global y # so we can use it anywhere! y = leftright() sample = many_falls(10000, 10) display(sample) if __name__ == '__main__': test() ========== Multiple runs: >>> LLLLLLLLLL : 15 LLLLLLLLLR : 109 LLLLLLLLRR : 438 LLLLLLLRRR : 1205 LLLLLLRRRR : 1976 LLLLLRRRRR : 2491 LLLLRRRRRR : 2118 LLLRRRRRRR : 1138 LLRRRRRRRR : 416 LRRRRRRRRR : 84 RRRRRRRRRR : 10 >>> LLLLLLLLLL : 11 LLLLLLLLLR : 96 LLLLLLLLRR : 454 LLLLLLLRRR : 1144 LLLLLLRRRR : 2027 LLLLLRRRRR : 2444 LLLLRRRRRR : 2066 LLLRRRRRRR : 1194 LLRRRRRRRR : 443 LRRRRRRRRR : 111 RRRRRRRRRR : 10 >>> From lac at openend.se Wed May 27 10:25:43 2009 From: lac at openend.se (Laura Creighton) Date: Wed, 27 May 2009 10:25:43 +0200 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: Message from Edward Cherlin of "Tue, 26 May 2009 17:28:28 PDT." References: Message-ID: <200905270825.n4R8PhVN011162@theraft.openend.se> I no longer think that the problem is that the '=' symbol is overloaded. I now believe that the problem is that when we, as teachers teach Python, we read a = b as 'a equals b' and if we forbid that language usage of the word equals, and always said 'a is bound to b' instead, then, in students who are learning their first programming language and don't come with C baggage, the problem will not arise, in much the same way that using * for multiplication does not cause a problem. So far this has worked, by my experiment has only been performed with 6 students so far -- hardly a large enough experiemental set. And the experiment is flawed because it is still quite difficult for me to stop saying 'equals', so I still use the forbidden words every so often. Telling the sudents they can point and make faces at me every time I slip up does wonders for improving me. Laura From lac at openend.se Wed May 27 11:28:35 2009 From: lac at openend.se (Laura Creighton) Date: Wed, 27 May 2009 11:28:35 +0200 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: Message from Laura Creighton of "Wed, 27 May 2009 10:25:43 +0200." <200905270825.n4R8PhVN011162@theraft.openend.se> References: <200905270825.n4R8PhVN011162@theraft.openend.se> Message-ID: <200905270928.n4R9SZkD014866@theraft.openend.se> p.s. Here is a test to see if your students understand about binding, or if they are walking around with it confused with equality. >>> class Animal: ... def __init__(eyecolour, sound, action): ... self.eyecolour = eyecolour ... self.sound = sound ... self.action = action ... >>> cat = Animal('green', 'miaux', 'pounce') >>> dog = Animal('brown', 'woof', 'wag') >>> vlerb = Animal('green', 'miaux', 'pounce') Now go ask them if what they think vlerb == cat will print. This is an easier place to clear up the misunderstanding than the first time they start passing mutable objects as defaults to a function or a method, which is where my classes in the past have tended to blow up with this sort of misunderstanding. Laura From kirby.urner at gmail.com Wed May 27 17:52:38 2009 From: kirby.urner at gmail.com (kirby urner) Date: Wed, 27 May 2009 08:52:38 -0700 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: <200905270825.n4R8PhVN011162@theraft.openend.se> References: <200905270825.n4R8PhVN011162@theraft.openend.se> Message-ID: On Wed, May 27, 2009 at 1:25 AM, Laura Creighton wrote: > > I no longer think that the problem is that the '=' symbol is overloaded. > I now believe that the problem is that when we, as teachers teach Python, > we read a = b as > 'a equals b' > Yeah, the word "overloaded" is itself overloaded in that it contains a bias, as we often suppose overloading is a bad thing, like an overloaded bus on a mountain road in Peru, whereas this might just be the standard rural bus, being used efficiently, and it only *looks* overloaded to the tourists. With the doctrine of namespaces already in place ("philosophy for children" thread), it's easier to say: "we have these bones or ivories or mahjong chips that we might recycle endlessly in any number of games and no, the little guy in chess (pawn) is not the same as the little guy in Monopoly (hat), but you could use the pieces interchangeably in a pinch". Likewise, a $ in Perl is unlike a $ in $1.99 and a ** in Python is rather like a ^ in BASIC. Look in the J dictionary (jsoftware.com) and all these familiar symbols are "repurposed" once again. Do the Great Lamba people to the north long to use an actual Greek lambda in native LISP in place of any spelling-it-out in ASCII, now that we have Unicode? I have no idea. You can call it "overloading" but why not just call it "recycling" i.e. taking symbols we've already grown accustomed to seeing, know how to write, and having them mean something different in different language games. "What a concept!" (sarcastic Monty Python voice, annoying laugh track). Being able to do this would imply that humans themselves are highly adaptable around how they use symbols and quickly learn new rules even where the idea of a "ball" is itself used over and over and over.... I agree this is the implication. Humans come into the world highly auto-reprogrammable, often take delight in so doing. Python comes with this OO mythos (mythology). In some "focus groups" (imagine a teacher prep session) we might start with Greek goddesses and gods as primary types, examining their attributes, reinforcing some humanities stuff we'd like 'em to know anyway. Like, I've been suspicious of this Apollo character lately, over what he supposedly did to some Python, take comfort in having Athena appreciate a wisdom Apollo may not get. But hey, not everyone wants to cogitate in those terms, not saying the Greek stuff (ala Disney's 'Hercules') is everyone's cup of tea. However, using Python in the humanities, like in theater, is looking promising. Given some high schools will send us grads already so-equipped, as literature professors, we'll be able to dive in with gusto, talking about "polymorphism" without starting from scratch. Dr. Hugh Kenner was a trailblazer in this regard (Joyce scholar, Bucky biographer, wrote a column for BYTE). > and if we forbid that language usage of the word equals, and always said > 'a is bound to b' Or 'a tags what b tags' or... many synonymous expressions, which if you hear a natural language teacher teach, you'll note is a common technique, repeating the same thing using slightly different analogies or characterizations each time, building up the "synonym base". Humans rely on association and mnemonic short cuts e.g. I use "gnu math" to help fuse the idea of running FOSS on commodity hardware in algebra class (like "of course!"). > instead, then, in students who are learning their first programming language > and don't come with C baggage, the problem will not arise, in much the > same way that using * for multiplication does not cause a problem. > Imagine you're an algebra teacher, first day of class, and these 8 students (pretty small class -- that's why this is considered an elite school) taking their seats already know Python. You're not there to teach them Python but to leverage that knowledge in service of transmitting mathematical concepts, in algebra, and in algebra applied to geometry (i.e. we're not ignoring the graphical, just because it's an algebra class, gotta do that group theory with polyhedra stuff, play some fun computer games around that). > So far this has worked, by my experiment has only been performed with 6 > students so far -- hardly a large enough experiemental set. ?And the > experiment is flawed because it is still quite difficult for me to stop > saying 'equals', so I still use the forbidden words every so often. > Telling the sudents they can point and make faces at me every time I > slip up does wonders for improving me. > > Laura I have all these meetings with teachers around Portland then package it up for export to gnu math teacher circles in the Philippines and places. Because OCN binds its Pythonic Math to a lot of niche market geometric content, mostly using VPython, I'm imagining my teacher base having assorted interests in common, which is borne out by much of the feedback. I transplanted that little fragment of 3.x re Bell Curve to my gnu math distribution vehicle, an archive at Drexel, knowing the teachers pawing through there are likely already Python literate, aren't especially interested in any evangelism for the language ("that's for other people not us"): http://mathforum.org/kb/thread.jspa?threadID=1942369&tstart=0 OK, time for my first meeting of the day... I have this "neolithic math" component in our place based curriculum. We keep going back to this "cave man" setting, but lo and behold their inner circle know quite a bit about world geography and navigation, per recent scholarship (anyway Sumerians were "cave men" and calling it "neolithic" is maybe more marketing than literal -- it's not "prehistoric", not literally). Sometimes we meet in Old Town, that part of Portland consider most Chinese in character. An important aspect of our subculture out here is our Pacific Rim identity, e.g. the Naito family, other Japanese heritage. Seattle is a lot the same way. So this business about working with Filipinos is hardly a new development, was doing it with AFSC (a nonprofit) plus grew up there (high school years). The fact that the RP, like the RSA, is highly anglophone (English-speaking) makes these business relationships all that much easier to form. I got both my XOs from a Chinese family I've known since International School days. Anyway, just filling ya'll in on some local geography, not sure how many on this list have actually been to Portland ever, though I know Laura, you have. Kirby > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > From kirby.urner at gmail.com Wed May 27 18:04:40 2009 From: kirby.urner at gmail.com (kirby urner) Date: Wed, 27 May 2009 09:04:40 -0700 Subject: [Edu-sig] Overloading (was Re: more on "variable names") In-Reply-To: References: <200905270825.n4R8PhVN011162@theraft.openend.se> Message-ID: On Wed, May 27, 2009 at 8:52 AM, kirby urner wrote: << SNIP >> > OK, time for my first meeting of the day... ?I have this "neolithic > math" component in our place based curriculum. ?We keep going back to > this "cave man" setting, but lo and behold their inner circle know > quite a bit about world geography and navigation, per recent > scholarship (anyway Sumerians were "cave men" and calling it > "neolithic" is maybe more marketing than literal -- it's not > "prehistoric", not literally). Sumerians were *not* cave men, meant to say. We've had lots of cave men on TV ever since the Geiko commercials, not all of you in USA TV bubble I realize (it's an intense bubble, actually a foam). Having Conan the Barbarian types transplanted to a civilized context, seeing therapists and stuff, is a long-running humorous thread in popular culture, right up there with "future civilized" forced to live in the past or our present. Some of you may be following my proposals to have a Python User Group on television, with an inevitable Mickey Mouse Club vibe, though without conscious copying. That's why I was taking that "let them sue, good publicity" line on the PSF list, regarding the Pinoy User Group use of a "mouse ears" motif, which I think was somewhat unintentional on their part: http://www.flickr.com/photos/17157315 at N00/3544467917/ Use of cartoon characters in an intellectual property context was also one of my themes at Gothenberg Europython (the last one in that city), as you'll see from my slides (pictures of TinTin, Donald Duck, plus a complete replica of some USA gas station, straight out of eXistenZ one might think, but in Liseberg). Kirby From kirby.urner at gmail.com Thu May 28 08:45:57 2009 From: kirby.urner at gmail.com (kirby urner) Date: Wed, 27 May 2009 23:45:57 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) Message-ID: The code below is somewhat boringly similar to other stuff I've archived here before, about finding all the totatives (defined below) of some N, then multiplying all possible pairs (a Cartesian product) modulo N to show how you've got closure i.e. you never get outside the group. The totatives of N are the numbers 1...(N-1) with no factors in common with N. If N is prime, every integer 1...(N-1) is a totative. The totient of N is *how many* totatives it has. Think how it'd only take you a few lessons to have your students impressing their guardians with stuff Euler talked about (make sure they pronounce "Euler" right). Hey, did you know Ellipsis is a new primitive object in Python 3, denoted ... ? >>> ... Ellipsis What's a little bit different in this pass is I'm applying some stuff I learned from Steve Holden @ Pycon re iterators, other subsequent trainings. Iterators are "one way streets" that become exhausted (dead end in StopIteration) so you might need to clone them ahead of time. The itertools tee is good for that e.g. lazyA, lazyB = itertools.tee( iteratorX ) will give you two for the price of one, then don't use iteratorX anymore (it's exhausted). Below, I want the totient (== number of totatives), so consume a whole iterator going totient = len(list(theiterator)) -- but fortunately I tee first. Hey, I was just learning from David Beazley on Safari that __repr__ is generally supposed to emit a string that'll eval right back to the object represented. So if I have Modulo type and go k = Modulo(10) then my __repr__ should maybe just emit 'Modulo(10)'. __str__ is for something prettier maybe (adding makeup). itertools.product will pair each with every, given two iterators (actually, takes any number, proceeds odometer style), but again, if you were to use the same iterator twice, you'd end up consuming all the rows so nothing left for columns or vice versa. That's where the repeat keyword argument comes in, which I use as an alternative to tee for a check (see multiply_a vs. multiply_b). Other little known features of Python 3.x, the ability to write: >>> def f(x:int) -> int: return x * x >>> f.__annotations__ {'x': , 'return': } The new __prepare__ method allowing processing in the classdict you're about to hand off to __new__, bolstering metaclass definitions. Set and dictionary comprehensions, cool. I play with a set comprehension below, limiting the output of the Cayley table to unique terms only (note curly braces in output) -- what takes the most room are the powering tables, where I take each totative t and go pow( t, e, N) with e ranging from 0 to totient-1 (a list comprehension). This relates to RSA. Also this is kinda weird (newly legal syntax): >>> alpha, *junk, omega = "This is sorta cool syntax eh?".split() >>> alpha 'This' >>> junk ['is', 'sorta', 'cool', 'syntax'] >>> omega 'eh?' >>> OK, the rest is source code, with output listed at the end... """ product does a cartesian product of two iterables tee replicates iterables 'repeat' times (default repeat=2) More of what this is actually about: http://www.4dsolutions.net/ocn/flash/group.html (yikes, evil noise! turn down those headphones!) """ from itertools import product, tee def gcd(a,b): """ EA per Guido """ while b: a, b = b, a % b return a def tots(n): """ returns iterator of no factors in common (totatives) """ return (i for i in range(n) if gcd(i, n) == 1) def multiply_a(ts,n): """ Cayley Table of ts x ts modulo n """ ps = product(ts, repeat=2) return (i*j % n for i,j in ps) def multiply_b(ts,n): """ Cayley Table of ts x ts modulo n (alternate implementation) """ row, col = tee(ts) ps = product(row, col) return (i*j % n for i,j in ps) def powers(ts,n): a,b = tee(ts) totient = len(list(b)) for t in a: print([pow(t,exp,n) for exp in range(totient)]) def test(n): print({i for i in multiply_a(tots(n),n)}) # print({i for i in multiply_b(tots(n),n)}) powers(tots(n),n) if __name__ == '__main__': test(12) test(15) test(21) test(24) So what's the printout if you run it?.... >>> ================================ RESTART ================================ >>> {1, 11, 5, 7} [1, 1, 1, 1] [1, 5, 1, 5] [1, 7, 1, 7] [1, 11, 1, 11] {1, 2, 4, 7, 8, 11, 13, 14} [1, 1, 1, 1, 1, 1, 1, 1] [1, 2, 4, 8, 1, 2, 4, 8] [1, 4, 1, 4, 1, 4, 1, 4] [1, 7, 4, 13, 1, 7, 4, 13] [1, 8, 4, 2, 1, 8, 4, 2] [1, 11, 1, 11, 1, 11, 1, 11] [1, 13, 4, 7, 1, 13, 4, 7] [1, 14, 1, 14, 1, 14, 1, 14] {1, 2, 4, 5, 8, 10, 11, 13, 16, 17, 19, 20} [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1] [1, 2, 4, 8, 16, 11, 1, 2, 4, 8, 16, 11] [1, 4, 16, 1, 4, 16, 1, 4, 16, 1, 4, 16] [1, 5, 4, 20, 16, 17, 1, 5, 4, 20, 16, 17] [1, 8, 1, 8, 1, 8, 1, 8, 1, 8, 1, 8] [1, 10, 16, 13, 4, 19, 1, 10, 16, 13, 4, 19] [1, 11, 16, 8, 4, 2, 1, 11, 16, 8, 4, 2] [1, 13, 1, 13, 1, 13, 1, 13, 1, 13, 1, 13] [1, 16, 4, 1, 16, 4, 1, 16, 4, 1, 16, 4] [1, 17, 16, 20, 4, 5, 1, 17, 16, 20, 4, 5] [1, 19, 4, 13, 16, 10, 1, 19, 4, 13, 16, 10] [1, 20, 1, 20, 1, 20, 1, 20, 1, 20, 1, 20] {1, 5, 7, 11, 13, 17, 19, 23} [1, 1, 1, 1, 1, 1, 1, 1] [1, 5, 1, 5, 1, 5, 1, 5] [1, 7, 1, 7, 1, 7, 1, 7] [1, 11, 1, 11, 1, 11, 1, 11] [1, 13, 1, 13, 1, 13, 1, 13] [1, 17, 1, 17, 1, 17, 1, 17] [1, 19, 1, 19, 1, 19, 1, 19] [1, 23, 1, 23, 1, 23, 1, 23] >>> As I said, kinda boring maybe.... Kirby From Scott.Daniels at Acm.Org Thu May 28 17:27:30 2009 From: Scott.Daniels at Acm.Org (Scott David Daniels) Date: Thu, 28 May 2009 08:27:30 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: kirby urner wrote: > ... Hey, did you know Ellipsis is a new primitive object in Python 3, denoted ... ? > >>>> ... > Ellipsis Actually, it has been around for quite a while. Try this in even a much older Python: >>> class Funny(object): def __getitem__(self, *args): return args >>> Funny[1, ..., 10] (1, Ellipsis, 3) >>> Ellipsis Ellipsis --Scott David Daniels Scott.Daniels at Acm.Org From kirby.urner at gmail.com Thu May 28 17:22:15 2009 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 28 May 2009 08:22:15 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: On Wed, May 27, 2009 at 11:45 PM, kirby urner wrote: << SNIP >> > Hey, I was just learning from David Beazley on Safari that __repr__ is > generally supposed to emit a string that'll eval right back to the > object represented. ?So if I have Modulo type and go k = Modulo(10) > then my __repr__ should maybe just emit 'Modulo(10)'. ?__str__ is for > something prettier maybe (adding makeup). > Speaking of David Beazley, not all published books about Python on Safari are of equally high quality and David's seem among the best. I was reading about descriptors, again per Holden workshop, and noticing the author adding at class level, but never making use of the passed instance argument, only self (inside the descriptor). David, on the other hand, explicitly tells us not to instantiate descriptors at the instance level (they're meant for the classdict) but then shows using one to pass through to the instance __dict__, using __set__ and __get__ to communicate at the instance level. This is what one would expect of attributes as the "normal" case is instance-level attributes (stuff in self.__dict__) and the first advanced Python book I was reading demonstrated no awareness of that, plus handed off to other writers in the case of needing some heavy lifting (OK to do, but I thought this one, not by David, over did it). He prepends a "_" to make sure the attribute name doesn't collide with its own instance-level key in self.__dict__. Here's some related material: >>> class Codeguardian: def __init__(self,codeword=None): print("I am here master...") self.default = 0 self.payme = 0 self.codeword = codeword def __set__(self, instance, value): print("I shall perform my duty...") self.payme += 1 if (value == self.codeword or value in range(5)): setattr(instance,"_thecode",value) else: print("the value was rejected, pah!") def __get__(self, instance, klass): print("I shall fetch ._thecode") self.payme += 1 if "_thecode" not in instance.__dict__: print("I have set it to 0 for you sir/mam!") setattr(instance,"_thecode",0) return instance._thecode >>> class Castle: def __init__(self, name): self.name = name # build castle real quick >>> mycastle = Castle("Somewhere Special") >>> mycastle.keeper = Codeguardian("hello kitty") I am here master... >>> myothercastle = Castle("Somewhere Less Special") >>> myothercastle = Codeguardian("pssst!") I am here master... >>> mycastle.keeper = 4 >>> mycastle.keeper 4 >>> mycastle.__dict__ {'keeper': 4, 'name': 'Somewhere Special'} OK, this isn't going according to plan at all. Why? Because I did what David said not to do and tried stuffing my Codeguardian into an instance of Castle, rather than into the Castle class itself. Result, __getattribute__ and __setattr__ don't find my Codeguardian when I go to set the "keep" attribute. So let's try that again: >>> Castle.keep = Codeguardian("hello kitty") I am here master... >>> mycastle = Castle("Somewhere Special") >>> myothercastle = Castle("Somewhere Less Special") >>> mycastle.keeper = 4 >>> mycastle.keep = "the crown jewels" I shall perform my duty... the value was rejected, pah! >>> mycastle.keep = 4 I shall perform my duty... >>> myothercastle.keep I shall fetch ._thecode I have set it to 0 for you sir/mam! 0 >>> myothercastle.__dict__ {'_thecode': 0, 'name': 'Somewhere Less Special'} >>> mycastle.__dict__ {'keeper': 4, '_thecode': 4, 'name': 'Somewhere Special'} >>> OK, that worked, except I left in the goof where I set "keeper" instead of "keep", cluttering my instance __dict__ with some worthless DNA. Or maybe that was intentional? The point here is the Codeguardian works for the class, even if it has a way to communicate with the instance at the time of setting and getting. In David's example, the instance __dict__ key is built by prepending a "_" to a passed in variable name so the same Codeguardian may be set to guard several unique attributes.** I question here is how does Codeguardian get paid, since he's clearly keeping an internal tally. How do we get at the instance level properties of Codeguardian? First, note that there's nothing to prevent just poking a value for _thecode directly into an instance: >>> mycastle.__dict__["_thecode"]="hah, got around ya!" >>> mycastle.__dict__ {'keeper': 4, '_thecode': 'hah, got around ya!', 'name': 'Somewhere Special'} >>> mycastle.keep I shall fetch ._thecode 'hah, got around ya!' Anyway, recommended: Python Essential Reference, Fourth Edition By: David M. Beazley Last Updated on Safari: 2009/04/30 Kirby ** David's example: class TypedProperty(object): def __init__(self,name,type,default=None): self.name = "_" + name self.type = type if default: self.default = default else: self.default = type() def __get__(self,instance,cls): return getattr(instance,self.name,self.default) def __set__(self,instance,value): if not isinstance(value,self.type): raise TypeError("Must be a %s" % self.type) setattr(instance,self.name,value) def __delete__(self,instance): raise AttributeError("Can't delete attribute") class Foo(object): name = TypedProperty("name",str) num = TypedProperty("num",int,42) From kirby.urner at gmail.com Thu May 28 17:24:32 2009 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 28 May 2009 08:24:32 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: Hey, didn't know that! And that *is* a Funny class you made there, quite twisted thx! Kirby On Thu, May 28, 2009 at 8:27 AM, Scott David Daniels wrote: > kirby urner wrote: >> >> ... Hey, did you know Ellipsis is a new primitive object in Python 3, >> denoted ... ? >> >>>>> ... >> >> Ellipsis > > Actually, it has been around for quite a while. ?Try this in even a much > older Python: > > ? ?>>> class Funny(object): > ? ? ? ? ? ?def __getitem__(self, *args): > ? ? ? ? ? ? ? ?return args > ? ?>>> Funny[1, ..., 10] > ? ?(1, Ellipsis, 3) > ? ?>>> Ellipsis > ? ?Ellipsis > > --Scott David Daniels > Scott.Daniels at Acm.Org > > _______________________________________________ > Edu-sig mailing list > Edu-sig at python.org > http://mail.python.org/mailman/listinfo/edu-sig > From kirby.urner at gmail.com Thu May 28 17:38:35 2009 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 28 May 2009 08:38:35 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: On Thu, May 28, 2009 at 8:22 AM, kirby urner wrote: << SNIP >> > I was reading about descriptors, again per Holden workshop, and > noticing the author adding at class level, but never making use of the > passed instance argument, only self (inside the descriptor). > Below is the example from the other book, for contrast. Note how the "instance" variable is not used in __set__ or __get__, so whereas it looks like you're getting a new attribute there at the end (new_att), you're not getting anything new at instance level. David's exposition was clearer. ============== Let's create a data descriptor, and use it through an instance: >>> class UpperString(object): ... def __init__(self): ... self._value = '' ... def __get__(self, instance, klass): ... return self._value ... def __set__(self, instance, value): ... self._value = value.upper() ... >>> class MyClass(object): ... attribute = UpperString() ... >>> instance_of = MyClass() >>> instance_of.attribute '' >>> instance_of.attribute = 'my value' >>> instance_of.attribute 'MY VALUE' >>> instance.__dict__ = {} Now if we add a new attribute in the instance, it will be stored in its __dict__ mapping: >>> instance_of.new_att = 1 >>> instance_of.__dict__ {'new_att': 1} But if a new data descriptor is added in the class, it will take precedence over the instance __dict__: >>> MyClass.new_att = MyDescriptor() >>> instance_of.__dict__ {'new_att': 1} >>> instance_of.new_att '' >>> instance_of.new_att = 'other value' >>> instance_of.new_att 'OTHER VALUE' >>> instance_of.__dict__ {'new_att': 1} ============= Expert Python Programming: Learn best practices to designing, coding, and distributing your Python software Tarek Ziad? Copyright ? 2008 Packt Publishing From Scott.Daniels at Acm.Org Thu May 28 18:21:44 2009 From: Scott.Daniels at Acm.Org (Scott David Daniels) Date: Thu, 28 May 2009 09:21:44 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: Scott David Daniels wrote: > kirby urner wrote: >> ... Hey, did you know Ellipsis is a new primitive object ... > Actually, it has been around for quite a while.... [broken example] Sorry, everybody, I started writing, tried the code, and editted the reply, rather than taking direct quotes. In doing so, I slipped up. I'm embarrassed enough that I'm going to re-post: >>> class Funny(object): def __getitem__(self, *args): return args >>> psuedo_array = Funny() >>> psuedo_array[1, ..., 10] ((1, Ellipsis, 10),) >>> Ellipsis Ellipsis Just to add some actual content: I believe this was first put in to help out array processing and heavy computation projects. The biggest survivors / descendants of those projects are Scipy & Numpy. By the way, Funny is actually a fairly useful class for experiments. --Scott David Daniels Scott.Daniels at Acm.Org From kirby.urner at gmail.com Thu May 28 19:03:39 2009 From: kirby.urner at gmail.com (kirby urner) Date: Thu, 28 May 2009 10:03:39 -0700 Subject: [Edu-sig] poking around in Py3k (recycling old algebra) In-Reply-To: References: Message-ID: Where I could see Ellipsis being used is in an OEIS-like context (Sloan's AT&T thing) and going like [1, 12, 42, 92, ...] which you then feed to a factory function, say get_seq. get_seq has lookup powers (ala OEIS) and loads the right looping construct, then gives you an itertools like thingy that spits out the supplied values without recomputing them, then kicks in with the generated values once the ... is encountered). e.g. >>> from oeis_lib import get_seq >>> cuboctahedrals = get_seq([1, 12, 42, 92, ...] >>> next(cuboctahedrals) 1 >>> ... For example, an open-ended iterable for cuboctahedral numbers may be written as: >>> class CCP: def __init__(self): self.value = -1 def __next__(self): self.value += 1 if self.value == 0: return 1 else: return 10 * pow(self.value, 2) + 2 def __iter__(self): return self >>> seq = CCP() >>> next(seq) 1 >>> next(seq) 12 >>> next(seq) 42 >>> next(seq) 92 >>> next(seq) 162 If you wanted an iterable that kicked in only after 92, you could go: >>> from itertools import dropwhile >>> evaldotdot = dropwhile(lambda x: x <= 92, CCP()) >>> next(evaldotdot) 162 >>> next(evaldotdot) 252 >>> next(evaldotdot) 362 >>> next(evaldotdot) 492 >>> See: http://www.research.att.com/~njas/sequences/A005901 (hey, links to my web site! -- oh wait, I knew that) Kirby On Thu, May 28, 2009 at 9:21 AM, Scott David Daniels wrote: > Scott David Daniels wrote: >> >> kirby urner wrote: >>> >>> ... Hey, did you know Ellipsis is a new primitive object ... >> >> Actually, it has been around for quite a while.... [broken example] > [fixed example]