You also don't balance equations in your examples. Your janitor goes to help a friend with rocketry, which seems like a net gain, but someone else now needs to stop helping a friend to replace that janitor's position. Otherwise researches at that facility where janitor had worked will have to do janitor's work instead of doing their own. You call work cooks and janitors are doing worthless for progress, but researches (or children in school) need to eat, need to have functional workplace/classroom, etc. While they might not make progress directly, they enable other people to make progress.
> We're long past the point where we barely need anybody to work to actually feed/house everybody
Why would we need UBI then? The price of food and of housing everybody would be dirt cheap, if that were really true. Value of anything is completely relative (which I find that many people have trouble grasping). If something requires very little work, then it will be very very cheap in an ideal free market.