Bill Allombert on Fri, 24 May 2024 23:07:43 +0200
|
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: Making use of "GP in your browser" questions
|
- To: pari-users@pari.math.u-bordeaux.fr
- Subject: Re: Making use of "GP in your browser" questions
- From: Bill Allombert <Bill.Allombert@math.u-bordeaux.fr>
- Date: Fri, 24 May 2024 23:07:38 +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=1716584860; c=relaxed/relaxed; bh=7I+t6WVuCReIvIj1w0rxpVY/xDl86T0wESTJXZgxlec=; h=DKIM-Signature:Date:From:To:Subject:Message-ID:Mail-Followup-To: References:MIME-Version:Content-Type:Content-Disposition: In-Reply-To; b=A2qzKCnc6PN5KNuJtEdcZQi9QtETAFKujgSJivIrckfj4sK9NxcFsO7Mb614ZvQjpQtZ0s3LBr2N2jgt86AZVTl1RCnyD+9uyjPzbMBhFuFR6lkGpXZBrw8+3UU5dj+foqPzCYtBkwdDqrejCFpf1j7Eyt0aF/QffYUZg+P/505ZDvFWBRyVF7Mv69eTBMwEroBPuUUxhQKczCHuc5dv6ALiSl7a2Zdwv5ndlJbE5nLWjFML+YjL1q2T0wZ9qpFM7ZS9mBvFQg67h77yKZZep1KA+JnZSTNJ96dHvDNLJerRy4uFTuQtCwS2jC8N92lIsNp70u4ChPshWIGJIHeynoo6YgZNCF2cyAW/WxL9kNQBYGkIbSoAvpe3QOD0iGw7Fcy+Dm5tInm2JK9GAfXcghav5WzpDxqe3MDdLYCud4zBdtag07RtgYnXvUbVqJQ2sOCONxH798Flk9Hm9EG52HfeNRn/RuT0i21Frb0dtsJsM7WXbtqZz3iacoWHsSAMYvKEopv0I4w3D4ijrh3d/sCLw6wqfiNlN0LB6HwQ/7bssyaIOvbExaQxv4+Uw1ds4jZ6EySExddKLW1M1MskQ0AKTihFRO0QDfDaxdcIEIPUHVNUgT3WFL7+JfzTTXuFBVidAhOmpBFBof/RBxg7UByJuVF/hGJKrTAjKeTYGbw=
- Arc-seal: i=1; a=rsa-sha256; d=math.u-bordeaux.fr; s=openarc; t=1716584860; cv=none; b=oZ/L2pD9zKW0FqWNfRCyU/H/vZHCj2MSAUekN8rMqqFv+jWjBv2VCYI35NO+3mRgSN9EiIGcZpZIJlxn/Iz735IdahLzLuKdbMVSoc5E1b3BRWusFzrBimR0vijJ1dxqHpZkMl1iBNRxL5dqbnn4+zffR5NsJkCTmyz6yvMdH2u+M4OXHRHNlFFzK+UH25NoG8bZtqvzzRit9is+lWWFQ7O875l3K92LU9L7EPoGAD6qJCW8yJ5fcvLkrqDDRgAlLcVhmTqMyZ4scOY2xDqbGhTGhir7zMpmtSDnlxC9aqObU91wV0DDNV6nlfeJ/kIi5iYChLzzTtgH95BBTiNyrMp/UFQcku+AtEN8YOaBi6uuqfnDraSwsu2snDK4jtcH9L+5B5ArZV6mvP9yQHC3lU9kZ5GNmDISC4CvLdLzMKQ5FgwB8hqDJqRD/a6ChXeLPHuDO8rctXCNZV5lTTBcF9l6OxEJ9QOez0vVFPGnphgfSsVbs03G2eAYOLDIShkc5a7Enp45aGA1uuBbDcpwk4spLquxarxEN+yvvacD4UQzGVyDo5/ytZzAKVJHlZPN7joRZPEmeRImlxhgqqTZBnaKq02wLmRFVmB1vWYJduGm+SoU8w5DOrSWJWW5/Dq8nwaMZ6UqAaFF0ArCN7jFpZH6US7/KN01bDtlpqhwEx4=
- Authentication-results: smail; dmarc=none header.from=math.u-bordeaux.fr
- Authentication-results: smail; arc=none
- Delivery-date: Fri, 24 May 2024 23:07:43 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=math.u-bordeaux.fr; s=2022; t=1716584860; bh=7I+t6WVuCReIvIj1w0rxpVY/xDl86T0wESTJXZgxlec=; h=Date:From:To:Subject:References:In-Reply-To:From; b=RAp//CFdQRjvtE5ARAXk1cps8d3nBX2farx0/arVV8YdqXhHcCCvElMhbycKPZ3e+ +f6Ps2UW2CM1pmVC5xz1EhKta0zKBA+ZgclI9ZE5LzO56+cTeEpfMRViE5ljGGqBAX f9LRMaND0hOYUUaFCxE7lUgnDS9J3Yj9ax+tQ+Ea9JPnjQk7maI0fqTwt4YsxvQtQn MezKKsnUX2pzcq/z+Rfk6ERtwvy+yfdw4NlOJ4uaAdG9JUKq30MKhVH3McOt1S2tkX rrOfjKlVfkf7wIgeWUDzpR6IX9AbXCYLWdpXw8WLtbx++H/MNgtlcLhk9MszquYpgN vUirPlf69F9WeGKjSXsNSmIwnRM3zrDcTi60pe6zvU/y61ykub9k9PLvmoPUuY6L5j N7yd1Z4xwbTj9tOO9QOvtueZLpiHMi38oMcUO6wA3q0pdS/BCC9qFAqA/0No8SoZ9P KczNNRIX47LB4u1NXgs+WHS9s+HxIaVEOurbysYjhjtkvD34TGHBUaKkxoneCYfA5k vQIkBt/YOhgHqTJnEgCckakAOi7+AwjEMnKvSgS/gqT8q6Y50QkTgX1S2ohaUtlbl0 lTKRGQgD7XRAQDJGnKCnA8ht/6CkTnttQEGLu6JZXZhB5WKIYh/5hf8fD9Hm6bXKI2 jBxlSbITQQUE5tmGbiI4UQTE=
- In-reply-to: <3a163f85800af9b1189e5cbb3743bae2@stamm-wilbrandt.de>
- Mail-followup-to: pari-users@pari.math.u-bordeaux.fr
- References: <3a163f85800af9b1189e5cbb3743bae2@stamm-wilbrandt.de>
On Fri, May 24, 2024 at 01:48:27PM +0200, hermann@stamm-wilbrandt.de wrote:
> Then I remembered this webpage:
> https://pari.math.u-bordeaux.fr/gpwasm.html
>
> While there is plenty of documentation on the website for many aspects,
> I found none for making use of wasm GP in browser.
Agreed, but I do not know enough to write it.
The source code for gpwasm.html is at
https://pari.math.u-bordeaux.fr/cgi-bin/gitweb.cgi?p=www.git;a=blob;f=wml/gpwasm.wml
> So I did save complete webpage, and downloaded gp-sta.wasm in addition:
You need a gpjswasm directory with gp-sta.js and gp-sta.wasm
(and optionaly root/ for optional packages).
Theses files are generated when you compile PARI with emscripten/wasm
> function myevalm(s) { return
> Module.ccall("gp_embedded","string",["string"],[s]); }
> in browser JavaScript?
gp_embedded is documented in doc/develop.tex.
Once gp_embedded_init start, you can use it to evaluate strings.
> 2) Is it OK to use
>
> https://pari.math.u-bordeaux.fr/gpwasm/gp-sta.wasm
>
> in own webpages for using myevalm() ?
> 3) Is it OK to host gp-sta.wasm eg. locally in github.io domain from
> lattice_sphere_cmp repo?
>
> 4) Does the repo need to have GNU license for 3?
The file gp-sta.wasm is a binary file generated from PARI source code (and GNU GMP) with emscripten.
So it is covered by the GNU GPL v2+. So you need to point to the GPL and
you need to also distribute the source code of PARI and GNU GMP.
Everything should be available from
https://pari.math.u-bordeaux.fr/pub/pari/javascript/
except the is no wasm file yet, I need to fix it.
Whether you want to copy or link to gp-sta.wasm is your choice, but it is probably safer to copy
them, in case I make some incompatible change on the PARI website.
Cheers,
Bill