Bits & Pieces

In Bits & Pieces, I share some brief insights, sparks of creativity and interesting lessons that may or may not constitute further, more elaborate work. Below you can read the most recent ones!

Sleep and knowledge work

A typical sleep cycle lasts about 90 minutes and includes both non-REM (light and deep) and REM stages. In the first half of the night, deep sleep dominates, which is important for physical recovery. REM sleep becomes more prominent in the latter half of the night, especially in the early morning hours. The longer someone sleeps, the greater the proportion of REM sleep in the later cycles.

REM-sleep is important for learning, memory consolidation, creativity, and emotional regulation—crucial elements for peak-performance in knowledge work.

While both sleep phases are important for everyone, it appears that knowledge workers are at a biological disadvantage here. Since REM is “second-in-line,” individuals who cut their sleep short (e.g., less than 6 hours) sacrifice a disproportionate amount of REM sleep.

Physical workers may derive most of their immediate benefits from deep sleep, which occurs earlier in the night. If their total sleep is slightly reduced, they might still receive adequate deep sleep for muscle recovery and immune function.

Knowledge workers may experience more noticeable cognitive deficits from insufficient sleep compared to physical workers, as REM deprivation directly impairs focus, problem-solving, and creativity.

So, when looking at (ways to improve) our sleep, its perhaps wise to be a bit more specific on the type of sleep we require most.

Feeling-awareness

In Buddhism, vedana constitutes the ‘texture of life’ and refers to the directly experienced sensations (rather than the emotions that we create from them). Mindfulness of vedana means to become more alive to the texture of experience.

Vedana is unavoidable, non-negotiable: it happens to us. What can be changed is how we respond to vedana. We can suppress or resist it (and create unpleasant emotions as a consequence), or we can consciously investigate it; explore it. 

This is true for pleasant sensations as well. Although we spend time and money on things we find pleasurable, when we get it, we often forget to pay attention beyond the initial moment. Kids are much better at this: while we lose our attention after one or two instances, kids seem to get joy almost endlessly from the same silly face, ride down the slide, or leap into the air.

We need to regain this child-like curiosity; to experience every moment as if we don’t know what will happen next. We need to re-learn to cultivate the discipline of delight. Since our habitual thinking is that pleasurable things are counter-productive, this is harder than you may think.

The discipline of delight

We are distracted from experiencing pleasure be wanting more of it, just like how experiencing negative vedana makes us want it to stop. This ‘wanting’ more (or less) is what takes our mind away from what we are actually experiencing. We often associate wanting with pleasure, but when we become more aware of this feeling, this vedana, we will soon discover how unpleasant it actually is. Excitement is painfully similar to anxiety: it has the same physical tightness, restlessness and agitation.

Vedana is experienced within a ‘life context’ of association, expectation, and memory. This life context shapes how we react to vedana. The key is learning to stop confusing our reactions to experience with the experience itself.

The same holds true for so-called neutral vedana, which constitutes the lion’s share of our day-to-day experience. Our habitual response to neutral vedana is to want pleasure instead. We may refer to neutral vedana as ‘boredom,’ and it has been easier than ever for us to escape it. 📺

The reason so much of our life can feel bland is not because a lack of experience. After all, experience is present all the time! It is the lack of awareness of experience that makes moments pass unnoticed.

To enjoy life, to experience it, we need to create a discernible gap between our experiences and what we do with them; how we react. That’s what we’ll set out to do in this third week’s practice of life with full attention.

Cultivating vedana-awareness

Creating a gap between vedana and reaction required breaking habitual patterns. Naturally, this week’s practice involves quite a number of tools to help us do so.

The first thing comprises a vedana-diary. This will promote a habit of catching vedana before responding to them. Furthermore, writing down all vedana keeps us out of the downward, apathic spiral that draws our focus exclusively to the unpleasantness of experience. 📔

In its most basic form, the vedana-journal contains just that: positive and negative vedana, one page for each. Alternatively, you can make a table with five columns, which you can fill in for every vedana that appears:

  1. What was the experience?
  2. Was I aware of the pleasant feeling while it was happening?
  3. How did my body feel, in detail, during this experience?
  4. What moods, feelings and thoughts accompanied this event?
  5. What thoughts are in my mind now that I write this down?

