Inigo Quilez   ::     ::  
1402 blog posts, written between 2008 and 2016. These are mostly short observations, funny thoughts and word playing. Some are embarrasingly corny, some more deep. I keep it here mostly a little time capsule for myself, organized by month:



<
March 2013
>
standing the test of time
2013-03-31
while reading about Betty Page the other day, i come across this documentary on bondage movies from the late 40s/early 50s by Irving Klaw. pretty awesome.

of course it's all very soft and tame for today's standards, and i doubt anybody would consider those big undergarments erotic these days. but i think that the rest of the attire and bondage holds pretty well, 60 years later (not that i'm an expert in knobs, though), which is pretty amazing!



the "bestest" commute to work ever
2013-03-29
it's not at all the fastest, shortest or easiest way to work.

i'm waiting at the red traffic light, looking up to California street. i usually turn right here and avoid the hill (the HiLLmalayas, as i call them in SF). but as i'm looking up there, while i have my eyes posed in that point in the very top where it gets tangent with the very sky, an idea crosses my mind.

i know. climbing these three blocks in front of me with my single speed bike seems like a suicide act. but what fantastic views i can enjoy if i get up there. the sun, the bay, the bridge, the city...

the traffic light goes green. but i don't turn right. instead i start pedaling straight fiercely. thankfully for me this is the back side of California Street (as known to the tourists, that is), so it's not as painful as one might think (insert joke on back sides not being as painful as pop culture claims them to be). indeed, despite my heart beats fast, all of my focus is the pedaling and my eyes don't move from the destination, i make it alive. and not only i make it alive to the top, but i make it with enough energy to smile on my arrival to the summit. and indeed, views are grand and inspiring.

i stop for a little bit to enjoy the moment. but not much, for i'm still just commuting to work after all. so i resume pedaling thinking that's it, this has been the magical moment of the day. however i'm wrong.

as i begin to sliding down California St by its front side, i start realizing the special thing i'm about to experience. in my focused climbing effort up the hill i hadn't payed attention to the fact that, for some reason, there's no traffic nor cars around me. it must be the time of the day (no wonder i'm pretty late, once again). for whatever reason, thing is i'm at the cross with Mason St looking down from and i cannot spot but a few cars in all the way to the ocean ten blocks from here. in fact, the city feels dormant. all i can see is a cable car, and a beautiful long street stepping down to the sea surrounded by light and shadows cast by the buildings, the blue sky, and of course, the warm soft breeze that i love so much. my heart starts beating again, not because of any physical effort, but because of the expectation of what's coming.

i give one impulse to the bike, and let gravity do the rest. slowly i start sliding. the air is warm, and i can see the bridge in front of me and the city below me. i then speed up, and at some point, i make a jump over the rails of the Powell-Hyde cable car line at its cross with California St. in my next block i draw S-curves with my bike as if i were skiing in the city. it feels like flying. then i have to slow down a bit, but that's perfect cause that allows me to enjoy the views for a longer time. pass Stockton i get into China Town, and from there, right when the Bay Bridge finally disappears below the horizon, i arrive to the financial district and its life and buildings and noises and people. it's all so beautiful right now that i want to cry. i slow down and do the last four blocks at the slowest speed i can, hand in pockets, with the biggest grin my face can accommodate.

i arrive to my destination. get of my bike slowly, and look up to the blue sky before bringing the bike up to my shoulders. this was a fucking amazing ride. and as with most good things, it was totally free.

so indeed this wasn't the fastest, shortest or easiest way to work. but for sure it was the bestest.
be extra careful
2013-03-27
if you are not wearing boxers or underwear of any form, then watch out for your fly. always remember to be extra careful when you are on one of those days of freedom and comfort.

not that anything has happened to me (or... has it?), but i thought it might be a good advice to give anyway
how adorable!
2013-03-25
I was reading a short article on the perception of robots by the American public in terms of partnership for companion, sex and even love (something Japanese are known to be more open to). The article was mainly a statistical study, and one of the highlight was that a surprisingly high amount of people recognized to be perfectly fine with the idea or an artificial partner. However, there's was a much less sensationalist kind of side result that caught more my attention: "Nearly 60% of Americans predicted that robots will be cleaning homes by 2030".

