Radiant Connections Visualizing the Interplay of Human Energies and human body and color fully background and art man
| | | |

How do you model metabolism?

The whole reason I got into software development was to improve the way in which biology is researched, understood and presented. I have always wanted better ways to explore the subject and understand how the whole complicated system works.

This article is an attempt to plan, develop and deliver on that vision. It is not a complete or organised article it is a set of notes helping to achieve a goal. I am sure many others have the same or similar goals so if anyone has any feedback or help to offer then please get in touch through comments section, email or ping me a DM on social.

What I understand about metabolism and how to ensure energy flows correctly through you and out again is something I am always incredibly grateful for. On a daily basis I see people wanting to have the same understanding to prevent the suffering they and others are going through because they lack this knowledge and experience.

So this project is one small way I can help others work with metabolisms and not against them..

This post is therefore a work in progress and a place I am using to share and coordinate a dream I have had for a long time but have struggled to find the time and resource to pursue. I am hoping that I can now find the time and resource to complete these project or atleast make a useful start.


I think it will be a series of input and output interactives. Refactoring the code to loop through the inputs and outputs to calculate the values

An intro interactive summarising the problems with a misfunctioning metabolism. It’s a problem in so many diseases, and the paper I plan to review shows a typical example of the scientific background. Biology is always about adaptation to demands. The story is similar for so many diseases. The body is insanely complex, so it is impossible right now to know everything that is going on. What is clear, though, is that when your metabolism goes off kilter, you open yourself up to injury and disease on the cellular level. This article is a typical example of research in the area of metabolism and disease, highlighting one of many ways in which the metabolism can be deregulated and hijacked for other purposes.

Krebs/citric acid cycle

Start by simply logging the inputs and outputs and adding a calculation for the outputs with a given input. Then, list the stages of the citric acid cycle with defaults. Then update the output when i change values. Just work systematically through.

It is the same as for the cardiac experiment I am planning. Start with a table and graph. Make it interactive. Use the graph in a componentised way. I’m really running experiments on standard models with specific values


How to metabolise fat

Click to reveal (CTR): animation How much ATP for fat

Combine with the metabolism sim CTR. Work slowly towards this by putting the fat metablism cycle in place I have the values for glucose. What happens for fat. What inputs and output Fats and proteins can also be used to respire. When fats are about to be respired, they are broken down into fatty acids and glycerol. The glycerol is converted into triose phosphate and enters the glycolysis stage. The fatty acids are broken down into two carbon fragments and entered into the Krebs cycle via acetyl co-enzyme A.


Energy balance

Notes from September 2011 For the course I am considering using a simple equation to explain energy balance in an accessible way.

When people talk about adding or putting on weight what they really mean is that they are adding energy which is being stored instead of being released from the body through normal metabolic pathways.

The equation I am considering is:

energy difference which is the factor of energy in minus metabolic rate and then energy for activity.

In reality, metabolism is far more complicated than that, but it’s the essence. The equation can show that as energy intake increases, only activity and the increased metabolic rate attributable to activity through increased muscle mass, etc, can balance the account. So. either you reduce your intake or you increase your activity to match. This is the basic equation. 

The same is true for minerals in nutrition. BMD has a similar equation just using calcium instead of energy. So does salt and sugar. Exercise loses salt through sweat. So more exercise allows more salt in the diet. It also teaches your body to regulate salt better. 

The same process can be used for sugar because it is modelling a natural feedback mechanism and restoring balance. 


It is also not only the first century of inadequate activity, but it’s the first where an abundance of flavourings like sugar, salt, fat and others occurred due to industrialisation. Essentially, The natural cycle of feast and famine has been turned on its head, and we now have a situation of a feast and famine of exercise instead of food.

Only occasionally do we do a lot of exercise. often as a new year resolution and only occasionally are we starved for the same reason. We’re mainly inactive and stuffing ourselves. This sedentary lifestyle has never happened on mass before and so our cultures have not learnt to adapt to it these new ways. We stick with old ways designed for past lives and ignore the abundance and opportunities of the present. We simply have not learnt how to have our cake and eat it and we have sadly also forgotten that activity can be so much fun. 

