Lets assume that two extreme intelligent species in the universe can exchange morse code messages for the first time. A can send messages to B and B to A, both have unlimited time, but they can not meet. Is it possible to transfer information between both species? What would be the mathematical precondition for information exchange?
If A sends "Hello friend" to B, he might not understand this message, but could A train B to understand the code of A?
For example A could expect, that B will know logic and first send some definitions like the generation of natural numbers and primitive logic or calculations.
Has there been a publication in a journal on this topic?
Communication with extraterrestrial intelligence has actually received a fair amount of (theoretical) attention.
If you have seen the film Contact or read the book (by Carl Sagan), you have seen a brief description of what seems to be the best current protocol. The message Sagan describes in the novel seems to follow the pattern of Lincos, a language developed by mathematician Hans Freudenthal. The idea, as you suggest, is to use mathematical language. The Wikipedia entry does a decent job of explaining how the messages would proceed. You may enjoy to know that messages coded in Lincos have actually been sent to space, in 1999 and 2003. Lincos itself was detailed in the book Lincos: Design of a Language for Cosmic Intercourse, Part 1. (Part 2 was never written.)
Let me quote from Wikipedia:
A few more details of the first two sections are presented in Contact.
For more details of research in these area, see here. The main issue with Lincos is the underlying assumption that the language of mathematics is universal, which can be traced back to the question of whether mathematics is created or discovered. This universality, its "unavoidable character", is somewhat disputed (again, at least theoretically). See for example the book
and for another view, the works of Mario Livio, in particular Is God a mathematician?
(Of course, your question is a bit harder, since it does not require than the originator of the message is human. But Lincos is still the most developed protocol and, at least, should give you an idea of the minimum mathematical assumptions that an exchange would require.)