Path: ...!weretis.net!feeder9.news.weretis.net!news.quux.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!eternal-september.org!.POSTED!not-for-mail From: "Chris M. Thomasson" Newsgroups: sci.math Subject: Re: Equation complexe Date: Tue, 25 Feb 2025 15:31:08 -0800 Organization: A noiseless patient Spider Lines: 65 Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Date: Wed, 26 Feb 2025 00:31:09 +0100 (CET) Injection-Info: dont-email.me; posting-host="7d2bb58dfe24acf4c8e5f08fe35a4e41"; logging-data="2350201"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+pD7BbgtlcvM/x760DSDFZ3Y4DSArSKV4=" User-Agent: Mozilla Thunderbird Cancel-Lock: sha1:jObMkIh6UUa+yfS+pqb6KkffkCA= Content-Language: en-US In-Reply-To: Bytes: 3021 On 2/25/2025 2:09 PM, Richard Hachel wrote: > Le 25/02/2025 à 22:49, "Chris M. Thomasson" a écrit : >> On 2/25/2025 6:23 AM, Richard Hachel wrote: >>> x^4=-81 >>> >>> What is x? >> >> >> Try to forgive the floating point precision aspects, but, the roots >> are the r's, raising them to the 4'th power gives the p's: >> _____________________ >> r0 = (2.12132,2.12132) >> r1 = (-2.12132,2.12132) >> r2 = (-2.12132,-2.12132) >> r3 = (2.12132,-2.12132) >> >> p0 = (-81,-7.08124e-06) >> p1 = (-81,-1.93183e-06) >> p2 = (-81,-7.53158e-05) >> p3 = (-81,4.57051e-05) >> _____________________ >> >> >> To gain a root, here is my code: >> _____________________ >> ct_complex >> root_calc( >>      ct_complex const& z, >>      int p, >>      int n >> ) { >>      float radius = std::pow(std::abs(z), 1.0 / p); >>      float angle_base = std::arg(z) / p; >>      float angle_step = (CT_PI * 2.0) / p; >>      float angle = angle = angle_step * n; >> >>      ct_complex c = { >>          std::cos(angle_base + angle) * radius, >>          std::sin(angle_base + angle) * radius >>      }; >> >>      return c; >> } >> _____________________ >> >> >> Also, this is not using floating point for roots, just signed integers. > > This is quite complicated, Actually, it's quite straightforward wrt getting at the roots for a target number. Even using signed integers for the power. > where I propose to use the nature of the > imaginary number i in a somewhat particular way, and according to the > new idea that i is not only defined by i²=-1 or i=sqrt(-1), but rather > with the generalized idea that for all x, i^x=-1. > A bit like if this imaginary was the antithesis of 1 where for all x, > then 1^x=1. > > With this technique, we immediately have x=3i. > > R.H.