## Complex roots of unity and the map() function

Here’s a little application from Complex Variables class that uses map() to repeatedly apply Maxima functions to each element in a list.

We want to find the complex 6th roots of 1 — there should be six such complex numbers $z$ that solve the equation $z^6=1$ Notice the solutions are returned as equations…this is sometimes really handy, but for now we want to isolate the right hand side of each equation. The command rhs(), when applied to an equation, returns just the right side. We can apply the rhs command to all the equations contained in our solution using the Maxima command map(): Finally, with the real and imaginary parts extracted, we can plot the six roots
{"ft_lang_label":"__label__en","ft_lang_prob":0.902032,"math_prob":0.99705046,"size":659,"snap":"2021-31-2021-39","text_gpt3_token_len":134,"char_repetition_ratio":0.13129771,"word_repetition_ratio":0.0,"special_character_ratio":0.20333838,"punctuation_ratio":0.072,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.99810845,"pos_list":[0,1,2,3,4,5,6,7,8,9,10],"im_url_duplicate_count":[null,null,null,null,null,null,null,null,null,null,null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2021-09-25T05:49:38Z\",\"WARC-Record-ID\":\"<urn:uuid:5e3fa8f3-7a59-455f-bd87-c2b118fc2511>\",\"Content-Length\":\"80544\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:63445547-7232-40f8-86f6-50711c397578>\",\"WARC-Concurrent-To\":\"<urn:uuid:70e4f1e9-ac2f-4861-8ab1-b9766443091f>\",\"WARC-IP-Address\":\"192.0.78.25\",\"WARC-Target-URI\":\"https://themaximalist.org/tag/roots-of-unity/\",\"WARC-Payload-Digest\":\"sha1:RBTJADC7FB7US7E57DXEMPGF5K7R63PT\",\"WARC-Block-Digest\":\"sha1:WLK2SZSZWYPQXKF26BHX5ECL375P2PDQ\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2021/CC-MAIN-2021-39/CC-MAIN-2021-39_segments_1631780057598.98_warc_CC-MAIN-20210925052020-20210925082020-00158.warc.gz\"}"}