No, communities on a given instance are completely independent from communities on other instances. There just happen to be two communities on two different instances with the same name (of course c/math is not the only case of this).
The federation makes it so that anybody on any server which is federated with both lemmy.ml and lemmy.world can see all the communities on both servers. This means you can subscribe to both the c/math on lemmy.ml and the c/math on lemmy.world. The fact that lemmy.ml and lemmy.world are federated with each other is inconsequential.
Yeah I believe that's a valid point of view when coming over from reddit.
People have been saying (and I somewhat agrree) that it's really analogous to how there can be multiple subreddits with effectively the same topic (e.g. r/compsci vs r/computerscience, r/math vs r/mathematics) and that either:
One will dominate the other in popularity, and the smaller will be absorbed by the larger
They will each cater to different aspects of the larger community they have in common
Point (1) I think has already happened on the fediverse with the de-facto piracy community being /c/[email protected].
Point (2) I believe makes particular sense in the case of lemmy, as different instances will have different themes and codes of conduct and rules of administration. Thus it might make sense for there to be different communities of the same name across different instances, as they might be about the same broader topic but differ significantly in culture.
That's actually why I made this community in the first place: lemmy.ml was never intended to be a general "catch-all" instance, it's just the instance the devs use and has always catered to their particular interests and ideologies. In fact I think ideally if there is to be a monolithic c/math then it should live on some instance more specifically dedicated to STEM, not a general instance like lemmy.world. But again, the problem has re-arisen, as there are many small "STEM" instances now but none are go-to. It's an exciting time, we'll see how it all shakes out.