From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: pjb@informatimago.com (Pascal J. Bourguignon) Newsgroups: gmane.emacs.help Subject: Re: [calc] routine tasks in batch mode Date: Fri, 25 Jun 2010 12:11:27 +0200 Organization: Informatimago Message-ID: <87sk4bmng0.fsf@kuiper.lan.informatimago.com> References: <86d3vgqev9.fsf@aiuole.stru.polimi.it> <87fx0cnhwx.fsf@kuiper.lan.informatimago.com> <866317r7ax.fsf@aiuole.stru.polimi.it> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1291839510 19635 80.91.229.12 (8 Dec 2010 20:18:30 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 8 Dec 2010 20:18:30 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Dec 08 21:18:26 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PQQT4-0005Z9-AV for geh-help-gnu-emacs@m.gmane.org; Wed, 08 Dec 2010 21:18:26 +0100 Original-Received: from localhost ([127.0.0.1]:36836 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PQQT3-00025c-Lp for geh-help-gnu-emacs@m.gmane.org; Wed, 08 Dec 2010 15:18:25 -0500 Original-Path: usenet.stanford.edu!fu-berlin.de!uni-berlin.de!individual.net!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 49 Original-X-Trace: individual.net vFo1qSyHpam/ESPp4tF6VAnWXbJfIRyA6Sfewr5gw6SqzC2/mE Cancel-Lock: sha1:ZGFjY2NiYzAyNDdlNzFlYmY4YzVjMzY1MTFjN2M4OWM0YTdjZDIyOQ== sha1:vyOv8TAHfu8gyWTZFxLdCA7jBMY= Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAQMAAABtzGvEAAAABlBMVEUAAAD///+l2Z/dAAAA oElEQVR4nK3OsRHCMAwF0O8YQufUNIQRGIAja9CxSA55AxZgFO4coMgYrEDDQZWPIlNAjwq9 033pbOBPtbXuB6PKNBn5gZkhGa86Z4x2wE67O+06WxGD/HCOGR0deY3f9Ijwwt7rNGNf6Oac l/GuZTF1wFGKiYYHKSFAkjIo1b6sCYS1sVmFhhhahKQssRjRT90ITWUk6vvK3RsPGs+M1RuR mV+hO/VvFAAAAABJRU5ErkJggg== X-Accept-Language: fr, es, en X-Disabled: X-No-Archive: no User-Agent: Gnus/5.101 (Gnus v5.10.10) Emacs/23.2 (gnu/linux) Original-Xref: usenet.stanford.edu gnu.emacs.help:179252 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:75966 Archived-At: Giacomo Boffi writes: > pjb@informatimago.com (Pascal J. Bourguignon) writes: > >> But given that the purpose of calc is basically a four-operation >> calculator [...] > > you are talking of M-x calculator RET, i'm talking of M-x calc RET, > let's try to reach an agreement on the object of the discussion :-) Perhaps as a mid point M-x calcul RET ? ;-) >> It might be hard to give an example of an interactive program used >> in batch... > > i use routinely calc to do different tasks, mostly leveraging its > symbolic algebra abilities > > some of these tasks are suspiciously similar to each other, so i > thought that i can write some support elisp that, e.g., from a file > that contains an high level description of a problem can produce a > file with the problem solution, using in the intermediate steps the > algebraic abilities of calc > > in the fine calc's manual i've found examples of writing and saving > keyboard macros that contain conditionals, loops and user input, and > a description of its elisp API > > clearly i have not understood the whole stuff and for starting i'd > like to read some examples of elisp programs, batch oriented or not, > that use calc elisp API do do their stuff (if such examples exist, of > course: in my OP i said that i was not able to find any on the web) > > i hope that this time i made more clear my question, should this be > the case thank you Pascal for giving me the opportunity of being more > explicit Actually, I understood M-x calc RET; where I may have misunderstood you is when you mentionned 'batch'. I thought about: emacs -batch I wasn't aware it was a symbolic calculator too. This means the hidden part of the iceberg is bigger than just its user interface and makes it indeed worthwhile to try to call up from your own emacs lisp code. -- __Pascal Bourguignon__ http://www.informatimago.com/