Now this was the really shocking part to me. People in general (both Americans and non-Americans, I think) seem to have no sense and measure of where science is, at all. They're pretty clueless, as their predictions proves, which to me feels a bit like when in the renaissance people would dream of a future of flying machines in form of bikes with wings and feathers. And, while dreaming is a necessity for progress, these things are in the very least just too naive, if not alarming (in a time when education was supposed to provide one some sort of understanding of science, which is obviously not the case yet, although I don't want to discuss that now).

Thing is, as of today we can barely teach a computer to tell the difference between a red square and a blue circle yet (unless we're under very clean and controlled lighting conditions). We can't even make a smartphone understand the words we are saying really, not to mention the actual "meaning" of our words. Reality is that, by 2030, we won't be even remotely close to have robots cleaning our houses. If anything, we'll have faster Facebook. And that's pretty much it.

So, yeah. People's ignorance is discouraging. But at the same time their naive hopes are somehow adorable.

mathimage #7: piano
2013-03-23
i made a piano this weekend for my “one realtime mathemagical image a week for a whole year”. it was a quick session, but the target was this time was clear, no doodling or wandering. instead, i decided i wanted to make a piano that looks like the one i have in my apartment. the point i wanted to make with this exercise was that "mathematical image" doesn't necessarily mean "terrains" or "fractals" or "arbitrary geometrical shapes", but it means anything you want. for example, a piano, why not. hence the very well defined target.



still the execution was improvised of course - not that i have done a mathematical piano before (or anybody, for the matter). also, due to technical issues in the current web browsers i could only go that far in the amount of detail. same goes for lighting - browsers are not powerful enough to do global illumination in realtime. lastly, composition wise, some very intense and saturated red roses in the left part of the frame (over the piano) would have made an super cool image. BUT, part of the game in these weekly challenges is to only sketch things (starting from scratch from a white canvas), then stop wait to the following weekend for a new challenge. still, i think i like the result.

as usual, i put the code online accessible for everybody to play with, and do changes to it live and see the results right in the browser: https://www.shadertoy.com/view/ldl3zN

the body of the piano is made of 4 boxes with round corners. the keys are one white box made periodic over the x axis, and a black box made periodic over the same axis except for multiples of 2 and 6. the feet are one cylinder (made the formula symmetric over x to get 2 of them for the prize of one) with a vertical sinus distortion. the music sheet is a thin box pushed out with a symmetric parabola. the bench, a box with a sinus deformation on top. walls and floor, planes. the window doesn't actually exist - i just indicate its presence by a soft-rectangular shaped formula with a cross in the middle which gets projected over the scene. the piano texture is some noise with horizontal patterns for subtle coloring. the broken paint, a grey coloring based on the local curvature of the piano formula (which sort of detects convexity, always a good indicator of exposure and hence age). the music is written with a vertical sinus to make the lines multiplied with a second sinus of one tenth of the frequency of the former, which creates the big white gaps that separate the paragraphs. the notes themselves don't exist - instead some very high contrast noise was used, modulated by the underlying lines themselves, in order to suggest there actually are notes there (one of the tricks in mathematical imagery is to simply "suggesting" things and let the brain of the viewer interpret the thing and do the rest of the job for you). the wood tiles in the ground are sinuses in x with a varying phase which is a function of z. lighting is done with my usual tricks for softshadows and fake occlusion (documented in my website), and so on.

it's not like before anymore
2013-03-21
what happened to the comedians? i love Eddie Izzard or Louis C.K, really. but still, clever as they are, i feel there's something missing. their sense of humor is "adorable" and "cute", but not really provoking, transgressive or challenging (Louis C.K. will swear and make fun of himself, but that doesn't count really). not direct enough of a critic to society. in fact, after having gone through almost all the material of George Carlin and Bill Hicks, the two real geniuses of intelligent comedy, i can only wonder what has happened, when did the our society get pussyfied?
compacting
2013-03-19
randoms thoughts in maths/science.

i've always been fascinated by the beauty of compacting theories.

but not only theories. even in the simplest interactions with maths you encounter constructions where the somehow magical powers of compaction manifests itself. when it does, it usually means you could have done something in a simpler way, but the fact that the thing arrives by itself anyway is fascinating, and almost mysterious.

like when you are describing something messy with your favorite notation, then you expand it into its elements, and start applying some standard techniques for simplifying things or rearrange terms, or simply move things around in the hope that some inspiration will work out some magic for you. then, most likely, you start slowly seeing things cancel out each other, patterns and symmetries appear, and eventually the whole thing reduces to a single, powerful expression that describes the original object or situation in a clean, concise, elegant way. and when things are seeing under this new self-uncovered optics, the result which was supposed to be the end of your mathematical journey, leads to a higher ideas, understanding and hence, more questions.