You can also use the diary to catch your habitual reaction proactively. What vedana are you expecting to experience in a particular situation? What is it exactly that gives you the feeling of pleasure or displeasure? Having written about them makes it more likely that you will be more aware when it happens.

When the event has passed, you can compare the pro-active and reflexive diary entries. Do they match? What can be learned from it?

In addition, we may pay particular attention to vedana during our daily mindfulness walk. Try to become more aware about what it is that you experience: is it a feeling or is it your reaction to it? In that context, become aware of your surroundings and your (non-)judgement about it: what is the plain experience and what is actually your response? Try to pay sustained attention to pleasurable sensations when they occur, but only to the sensation, not the wanting for more.

When you are starting to be overwhelmed; when you feel you are being reactive, we should develop the habit of creating our personal breathing space. A space whose settign up has the following steps:

  1. Stop whatever it is that you are doing, and if possible, find a quiet place to settle down.
  2. Gently scan through your body: what do you feel?
  3. Become aware of the sounds that surround you.
  4. Tune into your breath and follow it while it goes in and out.
  5. Carry this awareness forward in whatever you were doing before.

This is also the week we will start practicing meditation. Meditation is simply and only setting aside a period of time to cultivate awareness. It is here that we feel most clearly the distinction between reaction and vedana, particularly those with a ‘neutral’ nature. 🧘

We try to feel our body rather than to think about it; we substitute words for experience by experience itself. We can move through our entire body like this. There are always things to feel, even the absence of feelings is in facta feeling in itself.

Its best to have a fixed moment in your routine where you meditate, say for 15–20 minutes. Start the meditation with a clear promise to yourself to explore the sensations in your body with pure and open awareness. Similarly, when you are done, take a moment to recognise how you feel. Try not to jump right into your other commitments for the day.

To increase your awareness of the (fruits of) your meditation practice, it is a good habit to write down a sentence or two about how your meditation went, in other words to keep a mediation diary.

If you find it useful to have some pointers for your practice (i.e. things to focus on) you can follow the schedule provided in the book:

  • Day 1: become aware of sensations in your body, starting from the soles of your feet to the crown of your head.
  • Day 2: the same as day one, but now with a gentle, benevolant attitude. Do you notice any differences with yesterday’s session?
  • Day 3: see if you can uncover any habitual tensions, particularly in your back, neck and shoulders. Can you relax into them?
  • Day 4: take the same body scan approach but see if you can uncover which sensations are interpreted as pleasant, unpleasant or neutral.
  • Day 5: the same as day 4 but now try to stay with your pleasantly experienced sensations for a while.
  • Day 6: the same as day 5 but now with unpleasant sensations. Alternate with a pleasant sensation when you’ve been with an unpleasant one for a while.
  • Day 7: Expand the awareness of your body with the awareness of emerging sounds.

Third practice week

In addition to my preexisting mindfulness walk and meditation, I’ve integrated this week’s practice into my present routines as follows:

Vedana diary

To cultivate sensation-awareness throughout the day, I will add the following principle to my momentum cycle:

Whenever I experience a particularly pleasant or unpleasant sensation, I pause for a moment to neutrally observe the sensation, after which I write down (1) the sensation, (2) where and how I feel it and (3) what the sensation might try to tell me, so that I become more aware of the sensations in my body and experience life more freely.

As such, I deviate a bit from the book’s prompts, which to me personally seem like a lot of work, rather mechanical, and not so useful per se.

I feel like with this principle, I integrate the most essential parts of the vedana diary and the breathing space. I do not think I will manage to do both of them separately.

Influence is Immoral

Below I share a passage that made a strong impression on me from the book The Picture of Dorian Grey by Oscar Wilde. It’s at the beginning of the book, when Lord Henry explains to Dorian Grey why ‘all influence is immoral.’

Because to influence a person is to give him one’s own soul. He does not think his natural thoughts, or burn with his natural passions. His virtues are not real to him. His sins, if there are such things as sins, are borrowed. He becomes an echo of some one else’s music, an actor of a part that has not been written for him. The aim of life is self-development. To realize one’s nature perfectly—that is what each of us is here for.

(page 17)

