Beauty is at the border between boredom and confusion. Think of hearing music. If the music is very simple, like just one or two notes repeating in a fixed pattern, it is boring. If it is extremely complex, you get confused and it is perceived as noise. In the middle between the two is the “beauty zone”. Things in this area are not boring, because new, surprising things are happening all the time. They are also not confusing because the rate at which something new is happening or is being discovered is not too high. So the new information can be integrated into the pre-existing knowledge successfully.
So the feeling of beauty, I think, is an emotion of success of perception that arises if the knowledge we use in perceiving things (like, for example, the knowledge of a music style that we have already) is successfully extended to assimilate, i.e. to cover or include the new information. This extension is a creative process producing new or modified knowledge.
The experience of beauty is, as a result, subjectively different because each of us has different knowledge, depending on previous experiences, and it also depends on the culture that shapes these experiences. However, by exposing oneself to experiencing structures of a certain kind (a style of music or painting, for example) one can learn to appreciate things as beautiful that are confusing or boring initially because the structures contained in them can only be perceived once some knowledge of the “grammar” underlying the respective style is acquired.
If this hypothesis about the nature of the phenomenon of beauty is true, the most beautiful structures, both in music and in visual art, should have a mixture of regularity (to avoid confusion) and irregularity (to avoid boredom), producing a medium rate of novelty when we experience them.
The most beautiful structures are so rich that they remain interesting over a longer time since we discover new things all the time. Quality (in a formal or structural sense) could then be defined as this ability of an object to remain beautiful over an extended time. The things that have the highest quality become more interesting when we get to know them better, and remain interesting. As we discover structures in them, we also discover new things that we did not perceive before. Low-quality-objects, on the other hand, quickly become boring because after a short time, we have discovered all the structure that is there.
The purpose of beauty is to organize our perceptional learning processes. In this respect, it can be seen as a cognitive emotion. It is not irrational but part of the infrastructure of our rationality, steering our perceptual (as well as intellectual) learning processes along a path on which we can progress and grow.
This concept of beauty applies to art and artifacts as well as to things from nature. Since we are able to make things or processes that can be perceived by ourselves, we are able to create things artificially which dwell in the beauty zone at the border between boredom and confusion. This possibility is one of the roots of art. I am not saying here that all art is or has to be beautiful or that beauty defines art, but I think that creating beautiful things is a legitimate goal for the artist.
(The picture is from http://commons.wikimedia.org/wiki/File:Lichen_on_Nunavut_rocks.jpg) I find it beautiful, but this is a matter of taste :-).
https://asifoscope.org/2012/11/25/393/ ( a first sketch of the same ideas)