the fact that the results can often be described concisely means that the abstractions are higher of course. there's little to no abstraction in "2+2=4", it's the simplest form of conceptualization possible. symbols are quantities, operations or statements - there's little to no context needed to give it a meaning. however something like "E=mc²" or contains as many symbols, yet the ideas expressed are far more profound.

indeed, you need a bigger context to understand what those formulas mean, because the symbols compresses more meaning in them than a 100 page book can probably describe. yet, for the specialist, they are concise, simple, and describe beautiful relationships between the things around that matter to us. and in that sense, they become beautiful. and the compaction of a multiplicity of ideas and a variety of models in a simple expression, when it can be done, becomes the ultimate act of crafting beauty in knowledge.

this of course happens as a cascade of simplifications. when a new symbol or concept is invented for a set of ideas that got compacted into a single one, there's a second level of ideas that fly around that the mathematician will immediately try to understand, find a structure to and eventually compact in a single idea, reaching that way the third level of abstraction. and so forth. from what we know after few thousand years of compacting ideas at an exponentially rate, this seems to be and endless process.

or perhaps there's an end, and some day physicians are able to unify all forces, particles and micro effects together with the macroscopic world, and call it all with one final formula. perhaps something like "T(U)=0", where T is some sort of operator (much more complex than any current laplacian or anything we have now), and U is the universe (something more complex than just a tensor or anything we have now). i don't know what that would mean to us humans, though.
mathimage #5. cells
2013-03-17
or something like that. something organic for sure. which was completely unexpected, because my plan for this one was to make some techno scene with lasers and glowing neon lights. however, a couple of mistakes made me first derive from neon lights to some chrome tubular bells. then some random moves and doodling made the bells look like worms. and finally i decided to make it all look like some sort of living organic creepy thing.

the lesson is that when doing maths, not only you can doodle and start without any defined target, but you can also start driving the process with a very strong intention yet end up somewhere completely unexpected indeed. and that's part of the fun!

for the nerds, these are line segments connected to each other, which were made thick (like capsules) then deformed both in domain and range with cosinus functions to break the linear nature of the segments and make it all feel organic. there's some cheap (fake) ambient occlusion and cheap (fake) subsurface scattering going on that in fact work really good. everything else is massaging color, shaping gradients and in general putting a bit of love everywhere.

the making was about 4 hours, from a blank canvas, which definitely makes it my 5th image of the week for my "one realtime mathemagical image a week for a whole year". you can inspect the code, and change it and explore through the painting process here: https://www.shadertoy.com/view/Xdl3R4

teaching maths - on intuitions and beauty
2013-03-15
one of today's emails is from a math teacher i had at university long ago, with whom i didn't talk since i was 19. seems that back then i was already complaining about the way maths are taught, and that at some point i did a very cool presentation on my ideas and approach. i long ago lost count on the amount of little battles i've fought in form of talks, presentations and lectures , so of course i don't really remember that particular one he's referring to. however, from what he tells me in his email, seems that it had quote some effect in him.

intuitions

now that i think about it, my main point has always been the same: that during school, maths are formalized way too early. or perhaps, alternatively, that we never let kids use maths, play with them, and discover things by themselves before things get formalized. therefore they never get the chance to build intuitions. and trying to do maths without intuitions is like trying to find your way in a new city without a map.

my motivation to believe so comes from the observation that language learning, which usually is much smoother than math learning, happens very differently. basically, by the time kids are introduced to the formalization of language, to grammar and its syntax and structure, they already know how to speak. furthermore, they can perfectly read and write. not surprisingly, telling them that "a verb is an action", "a noun is an object" and "an adjective is a qualifier" suffices to teach them the terms we collectively agreed on for speaking of language, because they already know intuitively what a noun or verb is. indeed, in language learning formalization happens to be trivial, painless, smooth, and natural, for kids are already familiar with language. hence the last step of organizing the knowledge within a framework is actually the easy part.

with maths, however, that's no the case. that one terrible day the teacher arrives and announces "kids, we are going to learn trigonometry today" and introduces the notion of a cosinus and sinus, it is also the very first day kids ever get to examine angles and circles for the first time in their lives. crazy. no wonder this super-premature formalization of cosinus and sinus functions and their interrelations (described by weird formulas) alienates students to death. how wouldn't it.

