# Prove that a ring is commutative if $(ab)^2=(ba)^2$

Let $R$ be a ring with unit element $1$ such that $(ab)^2=(ba)^2$ for all $a,b$ in $R$. If in $R$, $2x=0$ implies $x=0$, how do I show that R is commutative?

Is there any general approach to attack this kind of problem?

• Some solution is given as Theorem 4 here. It was among the first google hits for "ab^2=ba^2" commutative. [By this I do not suggest that googling should be considered the general approach for such problems ;-)] Nov 18 '11 at 11:44
• @MartinSleziak is there any other way to solve this? Dec 12 '17 at 15:53

Let $F(a,b) = (ab)^2 - (ba)^2 = abab - baba = 0$. Then routine verification shows $F(1+x, 1+y) - F(1+x,y) - F(x,1+y) + F(x,y) = -2yx+ 2xy$ so $2(xy-yx) = 0$, which implies $xy=yx.$
{"ft_lang_label":"__label__en","ft_lang_prob":0.8728994,"math_prob":0.99988985,"size":929,"snap":"2021-31-2021-39","text_gpt3_token_len":299,"char_repetition_ratio":0.08864865,"word_repetition_ratio":0.42774567,"special_character_ratio":0.34553283,"punctuation_ratio":0.10697675,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.99999595,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-09-22T21:25:43Z\",\"WARC-Record-ID\":\"<urn:uuid:e08c53c8-d72f-47e3-bf4e-e94338cbf700>\",\"Content-Length\":\"163880\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:acf1c619-cf15-4cf0-ade2-2f5711e9e574>\",\"WARC-Concurrent-To\":\"<urn:uuid:8f42688f-83d6-450e-abf0-9422d7c61713>\",\"WARC-IP-Address\":\"151.101.129.69\",\"WARC-Target-URI\":\"https://math.stackexchange.com/questions/83334/prove-that-a-ring-is-commutative-if-ab2-ba2?noredirect=1\",\"WARC-Payload-Digest\":\"sha1:VGNUZWI36T7753DNUAUL6NDRVWH75C2S\",\"WARC-Block-Digest\":\"sha1:FEKD56JZ2H4CZMUNX5ST73G2MIAE6TLI\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-39/CC-MAIN-2021-39_segments_1631780057388.12_warc_CC-MAIN-20210922193630-20210922223630-00478.warc.gz\"}"}