The idea that we should help everyone to ‘realise their nature perfectly,’ rather than enforce upon them our convictions, is an original one, and one I think we desperately need.

The rational arguments and moral incentives do not seem to make anyone change their behaviour, no matter how clear or obvious they are—and no matter how hard we shout them. I think helping people to recognise their meaning is the most effective strategy to pursue, as captured beautifully in the words of Lord Henry once again:

I believe that if one man were to live out his life fully and completely, were to give form to every feeling, expression to every thought, reality to every dream—I believe that the world would gain such a fresh impulse of joy that we would forget all the maladies of mediaevalism, and return to the Hellenic ideal1— to something finer, richer than the Hellenic ideal, it may be.

(page 17-18)

Footnotes

  1. ancient Greek emphasis on balance, harmony, and excellence in mind, body, and spirit, striving for perfection in life and culture.

Awareness of the Body: Reflection

It’s been almost two weeks since I started on the second phase for the course in Maitreyabandhu’s book. This post is a quick reflection on my progress during this phase. What to read more about this phase’s focus (awareness of the body) you can go to my previous post.

In addition to the first week’s commitments for routines, this second phase introduced three new elements into the course: the health audit, body scan, and mindfulness walk.

Health audit

Since I found a nice way to integrate the health audit into my daily to-do list workflow, I maintained a pretty consistent diary of my physical health habits: sleep, being outside, exercise, eating, and drinking (only missing 1 out of 11 entries). Each of them I scored on a 5-point scale as explained in my previous post.

Without going into too much detail, I was quite happy with how I scored on being outside (4) and exercise (3.6), whereas I was surprised how poor I performed on my eating and drinking habits (2.9, and 3.2 respectively). In the upcoming phase, I want to keep maintaining this diary and see if I can get those last two above 3.5. 💪

Being more mindful of my health-habits is a nice addition to my daily workflow. I feel like it makes it easier to understand why I feel a certain way (grumpy, sleepy, etc.) and accept that that’s a consequence of my (lack of) actions. Furthermore, while I always assumed my eating/drinking habits were quite good, this reflection in the end tells me there is still quite some room for improvement.

Mindfulness walking

This didn’t go so well. I found like I had surprisingly little time to go for a walk, and often decided to substitute the ‘mindful walking’ for ‘mindful cycling.’ While that’s better than nothing, I feel like cycling allows for much less ‘deep’ awareness. Because you are participating in traffic quite intensely, you need to keep significant mental bandwidth available for that. Also, the weather being very autumn-ish also didn’t help. 🌧️

For the next phase, I want to set a minimum of 3 mindful walks per week, so that there are at least some deliberate moments to practice. Furthermore, when the weather is rainy, I can (at least in the office) take a mindful walk down-and-up the stairs.

Body scan

I really liked the idea of doing a body scan whenever I get home. However, doing so didn’t prove to be so easy, and often I simply forgot about it since there are so many things that draw my attention as soon as I step through the door (I worked a bit more on the house this weekend, so hopefully this will be less from now).

To make sure I do at least one body scan per day, I will combine it with my 10-minute morning meditation. This is not a substitute for doing a body scan when I get home—that’s still on the table, too.

Overall, I liked the beginning of this phase as I really felt more in contact with my body. Besides, the health audit has given me some clarity on my (apparently not so amiable) foundations for physical health.

However, over the course of the 11 days since I started, I feel like my body awareness, and maybe awareness overall, has faded into the background a bit. By making some more deliberate commitments and combining the body scan with something I already do, I hope I can reverse this trend. 📉

Why barefoot running is amazing for trails

I’ve been running on barefoot shoes for well over a year now, and today I wanted to share a little insight that I got during a trail run I did a few months back.

For most of the race, I was running at about the same pace as the people around me. However, on the way down, I was doing twice the speed wondering why everyone else was holding back. That’s when I realised the secret was in the shoes.

You see, virtually every running shoe you can buy is built for heel-stride running. Meaning that you land on your heel, ‘role’ over the arch of your foot, and then press forward from the toes. These shoes need heavy cushioning, because the entire shock from landing on your heel is transferred to your knee joints, hip joints, and up.