to make an analogy, the situation is pretty much like that of pretending to teach musical theory and what a major 5th or a minor 3rd sound like the very first day in their lives that the students see and listen to a piano. of course, it makes a lot more sense to let them first play music, often for many years, and only afterwards teach them its structure formally. any other approach to music teaching would be condemned for making no sense at all. obviously! yet, that's exactly what we are doing with mathematics, throwing the whole thing at once to the students.

so, instead, what if kids had a chance to play with sinus waves, angles, circles, projections and shadows during 4 or 5 years? perhaps, that would allow them build their own intuitions and naturally understand these things. this could happen by means of visual problem solving, sound exercising, programming, drawing or any other method of direct manipulation of these objects. and what if after all of this playing, and only after the playing, we'd go for the formalization of the subject. my bet is that maths wouldn't be any more difficult to kids than it is to learn language.

i believe that there's a fundamental flaw in the current teaching method, and that it is one of the main reasons that prevents most people from grasping what maths actually are. and this is not a random believe, i'd say i can prove it. from my own studying experience during my engineering masters, which was heavily based in an "intuition construction" approach (including programming, osmosis, sleeping and relating things to other easier subjects), to all the people i ever met who i saw explaining the most abstract topics by using of very simple analogies and examples (topics that otherwise would have been considered difficult). such close examples have repeatedly proved to me the power of intuition and its role as the basis on which formal knowledge should be built upon.

so, taking into account that of course every person is different, and acknowledging the fact that every student has a different way to built intuitions - as some people are musical, others visual, others need spatial movement, others systematization, others narrative, others discovery - i think that a period of "playing with maths" is something that would benefit the grand majority if not all of the students. so, my suggestion would be to allow the students play for a few years indeed, and delay the formalization to later.

to make things even sadder, lets point to the fact that we are living in a world of computers, digital images and sounds, where not only we finally have the medium to make this new "intuitively playing with maths" paradigm possible and almost unavoidable. yet, we are avoiding it. seems to me digital devices are perceived only as a recreational gadgets. which is a pity, cause, perhaps, all those kids texting each other during the long math class are in fact holding the answer to the problem we are dealing with here right in their hands. this probably doesn't need more explanation, for we all know that if there's anything we humans have ever invented that is visual, dynamic, touchable, audible, interactive, intuitive, and well, a great platform for playing, that's the smartphone (/computer). we do have the best intuition-making tool in our hands and pockets.

beauty

a second but not less attention worthy issue is that of aesthetical teaching. i usually refer to this as "sexiness in teaching". i have the feeling that no matter how good the content of your message or story is, the format you present it in matters just as much in terms of effectivity.

these days we all expect to see beauty everywhere. not only we all want to look good or even be sexy (to the point people can get disappointed if they think they are not perceived as following the current standard of beauty), but we actually project the beauty as a value into the places we visit, items we consume and objects we own. indeed, the best selling devices and gadgets are sold for their design and beautiful lines not for their easy of use or technical features. cars are designed with very specific lines too which certainly don't follow efficiency or any other technical criteria. every single movie and magazine undergoes heavy composition and color modifications to optimize their visual attractiveness. at more individual level, we no longer upload a picture to our online photo albums without passing it through color filters in an attempt to make it look "cool". we as a society and as individuals, expect beauty everywhere, regardless of the quality of the object, subject, content or idea we are dealing with. a famous architect was putting it this way when talking about sustainability: the brutal truth to make sure an architectural piece is sustainable, in that it stays there for longs periods of time, is not to make it better solar powered or more heat efficient only - instead, the answer lays in making it beautiful, to be eye catching so it never gets aestehtically obsolete, that will ensure it stays there forever.

others forms of beauty are engagement and humor. of course no good speech can be expected to not start with a joke, then show strong passion and heart, and do explicit use of verbal repetition and reiteration of the key ideas in the speech. that, we probably could indeed call a beautiful speech.

so, coming back to the topic of teaching maths, my second idea for today is that the realizations of the importance of beauty in the format of whatever content you are dealing with regardless of its quality, probably should apply to teaching too. now, if these principles of beauty should be applied just as a direct and simple design issue in the material used for teaching, or if there are actually more profound ways to understand beauty in the teaching process is something i cannot foresee yet. what i do know is that a set of exercises in a blackboard or an online website are certainly not the sexiest way to present the otherwise beautiful ideas that math teachers aspire to teach.
minimal appearance, convoluted concept
2013-03-13
despite its visual simplicity, this image that i made the other day has lots of convoluted implications in its making,

