[BUG?] ScriptingSystem arithmetics

Bert Freudenberg bert at isg.cs.uni-magdeburg.de
Tue Oct 15 10:19:32 UTC 2002


Alan,

I think the "kids way" of doing math is the same as for everybody else:
formulas. If we had a formula editor that's reasonably easy to use, that
would be even more helpful than using universal tiles, in my opinion,
because they are essentially just a graphical presentation of a
programming language.

I could imagine that for numerical parameters, clicking the expand arrow
gives an empty "math tile" and a floating palette of operators similar to
the paint palette. You can type numbers and type or drag/drop operators in
there. Operands (other object's numerical readouts) can be dropped, too.

 Perhaps in an advanced mode, these operands could be assigned a
single-letter variable name. This would make complex formulas much more
readable.

A formula editor would most straightforwardly resemble what kids learn in
school. I think the problem is not the math itself, but the usually
awkward methods to write math in a computer language. Do you agree?

-- Bert

On Mon, 14 Oct 2002, Alan Kay wrote:

> Bert --
> 
> It's an "unfinished feature" in search of an idea. It's unfinished 
> because we didn't come up with a really nice and simple way to deal 
> with subexpressions in etoys. The idea was to solve this problem at 
> the next scripting level -- for Omniusers -- but this didn't get 
> finished either, so no solution was moved to etoys. I expect that all 
> of this will be much better and nicer in a few months. However, we 
> still don't have a great "kids way" to think about and make 
> subexpressions. Got any good ideas?
> 
> Cheers,
> 
> Alan
> 
> -----
> 
> At 12:14 PM +0200 10/14/02, Bert Freudenberg wrote:
> >I think this is a bug, or confusing at least:
> >
> >When constructing arithmetic expressions with tiles, they bind from right
> >to left. However, the graphic representation suggests a left-to-right
> >order, which also would be the "smalltalky" way of binding. It only gets
> >obvious when one looks at the textual representation.
> >
> >My particular case was limiting the range of a variable using min: and
> >max:. Of course, I constructed it as "[value][max:][-20][min:][20]". 
> >But the actual code generated is "value max: (-20 min: 20)".
> >
> >A workaround is to use "[-20][max:][20][min:][value]" which results in
> >"-20 max: (20 min: value)" but this is surprising, at best.
> >
> >I don't see a simple solution. Any ideas?
> >
> >-- Bert





More information about the Squeak-dev mailing list