Barefoot shoes, on the other hand, demand that you transition to a ‘forefoot-stride.’ Where you land on the front of your foot, let your heels come down while the arch in your foot takes up the pressure, and then redirect that energy to your forefoot as you push off.

On flat pavement, you can perform just as well with either stride. (I’d argue that the forefoot-stride is better but that’s a discussion for another time.) But, as I mentioned, for trail running, the fore-foot stride comes out on top. But why?

I think there are two main reasons:

Excess forward momentum

With forefoot running, you put your feet closer under your centre of gravity than for heel-stride running. This means that in the former case, you are leaning—almost falling—downward, whereas with the heel stride you are leaning back.

All that potential energy you created by walking up doesn’t really get the space to be converted in forward momentum going down.

Joint pressure limit

As I mentioned before, heel-stride running can be quite demanding on your joints, hence the heavy cushioning in common running shoes. When you are going down, this pressure is greatly amplified, because each step down you go down for longer, causing your downward speed to accelerate and the blow on your heels to increase.

This is why most runners take smaller steps and hold back going down: simply ‘letting go’ would completely mess up their knees, hips and back.

While I think this makes a strong case for barefoot shoes, I hope it is clear that this isn’t about shoes at all. It is about the stride with which you run, and barefoot shoes simply demand that you adopt a forefoot stride. You can run heel-stride with barefoot shoes, your joints just won’t last very long. Similarly, you can run forefoot with common running shoes, but the latter are designed to be ‘rolled over,’ making forefoot running probably feel a little awkward at best.

LaTeX equations in Elementor WordPress

The Elementor website builder is a nice way to quickly create a good-looking website. However, by using Elementor, you lose some of the basic WordPress functionalities.

One of these functionalities I ran into yesterday was my inability to incorporate LaTeX equations, despite having installed the appropriate plugin. 

The solution is really simple, but since I couldn’t find it anywhere, I thought it’d be nice to share a quick overview below. So, here’s my ‘how to get LaTeX equations on my Elementor website.’

Step 1: install the WP QuickLaTeX plugin

You can either do so by downloading the ZIP-file from the official site and uploading it to the plugins section on your WordPress dashboard (plugins > add new plugin > upload plugin), or by installing directly from the browser (plugins > add new plugin > search for “WP QuickLaTeX).

Then activate the plugin to get it running (you can do this under plugins > installed plugins).

Step 2: add a ‘shortcode’ block to the beginning of your post or page

After starting a new post or page drag a ‘shortcode’-block from the builder to the top of your page.

Within the ‘shortcode’-block, change the content of the block to ‘latexpage’ between square-brackets, such as below:

Step 3: add a WordPress text block to your page

Now this is the step I overlooked to the point of frustration. To insert a LaTeX equation in your text, you cannot use the Elementor text block. Rather, you will need to use the WordPress textblaock, which you can find under the ‘WordPress’ tab in the builder widget section.

If you search for ‘text’ in the widgets, this block does not show!

Step 4: Add LaTeX equation to your page

In the WordPress text block, you can now write your equations in the WordPress text block, using the syntax provided in the plugin documentation. The most straightforward are the following options, illustrated in the example below. These include inline, between lines, or between lines with labels. The labels can be referenced later in the text.

Becomes (in a WordPress text block):

At first, we sample f(x) in the N (N is odd) equidistant points around x^*:

    \[ f_k = f(x_k),\: x_k = x^*+kh,\: k=-\frac{N-1}{2},\dots,\frac{N-1}{2} \]


where h is some step.
Then we interpolate points \{(x_k,f_k)\} by polynomial

(1)   \begin{equation*}  P_{N-1}(x)=\sum_{j=0}^{N-1}{a_jx^j} \end{equation*}

That’s it! Keep in mind that the equations only show when you view (save draft > view page) or publish the page. In the editor, it will always look like unformatted code.

Price formation in agent-based financial markets

In a previous article, I described a very simple agent-based market model. Today, I will revisit the simplistic mechanism for finding the market price by introducing the logic of a price function.

In the original model, the price of an asset is determined by solving all the orders of the orderbook. This means that when the highest bid is higher than the lowest ask—someone offers as much or more than someone else wants for it—a transaction occurs. This process repeats itself until no transaction can occur. The price is then set to the lowest ask: the lowest price for which someone would be willing to sell the asset.

