Carpetdiem, a digital odyssey that weaves together 555 generative carpet forms through the alchemy of ancient wisdom and contemporary algorithms. Unveiled on 23 March 2023, this tapestry of artistry unfurled itself to the world, and within the span of a single week, all pieces were claimed. What makes Carpetdiem resonate with its audience is its living, breathing essence. It’s a collection frozen in time yet ceaselessly evolving, captured in 555 unique NFTs that sing a song of both history and innovation. Under the creative orchestration of Mammadov, each algorithmic run births a new artwork, a seamless fusion of millennia-old patterns with the pulse of our automated age.

Yet, Carpetdiem transcends the boundaries of mere art and technology. It’s a bridge, meticulously engineered, that spans across time, connecting the past’s rich traditions with the future’s limitless potential. Through the digital loom of the blockchain, Mammadov has woven a magic carpet, inviting you to step onto it and journey through the echoes of a bygone era, a cultural memory reborn in pixels and code. This magic extends even further, bestowing upon its holders more than mere ownership; it grants them the intellectual property rights to their piece of art, opening doors to monetization and exploration. Carpetdiem becomes not just a piece of art but a symbol of empowerment, a nexus where creativity meets opportunity.

Inspired by the intricate craft of weaving, the vastness of savannahs and deserts, and the mystical cadence of mathematics, Carpetdiem offers an experience that transcends the visual. It’s an encounter with time, space, and existence, a harmonious dance that blends tactile memory with digital imagination.

In Carpetdiem, the whispers of ancient weavers find new voice, the elegance of mathematics finds new form, and the barren landscapes find new life. It’s an art form that thrives at the intersection of history, innovation, and beauty, a testament to human ingenuity, a celebration of culture, and a beacon guiding us toward a future where the past is never forgotten but continually reinvented. In the interwoven threads of Carpetdiem, we find a piece of ourselves, a reflection of our journey, and a glimpse into the infinite possibilities that lie ahead.


Artwork manifests the magic of mathematics, unveiling the mesmerizing spectacle of fractal geometry that unfolds in an infinity akin to blooming flowers. Carpetdiem captures the viewer, drawing them into an entrancing journey akin to a ride on a magic carpet, guided by ever-evolving designs. Indeed, unveiling the singular beauty inherent in mathematics forms the cornerstone of Mammadov’s craft. His work employs a recursive fractal system, derived from the Sierpiński carpet formula, which divides equilateral squares successively, while an algorithm generates a new pattern with each iteration, resulting in unique, autonomous designs.

This extraordinary collection of 555 unique carpet forms, digitally manifested as NFTs, transcends traditional boundaries by bridging the gap between the past and the future. Orkhan Mammadov, the visionary artist behind Carpetdiem, has skillfully fused thousands of years of history with cutting-edge technology, creating an immersive experience that allows us to walk through the memories of a long-lost culture.

At the heart of Carpetdiem lies the magic in mathematics, a universal language that permeates both the natural and constructed world. Mammadov’s exploration of mathematical sequences and algorithms reveals the inherent beauty and aesthetics that lie within these formulas. Inspired by the rich tradition of carpet weaving in Azerbaijan, where patterns hold deep meaning and spiritual significance, Mammadov masterfully translates these ancient designs into a contemporary digital code. Through his art, he embraces the intergenerational connection, celebrating the past while embracing the possibilities of the future.

The algorithm behind Carpetdiem draws inspiration from the Sierpiński Carpet formula, a mathematical construct that recursively subdivides equilateral squares, resulting in mesmerizing fractal patterns. However, Mammadov’s algorithm takes this concept a step further, directing the fractal propagation outwards instead of inwards. Each artwork consists of a combination of cells on a predefined grid, with the algorithm generating unique configurations at each run. The interaction between multiple fractals and their emergence from a single point creates intricate and enchanting patterns that captivate the viewer.

Carpetdiem encompasses four distinct elements: the field, the main border, and the outer and inner secondary borders. These components, with varying widths and densities, come together to form visually stunning compositions. Mammadov introduces an element of randomness through the placement of spawn positions, allowing for a multitude of possible outcomes. The artist’s meticulous attention to detail extends to the color and visibility of each cell, employing curated color palettes and toggling visibility parameters to create depth and complexity within the composition.