Most would agree that top athletes require a body that’s well organised, efficient and strong. Otherwise they couldn’t overcome the challenges they face. It’s also fair to assume that an inactive body will be less well organised, in efficient and relatively weak.it will have trouble overcoming daily challenges.

Fit bodies must work well

Through tbis course i want to explore the concept that western diseases can be seen as a result of these effects of inactivity. How heart disease can be an inability to handle salt, the same for diabetes and sugar. How osteoporosis can arise because the body isn’t told that strong bones are important.

That our bodies have evolved to respond to the daily signals of activity that hunters and gatherers traditionally receive.

An advantaged metabolic state

I just watched a wonderful video by Peter Attia on the physiology of human performance and it’s impact on health. It was like being back at Loughborough University, having lectures. It covered some of the details I covered there and showed clearly some of the benefits. This was on the IHMC channel, an organisation focusing on human performance. Their About page fascinates me, and I would like to know more about this organisation.

So, to start the conversation, I want a blog post linking to the site, embedding or linking to the video and a few questions that I have about the organisations. I was planning to email and contact via social thanking them for the video and asking more about what they do. e.g. their current research projects sound fascinating I like this because it is a learning journey.

Peter is very clear that he doesn’t know the answers. He is just sharing what he has learned and is continuing his journey of knowledge, So we should, too. I like that I learnt detail about the ketone metabolism process that hadn’t been explained to me in detail before and it explained another way fat can be metabolised as my training I can see focus more on the citric acid (krebs) cycle than the ketone cycle.

I still notice that we treat the body as a simple machine, not the highly complicated living organism that it is. So we really only know, at best, 10% of what there is to know about it. He still spends lots of time micro-managing his body like so many people do. It is good for learning but not for lifestyle, and it is not the only way. Not something our ancestors did all the time

Peter Attia – An Advantaged Metabolic State: Human Performance, Resilience & Health

Further reading

Protein/Nitrogen metabolism

How much urea is excreted for grams burnt? Proteins cannot be stored by mammals, so they have to be either used or excreted. The respiration of proteins only occurs when there is an excess of them in the diet. To begin their process, the amino group is removed (called deamination). The amino group then combines with CO2 to form urea, which is later excreted. The amino acid remains, now without an amino group, are called organic acids and are fed back into the Krebs cycle.

Further reading

Glut 4

Make a start to some ctrs that explain metabolism for FTT site. These are references to use. I start with a static image with hotspots. I then add animations to bring the cycle to life

Record basics of oxalate

As part of nutrition, I had never heard of oxalate poisoning, but it’s bad and easy to prevent, though the current list of healthy foods is high in oxalate. Of course, my view is all about moderation, which this confirms. The YouTube video put me on to it, and the links reinforce it. Put this somewhere. Maybe in my GI ftt section Kidney stones are the big reported problem. Still, oxalate binds to many of the body’s ionic molecules, so it would have the potential to disrupt the electronic ion flows through the body and lead to related problems. The video highlights many of the problems.


Further reading

A Fit2Thrive Game


Show the cumulative effects of regular exercise. How much more a fit person will burn over the same time and how quickly they will recover. Just concepts not precise.

And how much easier it is for a fit person to gain the protection from activity. They’re also much better able to withstand the ill effects of over doing things. They’ve trained their body for this.

Key to what i’m building is a dash board app. A snapshot on what’s going on.


Each topic could be associated with a character. So diabetes could be Bob, general metabolism, John. Osteoporosis Doris and cancer could be Bette. 

Then you get to know them over time as we cover more detail. 


Level 1. Inactive. A body that can’t handle even the basic food. Everything has consequences. Stress causes problems. Recovers slowly.

Level 10. Active, balanced lifestyle. The body can handle any food thrown at it. Can handle a lot of stress. Recovers quickly. High reserves. High threshold for bodily, mental and emotional stress. Is able to go on the best treks. Maybe incorporate with Google Maps and Earth. Hide really cool links in the game. You find the best links when you master your character’s lifestyle.

Maybe they go on a hunt through virtual space. And share what they find. Or maybe we get people to find and share information. They gain points as they contribute to the debate.lets  turn the course into fun. Each person says what they enjoy. For each task, they contribute by pursuing things from their own angle. We start making life fun.