This model simulates a peer-to-peer market. However, most markets (e.g. stock markets) function differently.

Introducing the market maker

The main difference is the introduction of a ‘market maker,’ who buys and sells the assets from investors. This has a number of benefits:

  • A market maker is always ready to buy or sell an asset. This makes it easier for traders to quickly find someone to trade with. The market moves faster and feels more active.

  • Without a market maker, the gap between what buyers want to pay (bid price) and what sellers want to sell for (ask price) can be large. Market makers narrow this gap, making it cheaper and easier to trade.

  • Market makers often help reduce big price jumps or drops by continuously buying and selling, which keeps prices more stable.

So how does it work?

In its most simple form, we can perceive how two types of agents are trading on a market: the investor and the market maker. The investor places an order, which is always filled by the market maker. However, the price at which the orders are filled is determined by the market maker.

The market maker has to balance supply and demand in order to achieve the benefits listed before. So, when there are more bids than asks (more demand than supply), the fill price goes up. Conversely, when the supply is higher, the fill price goes down.

The exact fill price is determined by a so-called market impact function. In this function, the market maker has to balance several things: inventory balance, market volatility, order flow information, competitive pressures, transaction costs and regulatory constraints. So, to manage risk, remain profitable, and stay competitive, he or she may apply a wide range of strategies—a wide variety of (exceedingly complex) market impact functions.

A simple price impact function

Below I show a very basic price impact function as presented in a paper by J. Doyne Farmer2 over two decades ago.

    \[ P_{t+1} = P_{t} * e^{\frac{\omega}{\lambda}} \]

Here, P_{t+1} is the new price and P_{t} the old price. \omega is the net order, so the number of bids minus the number of asks. \lambda Is a scale factor that normalises the order size: the order size that will cause the price to change by a factor of e. In the paper the latter is also called the ‘liquidity.’

Let’s see what that all means using an example.

Let’s say there are 20 agents (investors) in a market, all trying to buy and sell one unit of an asset A, with a starting price of €10.

If, given that price, 10 agents want to buy, and 10 agents want to sell the asset, there is no need to change the price. Indeed, when this is the case, the net order equals 0, and since e^0 equals 1, the new price is equal to the old price.

Let’s now say there is a mismatch in the market: 11 investors want to buy the asset, and 9 investors want to sell—demand is higher than supply. In this case, we expect the fill price to increase slightly. Let’s calculate this with \lambda equals 5:

    \[ P_{t+1} = 10 * e^{\frac{11-9}{5}} \]

    \[ P_{t+1} = 10 * 1.492 = 14.92 \]

This appears to be a significant price increase (49%) for a relatively small mismatch between supply and demand. In this case, we can say that the market maker is oversensitive to the demand function. Price stability will be hard to maintain.

However, we can change the value of \lambda to reduce this effect. Again, \lambda is the order size that will cause the price to change by a factor of e. Let’s assume that the total number of issued shares is equal to 10,000. We could conceive a rule that a factor e price change is appropriate when the mismatch in supply and demand is equal to 1% of the total shares (i.e. 100).

When we take this as a rule of thumb, the result is different:

    \[ P_{t+1} = 10 * e^{\frac{11-9}{100}} \]

    \[ P_{t+1} = 10 * 1.02 = 10.20 \]

And when supply exceeds the demand:

    \[ P_{t+1} = 10 * e^{\frac{9-11}{100}} \]

    \[ P_{t+1} = 10 * 0.98 = 9.80 \]

Note that the function is exponential, so that the price effect is amplified exponentially for growing imbalances in the market.

When we put the above example in a model, and we let the 20 agents put randomly a buy (50% chance) or sell (50% change) order over a timespan of 100 cycles. We get the following price movement:

The price appears to move in a random walk, which makes sense since the net order flow (supply and demand) is also based on a random function.

More interesting is the situation for the market maker, because it is important that he or she can maintain a sustainable position:

While it may look a little complicated, the graph makes perfect sense: when inventory (orange bars, right axis) of the market maker goes down, he or she has sold off assets. Hence, its capital (blue line, left axis) should go up. When inventory goes up, the effect is reversed.

