Bill Allombert on Tue, 03 Oct 2023 10:46:01 +0200
|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: How to generate wolframscript "PowersRepresentations[...]" output in PARI/GP
|
- To: pari-users@pari.math.u-bordeaux.fr
- Subject: Re: How to generate wolframscript "PowersRepresentations[...]" output in PARI/GP
- From: Bill Allombert <Bill.Allombert@math.u-bordeaux.fr>
- Date: Tue, 3 Oct 2023 10:45:46 +0200
- Arc-authentication-results: i=1; smail; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; d=math.u-bordeaux.fr; s=openarc; t=1696322742; c=relaxed/relaxed; bh=RpqtX1FSottAZuIYDc8Y9f+MoiJ+aHTycWZWKmUPLXo=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:Mail-Followup-To: References:MIME-Version:Content-Type:Content-Disposition: In-Reply-To; b=hadG/DLD5df4TEz5VBXxkLrjk/TOFCJOh0HIxKHdeewLz3edwvsZpM9kzbw7JxFyuaYgCg8bSBIrO/aSk1wuQvcYGwI6/DkCCxKxtjXHe8L2wJMdZO6BFj0NccyT5vLGMN/BDpsW+tT3xzgzWEXfX7bON5tvcFaJdgs89/WgHsLtlWNTcmdKwuwZ6WaaN68PJOkjqaoWuuNLB4yUCm+EEfWN3YYzzskJ//o6pqcaoqufeWe+v+s6QYYGR3W6/FNxjmh0uorf3dUo7xItmgP3daN+Uz8+VUrohzEYKgSB+3ZCrSiSScJWPTr9lcxAJKnykFXei00GZmb72xL57pZWsZV8lkIZhk2ReMkXCxOHzUHgks8p30g0iKfINfZRR2g23V7cIp6wbvf04D5mMGREupNC05hUy8qSkbnwx8zE9lzrUYk8NgunmB0C4ejmr0taoeGf6WcvEqKx9QT9LxuxSXXu5mTZdNCp/fYlymfC+vmalL5GHqnmTqw4fKGo+VfQ2/ZUYeDNwBSic6bvACu8W6Y1mSq3xuIbg3ooXBJtB7OLSwvW+qOQQmut/Kb0Pkg1EJnAWRxwDygA19A1YnynQnQVDb1vmvwcoM5elk87maoJz/oxWj7haHCsbYO42/CiQ6TQ7XyFSBX2sC92MfHMD6gofuuf/vlhitxhC//7MOI=
- Arc-seal: i=1; a=rsa-sha256; d=math.u-bordeaux.fr; s=openarc; t=1696322742; cv=none; b=CExZoUeDHkviC9nAaYv42Dw6RvFWN4WaGtq9h4QjvMQNme1FaCSxJ0RHElu1mtcAc8BDO+mOVegLje6nZxVQSJtvcYclfbthjKLFoPtbv2D6bv1WhZQqMRoqIVg4tIxid2odoS0oZxTbL69WeIrnJqsgFAsSbfUcw7Aghz1/pcv+RnYrBKGqNsWcGZGT2UZ/qrYwoSzjkMboLj30abZgXeRK0+pAYtdyJ92d4mgmZCQXLvb1BMhG4778ymUEKMNp47p9d+GN1nGMTkgjWt358J178LdGg4Du9moASITYMHYjjQRFspSsm0wYCkPOwJ5Kz/YXIv85C6wbU+NMpfzosGrl1bGw6P+vc8AqH1L/l/UFVIevkh0Y6+Dzv29A5X8xElqynlxlurqtCak4Lw5RjWRhPBgaJbmgjGJ5boiJ9fky/0FpZy2sU6fJzwEQDEQCAahQ0s2TsR03YQ1N0wkOtr6AH/XOmvEAuT97KSUzRAO8jO8gHflBj7hw8u7zvHVgjYI0PxJZJv7JJeYz4TlmSoP66pUx101yZlwHPYhg9H1dKFbQ4O6pstGSm9QFUMyUQ9//U7N9UkvxYD2MZtMweNZY8A81F33fUWfukxBOVwTRVsESv3mUahN7MQzt7NIY46h7ApBueGF2oXvJ0Ga1Db6QQnAwfnmjsITKvlvrJ/8=
- Authentication-results: smail; arc=none
- Delivery-date: Tue, 03 Oct 2023 10:46:01 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=math.u-bordeaux.fr; s=2022; t=1696322742; bh=RpqtX1FSottAZuIYDc8Y9f+MoiJ+aHTycWZWKmUPLXo=; h=Date:From:To:Subject:References:In-Reply-To:From; b=DNg4edDnFc91LDB0Pw1xWG0ovKIqzZXec9/ybifnWWKQIOifABsNr7EqIxWX1rMB7 gbn+DW2H9OZW755cM/sKq+ew3T5yvP/kJbdFFqiepYURUquPpFi7y6tPZv5TFSdBgQ Qh1O/YBJc2CgZhRFIdp/9KNJPaefVpCIejkwXXih0sxsJy0xCA6e0ebK2ASHdg0arF v3N+p+FQaUTGQrf6p/e/3KkBZy6DplqZm4GSdQfaUJpdSEE+dzppqOTGkQPyd3UjWT O5PTFmwZKy8fiIG+jI/zbsO2Tpe7xuUgv79GbWq13rfvLw/T5KcWK9JPaQ951ziWcz Kjc4kh1/t70Ht2I14JqEXGqYGItIUlSGbxgLgUcXu1qCHUKM76ZoD8Yus3OVz+EXhU iUa0wfdneHm11GQtFi0fvSvnrDUoREer1U2u+05Duj+zl1Lm/dxaH2ONCEdxyzwvb7 kU67ibeRqySw1ijOQ6pFiuE+uXNAriSWthrrKi7+rKX5NhreVP5cmgM4GWXdT8xn+6 do//axDnCRVgWryj+PWE6Em3y108TCGBWxcuEU44gHT5q8hpB2mSEJyEt2IW189C9a aEAfAbaN0645rlh1NsS9Ek/dq0oAiFxS/IPn2kDt6q0uWH2qHrH0Gitki8S+KkW4B6 yxNDg2bhaxSULD8BKTPA5Kx0=
- In-reply-to: <5a3dfde3424919e38236fcfc7080c10f@stamm-wilbrandt.de>
- Mail-followup-to: pari-users@pari.math.u-bordeaux.fr
- References: <f7c048745aec43281aeb72b3b2f15d9d@stamm-wilbrandt.de> <ZRsR5YQqCukMLl9l@seventeen> <5a3dfde3424919e38236fcfc7080c10f@stamm-wilbrandt.de>
On Tue, Oct 03, 2023 at 09:31:12AM +0200, hermann@stamm-wilbrandt.de wrote:
> On 2023-10-02 20:54, Bill Allombert wrote:
> >
> > If you want only one solution, you can do
> >
> > foursquare(n) = abs(qfsolve(matdiagonal([1,1,1,1,-n]))[1..4]);
> >
> > ? foursquare(17*29)
> > %15 = [0,0,13,18]~
> >
> > ? foursquare(2^127-1)
> > %13 =
> > [3485713606461563310,6176908041673972933,4510469025815889567,9974590734764851407]~
> >
> Thank you, that is fast and cool.
>
> I tried qfsolve() on bigger numbers, and asked myself whether pari lib
> and C could speed up computation.
>
> I looked at the 37 hits for "solve" in manual:
> https://pari.math.u-bordeaux.fr/pub/pari/manuals/2.15.4/libpari.pdf
>
> I found qfbsolve() and cornacchia(), but nothing I could match to GP
> qfsolve().
> Is qfsolve() only available for GP?
Of course not:
? ??qfsolve
qfsolve(G):
...
The library syntax is GEN qfsolve(GEN G).
Cheers,
Bill.