# Chaotic Love: What math can tell us about how relationships evolve

I’m very proud to say that Nanaya solves a problem that hasn’t been solved before: determining the value in time of relationships and the option of possible relationships. The Nanaya algorithm has to be pretty complicated to do all of that – a machine of gears, pulleys, and switches that work together to provide a result. The machine has many parts of which are some have been around for awhile.

For instance, the problem of determining relationship quality and stability has been worked on. My old textbook, Nonlinear Dynamics and Chaos by Steven Strogatz, works out an example. This isn’t exactly how Nanaya works but we can take this as a “simple” example.

To evolve a relationship in time, we need to know a few things:

1. Who are the people before their relationship begins? That is to say, what are their personalities and life circumstance before the first kiss.
2. How do their personalities interact?

Because this is math we need these to be quantified. We can do that with personality testing and asking a few other questions.

Now what’s next is to set up a system of differential equations. Specifically, there is an equation for each partner that shows how much their affection changes in time based on who they and their partner are. We can consider the simple example of “Romeo” and “Juliet” from Strogatz.

Oh dear. So what do these equations mean?

So R(t) and J(t) are functions of love/hate in time. Let’s use dR/dt as an example, though you’ll notice both equations are very similar. R(t) is Romeo’s affection toward Juliet. When R(t) is positive, he is happy with Juliet; when it’s negative, he’s not. dR/dt is simply how much his affection is changing at any specific point in time based on the shared emotions of the couple.

At time zero we have R(t=0), which is Romeo’s interest in Juliet before the relationship.  J(t) and J(t=0) are the same values for Juliet. The values a and b are factors that multiple the feelings of the couple for a specific person. The larger a is, the more Romeo is happy that he is in love. The larger b is, the more Romeo is happy that Juliet loves him.

Well that’s a lot of math. Of course any model like this is a huge oversimplification of reality. Here we look at two dimensions: how Romeo and Juliet feel about each other. These can be broken into many, many other dimensions based on personality and other factors. The oversimplification is welcome as adding more dimensions allows for very complex behaviors that aren’t very predictable. Essentially, the system becomes chaotic as described by chaos theory.

As complicated as it appears it’s very easy to see what happens for various personalities and initial conditions!

So we can consider a few personality types based on a & b:

• Excitable lover: where a > 0 and b > 0. For the excitable lover, any positive emotions from either partner just make the person happier and happier.
• Neurotic lover: where a < 0 and b > 0. For the cautious lover, self-doubt causes affections to diminish but love from a partner can over come it.
• Narcissistic lover: where a > 0 and b < 0. For the narcissistic lover, personal feelings are more important than how a partner feels.
• Hater: where a and b < 0. For the hater, any love is toxic. Even if they have early affection, that disappears. The more they’re loved the more they’ll run away.
• There are special cases where either a and/or b = 0. We don’t like haters around here.

That gives us ten different combinations of relationship types, ignoring those special cases. Even for each pair of relationship types there are several different outcomes. For instance, how identical are their personalities and how attracted are they at the beginning of the relationship? Let’s see a few different test cases.

These are parametric plots. In all these cases the arrow indicates going forward in time. Positive values indicate affection and negative are annoyance or dislike (i.e. top right is mutual affection, bottom right is Romeo loves Juliet but Juliet does not love Romeo, bottom left is mutual dislike). Units are arbitrary!

Two Identical Excitable Lovers With Mutual Attraction

This is the predictable outcome when two excitable lovers, attracted to each other, fall in love. Romeo and Juliet are attracted and that initial attraction just builds in time to create a positive feedback loop of mutual admiration. They go off into a bright, love-filled future.

Two Excitable Lovers With Juliet Not Initially Attracted

Without being initially attracted, Juliet simply isn’t interested even though Romeo is. Romeo has a persuasive personality, which causes her to change her feelings a little bit but she remains unconvinced. As time goes on, the relationship is simply unsustainable and the two part ways.

Now what happens if Romeo is just a little more persistent? We can tweak the a from 3.0 to 3.106 to find out:

In this case, Romeo can cajole Juliet just enough for her to overcome her initial ambivalence or lack of attraction to fall in love. In the near future, it’ll be a one-sided relationship but it will ultimately become more equal in love over time.

A Neurotic and Excitable Lover

Here we have a neurotic Romeo. A little bit of attraction at the start from Juliet enables a relationship to form but it ends up a bit lopsided. As time goes on, it’s clear to see Juliet does love Romeo “more.” There’s nothing wrong with Juliet per se, just that Romeo needs to learn to love himself apparently.

An Excitable and Narcissistic Lover

A recipe for disaster, it’s an unstable relationship! As soon as the narcissist Romeo feels too loved he wants his freedom but as soon as Juliet pulls away he wants attention. Because Juliet will keep loving Romeo so long as he’s happy, the relationship just oscillates between love and hate. It’s unclear what happens in the end but it’s truly something to avoid unless you really like drama. Maybe someone could write a play about it?

So there you have it, we can try to predict the long-term behavior of relationships with mathematical modeling. Reality is a lot more complicated as human relationships span more dimensions than mutual affection. With those extra dimensions comes the chaos that makes predictions all but impossible. It’s even harder when there’s no truly objective means of assessing personality and integrating life circumstances with personality as a means of determining initial conditions.

But difficulty be damned. At Nanaya, we’ve worked on isolating those most important parameters and determining relative long-term behaviors. We’ve made unpredictable, computationally intensive problems tractable and realistic. With the help of volunteers, we’ve validated our prototype outcomes. As time goes on, we look forward to more data as a means of further validating and improving our theory.