[...] tip is to avoid generating many small arrays and matrices inside the innermost loop. In general, computer languages (such as SAS/IML) that pass arguments by reference can be more efficient than "functional" computer languages in which every function allocates and …