Text this: Flowfield dependent variation method for one dimensional stationary and moving boundary problems