? Maybe it’s just an active game where they’ve got a bunch to do over a long period. Doesn’t have to have graphics. Can just be a basic maths challenge. The probability of winning is higher when your fit so you then thrive.

Introduce basic penalties like life eventsx, injuries, illnesses and stuff. See how the unfit person fairs against the fit.

Active people can eat more

An active person can eat more than an inactive one and maintain or lose weight. Show how much. Just give a simple example where more activity puts more food on tyhe table. Show that it’s easier to hit nutrition and taste goals at the same time and that it’s much easier to feel full and lose weight. Because you can have that little extra but still be in a deficit. 

The fitter you get the greater the deficit. 


need a dashboard. One value monitored is fatigue. Work rest and play feed into this. GFet too tired and bad trhings happen. diabetes, heart disease risk increase. Cholesterol increases. etc. 

So the game is all about balancing the dials. Thing is they’re always changing. Without rest fatigue is always increasing. energy is going down. The body is always breaking down. 


One way of highlighting elements is to use layering. A translucent darker layer above normal pane with the new element highlighted by settings it’s z index to show it. could then have all elements in place and just highlight what’s relevant. 


Considering the chemical expressions in http://shapiro.bsd.uchicago.edu/21st_Cent_View_Evol.html. It seems obvious to describe glucose in js or json form. 

even using arrays and objects connected to each other.

function Oxygen () {


new Oxygen

fuintion Carbon (){


new carbon();

function Glucose

So I have a basic version in chemistry.html. Shows the basics work just fine. Could easily be a long term project. I just need to figure out what to use it for. But I’d like to work at different levels in js as science. this chem layer could be used to show the transfer of energy. 

I could also show how diabetes develops through lack of exercise. 

But essentially I don’t have a specific simple use case yet. There’s no real reason to do this. 

Diabetes app

A basic outline for an app presenting the development of type 2 diabetes

Person has diabetes type2.  They are Inactive. with Low glut 4 expression. Not sensitive to insulin. No Blood carbohydrate control.

Activity increases glut4 and insulin sensitivity. Good carb control. Clears quickly.

Needs timing. Activity is a button. Either on or off. Just watch resistance climb when it’s off and dive when it’s on. Just watch over time. E.g effects of no ex take long time to appear. Ex effects are quick. Get people to find specifics. Principle still correct.

Virus transmission example

Can show virus transmission in js using eval statement and other bad os practices. Show that an overloaded system is more likely to allow viruses. Ux could be a game with stuff to do. E.g finding errors in a cells dna. When there’s too much to do the dna gets infected.

As a game. Could be a classic space invaders game re themed as cell invaders. As the levels progress you learn more about how viruses get in. Can show bacteria too in another game.

Explaining mitosis and meiosis in virtual systems.

One is an exact duplicate copy. Just like cloning an object or creating a new instance of a class. The configuration and lifecycle can change the class completely.

The other is merge objects and arrays. If one object doesn’t have a feature it takes the others . Syncing with master and slave is the same. The whole is more than the parts. This has dominant and recessive. The master is dominant the slave recessive. If a conflict occurs the masters details are chosen. Only if the masters config matches the slaves or if the master doesn’t have that config does this get expressed.

This is how i would explain inheritance to a coder or anyone who uses tech. Knowledge of tech gives knowledge of life. It also reflects permission systems.

Could create a script with two cells and explain meiosis and. Mitosis with them. Each has a nucleus with genes. Real basic stuff. Both have different values. One is dominant. Maybe its even the config that’s dominant and different. Not the code.

James Shapiros work also shows that life thrives on knowledge and the sharing of knowledge. The basic units of knowledge are known e.g protein units but their order of expression is open to change. So it’s much like languages we all know.  the letters of the alphabet andd even the word are already figured out. It’s how the sentences, paragraphs and chapters are put together and edited by the cell and natural processes that is the process of evolution


Could i link raphael objects to a simple decision chain.

Maybe scenejs is where to do this. They already have a human. Maybe i can add some animations to their existing model

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.