Adding internal wave mode computation function. Not there yet.