Exhibition brings Carpetdiem to life in a tangible and immersive manner. Three hand-made silk carpets, measuring 130 x 190 cm, serve as the centerpiece of the exhibition, showcasing the grandeur and intricacy of Mammadov’s generative art. Additionally, ten framed prints on silk, accompanied by three lenticular prints from the Carpetdiem Collection, further immerse the viewer in the mesmerizing world of fractal geometry. A creator edition screen and three small Arduino prototypes provide insights into the artistic process, revealing the underlying technology and code that bring Carpetdiem to existence.


The concept is more than a mere convergence of pixels and lines; it’s a symphonic fusion of art, culture, mathematics, and technology, a digital reincarnation of the timeless Azerbaijani carpet designs. These carpets, traditionally handwoven with love and precision by master craftsmen, become immortal in the digital realm, translated into the language of algorithms that captures their complex beauty through an elegant dance of fractals and recursion. Each execution of the code weaves a new pattern, a uniquely mesmerizing tapestry, echoing the human touch in a world of binary.

It transcends mere visual art; it manifests as an immutable piece of code, a digital artifact residing securely within the realms of the Ethereum blockchain and InterPlanetary File System (IPFS). This cryptographic haven grants owners the freedom to breathe life into the artwork directly from its digital loom, independent of external intervention. In this space, the blockchain becomes both a gallery and a vault, ensuring authoritative ownership while casting each artwork in a unique cryptographic silhouette or “hash,” an unbreakable seal of individuality.

Within the blockchain’s cryptographic maze, all the threads necessary to recreate the art are preserved, a digital genome encoded with the essence of Carpetdiem. Any seeker with the key—the provided hash—can unlock this treasure, retrieve the art script, and regenerate the artwork, a testament to authenticity and an homage to uniqueness.

Carpetdiem is not just an artform; it’s a philosophy, a digital poem woven from the threads of tradition, innovation, mathematics, and creativity. It’s a bridge between the tactile warmth of handwoven carpets and the cool logic of code, a celebration of the human spirit in a world mediated by screens, and a proof that even in the ever-changing landscape of technology, art endures, evolves, and continues to inspire. In Carpetdiem, the old and the new dance together, preserving the heritage of Azerbaijani carpets and reimagining it for a new era, an era where art is not confined to walls and floors but lives, breathes, and flourishes in the boundless digital cosmos.


The history of carpet weaving in Azerbaijan is closely linked with the history of the country itself with evidence of the craft dating back to the 2nd millennium BC. Influences of the various civilisations that have passed through Caucasia over the centuries can be seen in the evolution of carpet weaving, with Azerbaijani artisans refining and adapting techniques and styles from the Scythians, Sarmatians, and later, the Turks and Persians. Carpets were not only functional objects, providing warmth and comfort in homes, they also served as status symbols and gifts of diplomacy. Azerbaijani carpets were highly sought after by traders and collectors, contributing to the region’s economic development. Furthermore, the diverse landscape and cultural influences in Azerbaijan have given rise to a wide variety of regional carpet styles, each with its own distinctive characteristics. Some of the most well-known Azerbaijani carpet-making regions include Quba, Shirvan, Baku, Ganja, Gazakh, and Karabakh. Each region is known for its unique weaving techniques, colour palettes, and design motifs, which often reflect the local environment, customs, and history. 

Perhaps due to the tradition being passed down over several centuries, the region’s weavers - usually female - are highly skilled artisans who have mastered the art of symmetric and asymmetric hand-knotting, to create their intricate designs. The choice of materials, including natural dyes and fibres, and the qualities of the material such the elasticity of wool or the sheen of silk, significantly impacts the texture, durability, and appearance of the carpets. These women often work collaboratively in small groups or within family units, with each member contributing their expertise to the creation of a carpet. This collaborative process fosters a sense of community and shared identity. Carpets also play a significant role in various Azerbaijani rituals and traditions. They are often used during weddings and funerals, and are passed down through generations as family heirlooms. The presence of carpets in these ceremonies signifies the importance of continuity, heritage, and connection to the past. In 2010, UNESCO recognized Azerbaijani carpet weaving as part of the Intangible Cultural Heritage of Humanity.

