# What are physics codes?

Aaronvan
What are physics "codes?"

How does the physicist define “code?”

I often read slug lines such as “New hydrodynamic codes reveal stellar core collapse” or “Scientists use EMSolve Code to better understand magnetic fusion energy.” To most laymen, code is a set of instructions, i.e. a computer program.

However, when I peruse the paper or article the code in question is often a set of mathematical equations. It is certainly not computer code, pseudo-code, or even an algorithm.

I am perplexed and hence the question. Without knowing any of the specifics, I presume the codes involved are the implementations of the equations. The papers usually describe the results obtained from the codes.

dauto
They are talking about a computer code that solves the equations numerically.

thegreenlaser
How does the physicist define “code?”

I often read slug lines such as “New hydrodynamic codes reveal stellar core collapse” or “Scientists use EMSolve Code to better understand magnetic fusion energy.” To most laymen, code is a set of instructions, i.e. a computer program.

However, when I peruse the paper or article the code in question is often a set of mathematical equations. It is certainly not computer code, pseudo-code, or even an algorithm.

I am perplexed and hence the question. A lot of times, the actual computer code isn't what people are really interested in. They're interested in the mathematical models for things, and they're interested in the solutions to those mathematical models. The computer code usually just provides a way to extract solutions from mathematical models. Researchers may spend a lot of time writing code to solve a problem, but if they don't use any novel algorithms or techniques in their code, why would they bother talking about it in a paper?

Also, a lot of times researchers may be using proprietary code. If a company writes some code and is making money off of it, they probably don't want some researcher blabbing about it in a paper. In fact, the researchers themselves probably aren't allowed to know everything about how the code works.

Aaronvan
Good information, thanks.