Guilhermesilveira's Blog

as random as it gets

Posts Tagged ‘mathematics

What’s in a word? From nowhere to software

leave a comment »

How careful should we be when borrowing words from the scientific world without paying proper attention to its meaning?

Its a common and good practice to borrow words in order to create meaningful metaphors which can better describe our point.

It is fine to take an already existing word or sentence and create a totally new meaning to it, as long as one doesn’t mention the previous consequences of the original meaning being consequences of the new one “just because”.

This wrong adoption of such words might create a false sensation of “meaningful logic” in a senseless phrase. In an abstract way, let’s say that there is a scientific proof of “A” and “B”, boolean symbols: “B is implied and only implied if A”. Now someone picks “A” and changes its meaning… one can not say that “B” is implied by “A” as now, “A” does not contain the same original meaning. It might be as much as true as much as it might be false.

In a practical way, the most common misuse of a word that I am aware of relates to “chaos” and/or the “edge of chaos”.

Chaos in mathematics is related to a specific sensation of random consequences while one still faces a deterministic situation. In other areas, chaos is related to darkness, nothing. Popular speaking its a matter of confusion. But only the first definition of chaos has a mathematical definition from which all chaos theory has evolved, therefore, right now, only if one uses this definition, it makes sense to talk about chaos exitence prooven consequences.

Bifurcation diagrams shows how the studied system works while applying diferent values for specific parameters. This leads to visuali-guessing when periodic orbitas leave the game and chaotic behaviour shows up. This time chaotic is being used in its mathematical definition.

Edge of chaos in wikipedia refers to the situation between chaos, randomness and order. But note that dynamical systems are deterministic in nature, therefore not random. At the same time, chaos is not defined as confusion (the opposite of order) in mathematical terms.

One can surely use “chaos” and “edge of chaos” as their popular definitions related to confusion, randomness and almost randomly, but this does not imply in any mathematical consequences studied by dynamical systems.

We commonly find ourselves talking about a lot of other words borrowed from biology or finances word, sometimes used to emphasize and sometimes to proof a point.

As Jurgens mentions, metaphors are good, we just need to be careful not to make funny statements, except if you define the way you will use the word prior to using it, even though its differente from the scientific meaning.

Written by guilhermesilveira

September 26, 2009 at 12:02 am

Posted in mathematics

Tagged with , ,

Agile methods and Mathematics

with 2 comments

The Agile Brazil 2009 meeting gave me something really nice to think about (and play with).For those who still do not know, I have studied Applied Math at USP and switched to Computer Applied Math. During my earlier years at the university, I have had a mentor who had his specialization in dynamical systems and chaos.

As a programming geek, many of my early efforts at Java and bytecode compilation using Janino were to build a software that was able to run iterative methods in order to qualitatively find specific conditions in a dynamical system, that was Pulga.

An attractor

Mathematically thinking, an attractor is a set which over continuous iteration of a function f, attracts some sets in such a way that, no matter how close i want to get to my attractor, i can get, in other words there is a finite number of iterations over f which, after those iterations, the distance of the result of any following iteration to this set is lesser than the distance that i want.

This – unformal – definition of an attractor is broad enough to let me define either a point or an open set as an attractor.

An initial condition over constant iteration through the f function can lead someone closer and closer to this set (which might not be unique) but all of the sudden, after a finite number of iterations, revert its situation to something else, as a chaotic behaviour for instance.

But who is attracted? The set of points whose orbit converges to this attractor is called that attractor’s basin of attraction. This means, that whichever point your start at, if its contained in that attractor’s basin, its orbit will converge to the attractor.

Agile iterations

During the event, one of the presenters made an really interesting comment on agile iterations and iterative methods. Iterative methods can be used to find minimums and maximums of functions – either locals or globals. Non-linear programming is (hated by many students) a subject which studies those methods and most of the comments I heard were somehow connected to either this subject or simulated annealing.

In an iterative development process, one can think of the retrospective as f function, which – we believe – will improve our situation over every iteration (time). The methodology used in the first iteration is the starting condition of our system and the infinite open set of possible methodologies  is our domain.

Every time the retrospective takes place, f is applied, and we get a different methodology which will be applied. This does not mean that it will converge to a local or global minimum as it might converge to a local or global maximum. Even more complex, its orbit might converge to an attractor set which is composed by methodologies situations that we perceive both as good and bad or our project and our team’s health.

During the talk, i was in doubt on how could we tell that applying f (the retrospective), the results were better. Of course, we have a lot of subjective ideas that might give us the perception of “improving”. The presenter also told about a good way of measuring results, the velocity.

Velocity is based on perception as the importance of features for the client might not be the improvement reality for the company. The guys at globo.com told me they were using “new open bugs” and “received calls” at the support desk as a measure of improvement. It seems like the “new open bugs” approach is really good to measure quality improvement but still not so good to measure “new features capability” improvements.

Mathematically thinking, improvement itself can be temporary and “f” can be leading us to even a worse attractor as it might not yet have reached a fixed orbit (or any similar set), giving us the impression that we are better right now and surprising us in the next year, when everything corrupts.

Parallel improvement

One of the fastest ways to find such attractors is to iterate many starting conditions instead of just one. The odds of finding attractors sooner is bigger. Even better, after a specific number of iterations over f, one can combine the conditions and create different ones – “genetically modifying your conditions”.

In the development world, that would be similar to, after realizing that the retrospectives are not helping any further, grab ideas which improved other projects within your company and bring them to your project, leaving the old ones to who else wants it. This leads to even more different conditions and increases, again, the odds of finding global minimums or attractors.

Why is it interesting for you?

I was really happy to see someone talking about development processes in such a way that we can mathematically define. Although it seems not yet mature for (myself) writing papers on it, the idea of iterative methods was always close to my life, and i have never noticed how it was part of my professional life.

Its the mix of math and other areas that allows us to see how we can create and innovate the way of thinking. So far we created a lot of things with our science base, now its time to take it to another level. Iteratively improving might help myself, what about you?

Written by guilhermesilveira

July 8, 2009 at 11:19 am