Many contemporary artists and designers have been inspired by the visual language of Azerbaijani carpets, incorporating their motifs and techniques into various mediums such as painting, sculpture, and textiles. In recent years, efforts have been made to preserve and promote the rich heritage of Azerbaijani carpet weaving. The establishment of the Azerbaijan Carpet Museum in Baku, the inclusion of Azerbaijani carpet weaving in UNESCO’s Intangible Cultural Heritage list, and the organisation of various exhibitions and workshops all contribute to the continued vitality and recognition of this ancient craft. Several institutions and organisations such as Heydar Aliyev Foundation, Carpet Museum and Azercarpets in Azerbaijan are dedicated to the preservation, research, and promotion of Azerbaijani carpets. These entities provide resources, education, and support to carpet weavers, ensuring that the craft continues to thrive in the modern era.


The algorithm behind Carpetdiem is an artistic philosophy, a bridge between the worlds of geometry and creativity. Its genesis is inspired by the Sierpiński Carpet, a mathematical siren that calls forth the infinite by recursively subdividing equilateral squares into themselves. Yet, the Carpetdiem algorithm dances to its own rhythm, evolving the fractal expansion to radiate outward like the petals of a blossoming flower, rather than inward.

At its heart, each artwork is a symphony composed from a single, foundational unit known as the ‘cell.’ The Carpetdiem designs are like intricate orchestrations of these cells, arranged within a predetermined grid, each playing a part in the grand performance. A cell is a thing of simplicity and beauty, with basic attributes such as its position, visibility state, and color. Yet, from this simplicity springs complexity. Each fractal melody begins with a lone cell, a solitary note. As it is rendered, the algorithm, like a master composer, surveys the surrounding grid, inviting new cells into existence if the positions are unoccupied. This outward recursion is a creative explosion, opening doors to a universe of possibilities. It’s a dance where multiple fractals can spontaneously waltz across the canvas, each sprouting at random locations, each unique, yet part of the whole.

The artistry deepens when these fractals begin to see each other, to feel each other’s presence. As they intertwine, their boundaries kissing and merging, elaborate patterns emerge like poetic verses. The designated areas for propagation draw aesthetic parallels to the rich structure of Middle Eastern carpets, with their intricate borders and central fields.

The final brushstroke of the algorithm is emergence, the magic of growth from a single, humble point. It’s a visual journey captured in the code’s execution, where each stage of fractal propagation is like a 240-frame animation, a ballet that unfolds with each pulse of the code.

Carpetdiem’s algorithm is not a cold mathematical function; it’s a living manifesto of art and mathematics, a celebration of complexity and simplicity, form and chaos. It’s an ode to the beauty of fractals, a visual sonnet that captures the very essence of generative art. In its code, in its cells, in its recursive dance, it tells a story—a story that is as timeless as geometry itself, as infinite as the fractals it crafts, and as profound as the carpets that have adorned human civilization through the ages.


Within the realm of Carpetdiem, structure is the skeletal framework that gives form to the dreams woven into each carpet. The architecture, like the notes of a timeless symphony, consists of four essential elements—the field, the main border, and the supplementary inner and outer borders. Each plays a vital role, a unique voice in the chorus, crafting patterns that mesmerize and transcend the fabric’s plane.

The borders are the gatekeepers of design, versatile and adaptable, able to whisper thin lines barely perceptible to the naked eye or to shout with thick bands that boldly delineate the carpet’s form. This variability in border widths is akin to an artist’s stroke, introducing a complexity and uniqueness that ensures each carpet is a world unto itself, a distinct fingerprint in the vast universe of design.

Nestled within these borders, the central field emerges as the expansive canvas of creation. It’s here, in this unbounded space, that the fractal magic breathes and dances, unfurling like a flower in perpetual bloom. As the borders shift and waver, the field’s relative size responds, creating an ever-changing landscape of intricate patterns, a dynamic play of light and shadow, form and void.

