From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: arthur miller Newsgroups: gmane.emacs.devel Subject: Re: as for Calc and the math library Date: Mon, 12 Aug 2024 05:30:08 +0000 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="_000_DU2PR02MB101093A78B629F65CF87218ED96852DU2PR02MB10109eu_" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26314"; mail-complaints-to="usenet@ciao.gmane.io" To: "emacs-devel@gnu.org" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Aug 12 12:47:32 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sdSaI-0006hg-Pw for ged-emacs-devel@m.gmane-mx.org; Mon, 12 Aug 2024 12:47:31 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sdSZf-0003sb-Vu; Mon, 12 Aug 2024 06:46:52 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sdNiA-0000qx-Au for emacs-devel@gnu.org; Mon, 12 Aug 2024 01:35:18 -0400 Original-Received: from mail-vi1eur05olkn20801.outbound.protection.outlook.com ([2a01:111:f403:2e13::801] helo=EUR05-VI1-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sdNi8-0006oU-Gc for emacs-devel@gnu.org; Mon, 12 Aug 2024 01:35:18 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=hWPcD9rCHeciRKOS0XVKRBKi6dPQ7Mu0v6+sNNqMBy9t9B0P+BoFby88SdJWgacyhMl7MGQV7hl1Cq3W3iJ6AwM0vYfiBYHx679/u/h+wMwIN/Ow5GQQburdo4W3u3ZU7yEhtYZlXz6DsqY/h4g6V1Hcl8lKugf71+y1tDKE8oQ2CP41EuXa34ZbOrECw6xQxEexKc3svZW5LdezGeviglSFi2mEFV/67NWDlP2mCMHrfQcuh8EQwnaXSHr15mxpff/HnSMTkqD5U4lMLheoXXear5ddE48g92O7nF7Bu2+Tyg3mH7Zxr2Au+1SPj4kpf+t3mTTjwWdE9bscmRG2qA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=DlemCWzXqjkK3SSG7i9eSXWjFtCObMH4FUxodZRY7yM=; b=OhP0nCyIMIzYwXYqm/XTwtWeuyMp28W2XfHdcNMkQSTyqyKPrquENhqAVlK4nLkkMswfWVj7Ujf/UrwpBvMXUWHlhE92X7hfhofQAAOj4vpOSqQYc47B9TfQf6Fx7SOkxaAyGo6T/Dl2htTJMAfGWFk4ciw+CHH17c71wSQj9/NBXiH6qJjYdow34LaNhzs/Jj/k90sy193p5yzQxH9YrbdJcJrc/dO02mGPGLoPyMxMW4fOY8qdvn2POIx7Wn5c/NT5BVDVjwwQolCA79qmioMTodIIPOo/uK/MpDZ5N+rfRsd0wDMFVbl+EObUTSE9iH2Tw2Re1bl7JVnbAGsWlw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=live.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=DlemCWzXqjkK3SSG7i9eSXWjFtCObMH4FUxodZRY7yM=; b=i8nP26xRz943/2swf7pQYAwLEQfornNsT9opI4WTqa67BkBhcL8TTuyBeG61Yz8QGlj+J/IPtMgQsOvgsoCYtPvD5TE8vlH+WcEX25NL0wbOVx+NC2wdlQVcgt7hmCtyly28Ry2UBEtl+EJdLEUv3yz89o5IJhAtyGQEy0CvnBEFzaVP34QsJ6z3wPqwfHNrOnBCqnbqlKEs4H/z08SdC4WqX/6dumjErXEoSsqzY1QxOZJoVyHtKA2fkLcmLhRqkE6uUKJKy12RszdLdtS+xq0uTPDcOn8lt7m7c0msjl08Zzx4uO1ckjIKIIrXa+bMU+cEekWFEn3q5hKWVCTuPA== Original-Received: from DU2PR02MB10109.eurprd02.prod.outlook.com (2603:10a6:10:497::14) by VI1PR02MB10200.eurprd02.prod.outlook.com (2603:10a6:800:1ce::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7849.20; Mon, 12 Aug 2024 05:30:08 +0000 Original-Received: from DU2PR02MB10109.eurprd02.prod.outlook.com ([fe80::f3c9:d4cb:290:d487]) by DU2PR02MB10109.eurprd02.prod.outlook.com ([fe80::f3c9:d4cb:290:d487%4]) with mapi id 15.20.7849.019; Mon, 12 Aug 2024 05:30:08 +0000 Thread-Topic: as for Calc and the math library Thread-Index: AQHa7HhyCr4HNzb0tkSg9b4Ke04UmQ== Accept-Language: sv-SE, en-US Content-Language: sv-SE x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [gjhMAfh+Agk18EMIXrWRh++jJQnmRERa] x-ms-publictraffictype: Email x-ms-traffictypediagnostic: DU2PR02MB10109:EE_|VI1PR02MB10200:EE_ x-ms-office365-filtering-correlation-id: 4e556ab4-3228-4632-8b32-08dcba8fd437 x-microsoft-antispam: BCL:0; ARA:14566002|15030799003|15080799003|19110799003|8060799006|461199028|3412199025|440099028|102099032; x-microsoft-antispam-message-info: o4/o2jO/5s0/wo7gZ2aKxt/nWQPM/tvCfHm6KC/fNrU2wnG8ki9AbWyE2sFtIzvs6jxuNxc8eD+aK5g2fbfO8FwjRAhb1GQ0+AENJWM1nC2oERhm1/YPhgU9JqKzFtmr71m+7Rx9p186+Tw43fftZevk8p8OEtFZvos2PXoQiGDE9r5WoZTm90lmIimrZ5Ci8SWHXiw2DlurINVYOEN/PI9DpAMt38hAKeQogXHsMHuii3moSnogImUB1Ks3tauNDVs04R0in7R92iVJ1K+19cZno7qZ03czhJsLuv7BPB9c+DvixWT9Wnmgr65+6p1dnyAn/W/E01Uf+AVH/jafh3NXEZlwFNMrkkGcTiHXFKXxJS85miUySM+sE08hzXzUDU941ac4kVRan9dyHqIK1dFpJ+Y/DTuah6HHpLUNjxdLWvZ+vkXFxf95TgsUee3qNQXsjPPNWud0HIyXpN1d4gkU6+WUX6MJzOmx50X9B6/gRcil9vLkh4HESufDiYWVPJ6+1owcDnVoalur++K70m96xnehmz+7J1SPQRTShsUTIU89/MPkn+mYI3op+Yli4AeXbbtyXerDRUXyB5G+TSdmPGRN7WFrPUz+2Tofq1DYt+FkTga9qobuxxtZO5j2D9hS/jj+Zn/pHBWhEH1lWlOulLSGAqMWAjJWjdxXOglSy8jxx4gtLSaXMCna7yRTTdRDaRPpA01M2vK013QQTg== x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?iso-8859-1?Q?QRAyNuQLTRxZa4Ihy8wySY5dQ1soat7rbJJtMfjQ4FbMBcol6O7zA2GB+m?= =?iso-8859-1?Q?EAuk7MB2kC+IMATTCVHzyewZGcFDKem3HYWto2uNKzUW2YHFDi8Gd+P9NF?= =?iso-8859-1?Q?FWXQGaYCbt9ypZdxf7qxMesUSnauTCjWzGrZciOIsgoa9mLVZ/TbmmQkWk?= =?iso-8859-1?Q?h4/+5eVqjHDRmw40UE+r6eKP7efvlZLDURe6SfkhNwL4Isz+bOsPFLSOEh?= =?iso-8859-1?Q?CNEVvLdA1KhqTGqGeqEg8HB+dd83vdU8RQr1Fb8VnQoSGXsuTa0uYhVm5y?= =?iso-8859-1?Q?X9pG4/xmeNrLNE96E6AIgHDKqNR9K/cAzWUjHIqkVcy3MslNmrRiNuAFas?= =?iso-8859-1?Q?heDi/PE6xQhDsrtnVeLogwJnOwQeCSAODEr8jJKcfEz95dFVMMMHL123Zx?= =?iso-8859-1?Q?v8E0H2z2Apqe51bsNmYwCJYglICVY6KtPicwwk8iPvyB86n+Z8uvaTvXNG?= =?iso-8859-1?Q?2sWLf6DSDmzuVoFSP3TUcsI4O4/Yx5Nd4n1cVjE2FLjm443fQZmN7sepDE?= =?iso-8859-1?Q?qnybx3J0JpiS9MVGA7DTZFDtpgdy6rTsLlLh+CbFB6g/Y66i5NYwuwyIkt?= =?iso-8859-1?Q?nhR+XyKG8R4ABw9LEXBEz3CKTmZf12PfpyLdRTTOKGbrCFbE/LBVmtDViA?= =?iso-8859-1?Q? X-OriginatorOrg: sct-15-20-7828-19-msonline-outlook-12d23.templateTenant X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: DU2PR02MB10109.eurprd02.prod.outlook.com X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-Network-Message-Id: 4e556ab4-3228-4632-8b32-08dcba8fd437 X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Aug 2024 05:30:08.3253 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-rms-persistedconsumerorg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR02MB10200 Received-SPF: pass client-ip=2a01:111:f403:2e13::801; envelope-from=arthur.miller@live.com; helo=EUR05-VI1-obe.outbound.protection.outlook.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Mon, 12 Aug 2024 06:46:50 -0400 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:322659 Archived-At: --_000_DU2PR02MB101093A78B629F65CF87218ED96852DU2PR02MB10109eu_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable > > If Emacs is to have a math library, the library must use high-quality > > mathematical and numerical algorithms that are well-known and > > described in many textbooks on this subject matter... > > I agree with this point, but I suspect that writing such a library from > scratch might be a bit difficult. > > May I suggest an alternative: abstract out GNU Calc math routines to be > available from Elisp without having to read Calc sources. > Such a task would require: > 1. Documenting some Calc data structures > 2. Possibly refactoring some Calc functions to use simpler API. > > It would be a much easier task and can improve the existing > functionality. Even better, given people proper FFI so they can import and use any of the = tens or hundreds of quality math libraries available. That would also help to keep C core smaller, and relieve the dependency on = core devs to add bindings to future libraries when users want or need them. A third of Emacs C core could have easily been implemented by users if they= had proper FFI exposed to Lisp instead of C modules which very few people use. --_000_DU2PR02MB101093A78B629F65CF87218ED96852DU2PR02MB10109eu_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
> > If Emacs is to have a math library, the library must use high-qua= lity
> > mathematical and numerical algorithms that are well-known and
> > described in many textbooks on this subject matter...
>
> I agree with this point, but I suspect that writing such a library fro= m
> scratch might be a bit difficult.
>
> May I suggest an alternative: abstract out GNU Calc math routines to b= e
> available from Elisp without having to read Calc sources.
> Such a task would require:
> 1. Documenting some Calc data structures
> 2. Possibly refactoring some Calc functions to use simpler API.
>
> It would be a much easier task and can improve the existing
> functionality.

Even better, given people proper FFI so they can import and use any of the = tens
or hundreds of quality math libraries available.

That would also help to keep C core smaller, and relieve the dependency on = core
devs to add bindings to future libraries when users want or need them.
 
A third of Emacs C core could have easily been implemented by users if they= had
proper FFI exposed to Lisp instead of C modules which very few people use.<= /div> --_000_DU2PR02MB101093A78B629F65CF87218ED96852DU2PR02MB10109eu_--