It seems that with this very basic price impact function, we can easily simulate a more realistic agent-based market model.

Footnotes

  1. Farmer, J. D. (2000). Market force, ecology, and evolution. 66.

Are we witnessing the world’s greatest financial bubble?

Today I came across an interesting article by Ruchir Sharma in the Financial Times. In the article, aptly named ‘The mother of all bubbles,’ Ruchir describes the absurdity of investors’ gluttonousness for US stocks.

The image of America as an exceptional nation leading the world has long forgone. The article reads how “in political, diplomatic and military circles, the talk is [more] of a dysfunctional superpower, isolationist abroad and polarised at home.” An impression that was further reinforced by the presidential elections last month.

Yet, the faith in the financial markets appears to be unaffected. On the contrary, November has shown the strongest relative outperformance of the US market compared to the rest of the world. Even when correcting for the domination of Big Tech, the rest of the world was outperformed by more than four to one since 2009.

While there is some rationality to this premium, the US financial market share (70%) is completely disconnected from its share in the real economy (27%). As such, it is not surprising to read Sharma conclude that “America is over-owned, overvalued and overhyped to a degree never seen before.”

While these fundamental figures might alarm and spur any ‘rational investor’ into action, the financial world is known for disregarding anything that may suggest that its pricing is wrong. (With repeated financial crises as a result.)

Since financial bubbles3 are built from speculation rather than empirical facts, it’s impossible to know when—but not if—they will burst. Nevertheless, with an impulsive driver back at the wheel, today seems a good one to assess your exposure to this ‘mother bubble’-risk.

For more detailed insights, please find the original article here.

Footnotes

  1. A financial bubble is when the price of something, like houses or stocks, rises far beyond its true value because people are overly excited, but eventually crashes when reality sets in.

3 Tips to make principles work

Principles play an important role in personal growth. However, how you define and maintain principles is rarely discussed. To this end, I share some reflections that can help you integrate them more easily into your own life.

Principles should be liberating, not constraining.

Often when we define our principles, we focus on the things we have to do, or that we are no longer allowed to do. This makes principles, which should inspire us, seem like the rules our parents made us live by when we were small. In other words: no fun.

Take the principle “I don’t eat junk food.” At first glance, it sounds restrictive. It focuses on what’s forbidden, making it feel like a sacrifice.

But if we reframe it as “I choose to fuel my body with nutritious, energizing foods,” the same principle becomes empowering. Instead of focusing on what you can’t have, it highlights a positive choice and the benefits it brings. Suddenly, it’s not a rule to obey but an inspiring vision to live by.

Principles should carry their vision.

Again, principles should inspire us, and sometimes we need a little reminder of why we chose them in the first place. As such, it can be helpful to end your principles with a ‘vision’ that captures the overarching aspiration.

“I choose to fuel my body with nutritious, energizing foods” could become “I choose to fuel my body with nutritious, energizing foods, so that I am free of the physical limitations that junk food imposes on me.”

Principles should have a trigger.

I feel that the most difficult part about principles is to remember them. Still, I noticed that for principles with a clear trigger this was less often the case.

Building on the same principle as before, we are more likely to be reminded of actually having this principle when we are presented a choice. So, incorporating and rephrasing, we may arrive at: “When I am in the grocery store (trigger), I choose the healthy alternative (positive choice), so my body will not be impaired (vision).”

Do you have a principle that never seems to stick? See what happens when you rephrase it like this!

Good and bad

In his book principles, Ray Dalio presents his philosophy about good and bad. He observed that what people often call good or bad merely reflects their (group’s) preferences and has very little to do with an absolute truth.

Dalio argues that anything is subject to the laws of nature, and that from it, a more universal definition can be conceived. He writes:

[…] ‘good,’ to me, means operating consistently with the natural laws, while ‘bad’ means operating inconsistently with these laws.

And a little further:

In other words, I believe that understanding what is good is obtained by looking at the way the world works and figuring out how to operate in harmony with it to help it (and yourself) evolve.

I’ve always found the subjective nature of ‘good’ and ‘bad’ intriguing. Dalio presents a more objective alternative, but perhaps one with an overly rationalist taste.

Have you ever defined your own ‘good’ and ‘bad’?