Yet, Carpetdiem is not content to merely follow tradition; it flirts with the unexpected. Some renditions dare to eliminate the inner secondary border, a bold disruption that births a new visual experience, a design that sings its unique aesthetic song. It’s a risk, a gamble, and a beautiful defiance of convention that adds a thrilling edge to the collection.

The interplay of these components, their variations, and their potential for unexpected transformations is not just structure; it’s the very soul of the Carpetdiem exhibition. Each artwork becomes a spectacle, a distinct celebration of mathematical beauty and artistic innovation, a dance of form and formlessness that invites the observer into a world where the carpet is not just a decorative object but a living, breathing entity, an art that whispers secrets of geometry and sings songs of boundless creativity.


Within the kaleidoscopic landscape of Carpetdiem, the spawn points become the seeds of creation, the embryonic origins from which the fractals burst forth. They are the unsung heroes of the design, placed strategically in the central field and the primary border, where they claim the most substantial portion of the visual story. The mechanism of spawning is both an art and a science, painting a diverse range of potential patterns and weaving a tapestry as intricate as it is mesmerizing.

In the field’s context, the spawning concept dances to a simple rhythm. The pattern’s density waltzes with the number of spawn points; the more points, the more intricate the dance becomes. Each point’s location is like a note played by an improvisational jazz musician, randomized and free, leading to endless variations, rhapsodies of designs that enhance the collection’s diversity.

The main border, on the other hand, plays a more complex, nuanced symphony. It is here that tradition meets innovation. The corners’ spawn points are fixed, like sentinels preserving the integrity and distinct detailing reminiscent of the art’s traditional roots. Yet, between these corners, the spawn points reside in a linear continuum, dancing to a density parameter that adds new variability layers.

These border spawn points are also artists with a flair for drama, endowed with an offset attribute that allows them to flirt with the outer edge or embrace the central field. This interplay can drastically alter the visual outcome, creating waves of visual sensation that crash against the shores of perception.

Lastly, the main border is graced with a uniformity parameter, a subtle maestro controlling the degree of orderliness or randomness in the pattern. Like the disciplined strokes of a calligrapher or the wild brush of an expressionist, this parameter adds yet another dimension, infusing the art piece with a complexity that resonates with both mind and soul.

In Carpetdiem, spawn points are not mere technical attributes; they are the whispers of creativity, the echoes of tradition, the laughter of randomness, and the heartbeat of complexity. They are the composers of a visual symphony that plays in the hidden recesses of algorithms, and in their interplay, the art comes alive, a celebration of both the new and the timeless.


Propagation is the heart’s pulse, the rhythmic beat that guides the growth and complexity of the fractal’s soul. Stemming from the fractal nature of the foundational algorithm, propagation duration acts as a masterful conductor, orchestrating the expansion’s tempo and character.

The time span over which the fractal is permitted to unfold is not a uniform monotone but can be delicately randomized for each individual creation. This parameter acts like the deft fingers of a sculptor, chiseling the intricate complexity of the resulting patterns. The longer the propagation, the greater the dance of design grows in density, and the higher the likelihood of fractals intertwining with one another. This courtship culminates in designs that are both elaborate and beautifully intricate.

However, the true artistry in Carpetdiem’s propagation lies in its ability to differentiate between sections. Imagine a canvas where the border pulses with a high propagation value, weaving a tapestry dense with patterned complexity, while the field resonates at a lower value, painting a picture that’s elegant and sparse. Or vice versa, where the roles are reversed, and the field becomes a labyrinth of detail, and the border a gentle whisper of simplicity. This differential propagation is like a symphony with varying movements, each playing its own melody, yet in harmony. It multiplies the potential diversity of outcomes, transforming each piece of artwork into a universe of visual sensation.

In Carpetdiem, propagation is not merely a parameter; it’s the rhythm of growth, the breath of life in mathematical form, a dance of patterns that crafts the poetry of design. It is a journey into the heart of complexity, a reflection of nature’s elegance, and a celebration of the infinite possibilities within the realm of generative art.


