Moved 1d swr function into seperate file
Updated domain parition logic to something more rational
Moved 1dopt swr code to function in seperate file
Moved 1d pipe code into seperate function
Moved 2d opt swr code into seperate function
Moved 2d pipe waveform code to seperate file