basically, it's a twist to how computers do graphics - this is an image in an image, or an algorithm in an algorithm, or a paradigm in a paradigm, if you wish, sort of like the "a dream in a dream" in the Inception movie.

it's using the hardware (GPU) which runs some software (a shader) which re-implements what the hardware was doing in the first place (polygon rasterization). the implementation is not difficult at all, but the mere idea of this recursive planes of abstraction is worth a post.

cause, or symptom?
2013-03-11
people complain about mobiles phones and how, according to them, they actually and ironically don't connect people but isolate them. i was thinking that perhaps these people are right in their observations, but not in their conclusions.

seems kids these days pay more attention to their mobile phones in class than they do to their teachers ("damn mobiles", i hear grumpy teachers say). but not only kids exhibit this lack of attention ability. the image of a person, or two, or five looking down to their mobile phone's screen during a meeting is now common in any team meetings in the offices of companies all around the world. almost not surprisingly, as i have these thoughts right now while i prepare my breakfast and i look through the window to the street outside, i see these workers doing reparations in the street from which one is driving a carving/hammering machine and opening some holes in the pavement while the other two, which perhaps are there to supervise, are busy with their mobile phones.

now, instead of doing the conventional and demagogic judgemental assertion "mobiles are the problem", what if the mobiles were simply channelizing to the outside world the more embarrassing fact that, over all these years before we had mobile phones, people had been distracted and not "working" as we had expected without anybody noticing. perhaps it's just that we no longer pretend.

cause i don't see companies being less efficient than they were before due to the distracting mobiles, i don't think the works in the street outside my apartment would be executed quicker if those two guys weren't on their mobiles. the world keeps turning at the same speed i think. it's that we were not as busy as we though perhaps, and while before we were thinking on donuts and boobs while the boss speaks, now we check facebook or twitter (which also have donuts and boobs).

so perhaps it's US who are distracted by nature, and the phones are the symptom more than the cause?
his-tory, her-itage and my-ths
2013-03-09
not sure what tory, itage and ths are, but they belong to the three of us
mathimage #4. pickover
2013-03-07
This week was really busy and hard. I could only doodle a bit, not really engage into a complex mathematical image. Yet I think it turned out quite cute. I used some variation of the famous "popcorn" formulas, although to be honest any random combination of trigonometric functions would have done equally well. I put them under iteration and then massage the different properties of the resulting orbits till I got something visually interesting and pleasant (some people have indicated that it looks Dalinian). You can see it moving in realtime here: https://www.shadertoy.com/view/Mdl3RH, and change some of the formulas if you fancy (I recommend starting with lines 6 and 7). See you next week!


SUN francisco
2013-03-05
it's not often that the sun visits us here, but when it does, SUN Francisco gets really pretty. everywhere. but in particular i like it in the downtown area where the big buildings and life happens, the place in this "city" where i actually feel like using such word, and where at sun setting time the rays carom in complicated reflections and diffractions though the windows, corners and streets. it almost seems like the sky was trying to tickle the city before letting her go to sleep (for me a city, especially a pretty city, is always a "she").

as this city transitions into a town in my way home, heading west, i am lucky enough to have to climb two of the seven hills. lucky, because at sunset time, seven hills mean seven different sunsets that you can enjoy. lucky, and happy to reach the top of each of my two hills, get to meet the sun there for some magnificent views and extra tickles before arriving home.
who's "they"?
2013-03-03
to me, complains of the type "but they tell us how we should live our lives" are legitimate only to a certain degree. cause, boy, it's up to you to choose who deserves being listened to. as far as i'm concerned, nobody around me is telling me anything about how to live my life. i cannot hear them. furthermore, who's "they" anyway?
mathimage #3. catacombs
2013-03-01
My mathematical image of the week (number 3 in my one year challenge). A rework from an old piece from 5 years ago, plus lots of love and massaging for a whole long, long night. Planes, cylinders and cosinuses. Mission accomplished. Till next week!

You can see it moving and modify the code/formulas/image yourself here (you might want to change that first 1 in line 83 to a 0.0, then hit the black triangle below): https://www.shadertoy.com/view/lsf3zr