Within the very fabric of each creation, cells emerge as the fundamental building blocks of the artwork. In the world of Carpetdiem, color is not merely a superficial attribute; it is the soul that animates these cellular structures. The algorithm, acting as the artist’s brush, selects from a meticulously curated set of 22 color palettes, each containing hues that resonate with the overarching theme of the collection.

As the fractal evolves, so does the color. With every expansion, a new shade is unveiled, and the artwork grows richer in tone and complexity. This synergy between fractal progression and color application is akin to a blossoming flower, with each petal revealing a new facet of beauty.

The Fractal Color Palette, an orchestration of shades and tints, ranges from the ancient resonance of Tyrian Purple, dark and enigmatic, to the earthen robustness of Wood Bark.

These are further grouped into color families that evoke distinct moods and energies:

Mixed Group: A fusion of shades (247)

Brown Group: Earthy tones (84)

Green Group: Life and renewal (67)

Red Group: Passion and energy (65)

Blue Group: Tranquility and depth (49)

Gold Group: Opulence and light (26)

Silver Group: Purity and clarity (9)

Sunset Group: Transitions and warmth (8)

In Carpetdiem, colors are not mere pigments; they are characters that dance across the canvas, partake in the narrative, and breathe life into the algorithms. They reflect the invisible rhythm of the mathematical patterns, and in their interplay, the artwork sings its visual song.


Visibility in the context of Carpetdiem is not merely a technical parameter; it is a tool of artistic expression that governs the very essence of what is seen and unseen. Within the algorithm’s depths, the cells are processed, analyzed, and assigned roles in a grand performance. However, not all are destined to take center stage on the canvas.

The visibility parameter controls the degree of revelation, akin to a maestro controlling the dynamics of a symphony. It introduces a layer of complexity that transcends mere form, generating undulating variations in contrast and sophistication. Every cell’s appearance or disappearance on the canvas is a deliberate choice, a decision that shapes the composition’s soul.

This unique approach is not static but dynamic, evolving with every fractal expansion. Like an unfolding story, the visibility parameter is applied with rhythm and precision, ranging from full visibility—where every cell in the fractal becomes a visible actor—to sparse visibility, where only a select few expansions are revealed, akin to whispered secrets.

In the sparse interplay, certain cells become the focal points, like stars in a night sky, while others recede into the background. This selective visibility creates intricate patterns, shadows, and silhouettes, composing a narrative that speaks through absence as much as presence.

In Carpetdiem, visibility is a dance of light and shadow, a nuanced choreography that illuminates some parts while veiling others, crafting an artistic journey that resonates with the beholder’s eye and imagination. It is not just a parameter; it’s a poetic expression of the unseen beauty within the algorithms, a story told through the interplay of revelation and concealment.

Programming Language

This project represents the culmination of several years of meticulous research and dedicated work. The code is based on the p5.js JavaScript library, a free and open-source tool that is part of the Processing Foundation. This foundation allows the artwork to exist solely on the web, eliminating the need for any additional frameworks, while also maintaining a remarkably lightweight footprint (the entire codebase accounts for only a few kilobytes). 

P5.js is a versatile JavaScript library explicitly created to facilitate the production of interactive graphics and visual content on the web platform. Based on the principles of Processing a programming language tailored for the digital arts—p5.js aims to make the programming and coding environment more accessible and inclusive, particularly for artists, educators, designers, and novices.

This library is recognized for its intuitiveness and ease of use, with functionalities that simplify tasks like graphics creation, handling input from devices (like the mouse and keyboard), manipulation of the Document Object Model (DOM), as well as working with audio and video files. By lowering the barriers to entry, p5.js encourages creative coding and computational thinking, thus playing an instrumental role in democratizing digital creativity and interactive web content creation.

This project owes its fruition to the tremendous support of the generative art community, which stands as one of the most inclusive and supportive online communities to date. It is my hope that the dedication, love, and care invested in bringing this project to life shine through each and every piece. 

Research & Execution:
OMA Lab - Orkhan Media Art Lab. 2021-2023