- The code should be designed to seperate physics or model from numerical methods.
vectorsare convinient but slow. 1
- Do not copy arrays if not necessary. The example would be for a function return. Most of the times, we can pass pointer of array to the function and update the array itself without copying anything and no return is needed at all.
- inline function.
namespaceinstead of class if no data structure is stored in it.