Guess I goofed!
I should have mentioned I was running Maxima on Win32 using Pentium IV
amd XP Pro. Last year I debated whether to go Linux or MS Win32 and
went with the latter (MS Win32). because of some advantage and now also
because of the work I want to do with TI 89 Titanium. Eventually I will
go Linux but can't do that right now.
Anyway, my questions should have been understood in that context.
The last response I received indicated that I should do certain things
with xmaxima which is one of several packages used on the Linux OS. The
reply indicated doing certain things with the Source Code and then
rebuilding. I will bear that in mind when I get over to Linux but I
thought I would look at the source code anyway. I looked at the CVS and
I looked at the download page. What I found was as follows.
(1-src) The CVS repository only shows a list of the modules -- mostly
Lisp files.
(2-src) The download page lays out binanry and source where a clear
distinction is made between Linux (in the form of rpm files) and Win16
exe file which self installs. The only file I can see on the download
page which might be used for building the Windows executeable package is
"maxima-5.9.3.99rc1.tar.gz" which is the same for both candidate
listings. Upon looking into "maxima-5.9.3.99rc1.tar" I found a lot of
.mac files and the remainder were mostly lisp files (probably the ones I
saw on CVS.
(3-src) Is "maxima-5.9.3.99rc1.tar.gz" the source code for building the
self installed Windows executeable????
If so then I don't think the help I have received so far addresses my
points (1) to (5) given that the last advice relies on a collection of
Linux files not found in "maxima-5.9.3.99rc1.tar.gz". Much of the
documentation I encountered also assmes or specifically states that it
applies to Linux. Yet (in the download section) this file is marked ANY
and so also are the Linux source file collection so marked as ANY. But
the Linux files clearly make provision for the Linux OS and those same
provisions (like xmaxima) don't seem to appy to Windows OS. In
"maxima-5.9.3.99rc1.tar.gz" I think I saw a large group of script files
which may be providing the interfacing about which I have been wondering
and asking questions.
Can we first clear up this present confusion I have regarding source?.
(4-src) With regards to a Windows build -- how do I go about it -- are
there instructions somewhere specific to a Windows build? Could I do
the build using CYGWIN?
(5-src) I assume I have to uninstall the present version before letting
the self installing Windows binary execute? This gets me back to TCL.
The present installation came with TCL so I ended up having TCL (from
CYGWIN), TCL from KOMOTO and TCL from an independent install.
Back to my initial points (1) to (5) where Windows is the current platform.
I really need to know what TCL functionality (in the form of language
syntax )is used to evoke Maxima.(as the last explanation I received was
looking at this from a Linux standpoint). The last explanation did
indicate the presence of a TCL script which I believe is found in
"maxima-5.9.3.99rc1.tar.gz". If so is the script executed by TCL
without any arguments or are variables set up to use the script or what
or does anyone really know? Somehow TCL has to know about this script
or whatever else is required in order to instigate opening a socket to
be shared by Maxima. so that an effective channel for data transfer is
created allowing Maxima to repond back to the TCL program with the
results. Whatever operation TCL launches to transfer data to Maxima must
also notify Maxima regarding the socket as well as transfer the Maxima
code imbedded in the TCL. Here is a make believe answer.
MAKE BELIEVE EXAMPLE and MAKE BELIEVE COMMENTS
"create_transfer_through_socket arg=Maxima arg1=socket_designation
arg3=Maxima_code_to_execute arg4=pathway"
Comment: The imaginary function "create_transfer_through_socket" is a
TCL built in function which sets up a data transfer path as a string
which based on the arguments evokes the Maxima engine which executes
the string and returns the result through the socket to the TCL program
which results then appear beneath the Maxima code imbedded in the TCL
program. The imaginary function "create_transfer_through socket" needs
to be executed only once during the TCL programs execution (ie, the
socket remains OPEN). Thereafter, when ever a Maxima script is
encountered the socket transport is utilized. The TCL recognizes the
Maxima script because it is tagged according to a TCL convention with is
%%*"this is a Maxima script". The arg3=Maxima_code_to_execute would
therefore be arg3=%%*"this is a Maxima script". The actual interface
code might look very different from this imaginary example.
That's the sort of thing I am looking for -- a very clear and detailed
example and relevant comments telling me how to code TCL to manage a
data transfer between TCL and Maxima and how that code facilitates the
transfer. The above is just an imaginary example of something about
which I know very little or I would not be asking the question. This
is what I mean by asking for the syntax needed to effect such a transfer.
Hope this imaginary example clarifies exactly what I am looking for on
the Windows platform.
I really appreciate the effort of those that have tried to help. Also,
I apologize if I have missed your points but I really need the answer in
a form similar to the imaginary example and with the imaginary comments.
Thanks again -- looking for the real syntax and appropriate comments per
the imaginary example format that I provided.
-------- Original Message --------
Subject: Re: [MAXIMA] Extending functionality
Date: Sun, 06 Aug 2006 16:50:55 -0600
From: Ted Hilts <thilts33 at telus.net>
Reply-To: thilts33 at telus.net
Organization: help-for-you.com
To: Robert Dodier <robert.dodier at gmail.com>
CC: maxima at math.utexas.edu
References: <44D3AB2A.5070506 at telus.net>
<eb9c4b9a0608050926p34c35252rfde523e54e6d9030 at mail.gmail.com>
Robert
Thank you for you informed answer. You are very analytical and organized
in your thinking so I will try my best to clarify my actual purpose by
providing you sufficient relevant information.
You are correct in saying that I have not made my objective clear.
Sorry. I only realized that when I caught the nature of your response.
Initially (1) I simply want to be able to code in TCL and make it
possible to evoke from TCL Maxima programming and mathematical functions.
Also, (2) I would like to code in Maxima and make it possible to evoke
TCL functionality. But (2) is not as important to me as is (1).
(3s) Essentially, I want to code from a TCL IDE (which I suppose would
be the TCL console) executing TCL files which evoke Maxima programming
files and Maxima mathematical functions. I am interested in both
execution fromTCL files (batch) and TCL interactive.
(3b )However, I read in an article where the author claimed to run
either or both (I'm not sure now) TCL and Maxima from an editor. This
apparently gave him the abiltity to both edit and run programs in this
editor environment which he compared to the Maple live spread sheet
where one could both code, edit, execute as well as remember prior
actions, etc.
(4) That got me really excited. I said to myself, I should be able to
run an editor (like Emacs) within the TCL console or batch file and
within that editor set up TCL evoking Maxima functionality. So my
objective widened from simply using TCL to Maxima interaction to that
interaction involving an editor.
(5) is the crux of the issue I was trying to get help on.
(5) But my basic problem with all of this is understanding how to set up
TCL to provide a data channel between itself and some other environment
like Maxima or Maxima (hopefully in combination with an editor like
EMACS ). That is, HOW (what are the TCL language elements and language
sytax that enables these channels). And what conduct does that evoke on
the Maxima end of things. In other words I need to know how to code in
TCL the interfacing process. Not the actual evoked Maxima control and
mathematical functions and programs but rather the code that enables the
transfer process between TCL and Maxima engines which I call Programming
Environments.
DETAILS: But life got complicated as soon as I asked my self HOW TCL
actually evokes Maxima functionality. I have read the information
available on Maxima and TCL (obviously not all of it for I seemed to
miss some information). In the process of discovery I discovered there
were a number of seemingly differen't ways to interface TCL and Maxima
and one article indicated that socket interaction was generally the way
to go and another indicated that a text based TK widget was one way to
go (which did not involve sockets) and another indicated that one could
build a "proc" and actually provided one. Some examples were given that
had assumptions in that they lacked sufficient detail for me to
understand the actual interfacing between TCL and/or PHP. I got the
notion that much of this was still in the exploratory stage. But then I
discovered an interesting article about audio signal processing that
involved PHP or TCL (don't remember now) interfacing with Maxima. In
all of this the actual interfacing seemed vague -- maybe because I am
still getting used to the TCL and Maxima functions and their useage. The
TCL handbook does not specifically address interfacing TCL to Maxima, in
fact the author of the TCL book had never heard of Maxima until I
contacted him about a year ago.
Basically I was looking for solid or reliable way or ways of programming
in TCL as super structure code that evoked Maxima functionality. And I
was excited about this editor environment acting as an IDE. What I had
missed in my surfing through the documentation, wikis, tutorials and
other documents was HOW (in terms of TCL language syntax and functions
involved) TCL evoked the desired Maxima function. or Maxima batch file
(containing a Maxima program which could serve as an evoked function).
I did come to understand that TCL had to first evoke the Maxima engine
(you guys call it engine and I call it the programming environment).
However, it seemed that before TCL could do this evoking it first had
to be set up using some built in functions (for that purpose) and/or
control syntax which apparently enabled data to move between TCL and
Maxima "engines" or what I call the respective Programming Environments.
After that is done (this mysterious set up) then one simply imbeds the
Maxima syntax embedded within the TCL coding. This seemed to be what
some of the examples were saying. "Now just pop in the Maxima control
and functional code". Or is the set up functionality repeated for every
time a Maxima function is evoked. It seemed lke the former was the
case. Both sides of this data path (TCL and Maxima sides) utilize a
process that is socket centric in character. That does not tell me how
to code the transfer. But knowing this I still don't know how to code
sytactically using language elements and make this mysterious set up to
enable that data exchange between the two programming environments.
That is what I missed, it's probably in something I read but I missed
it somehow.
Maybe I should have hacked around but that takes a lot of time and my
internet connection is very slow which makes hacking very slow. Hope
you can help me on this.
BTW:
I have not told you everything. Once I get all this together and
understand the syntax and language elements and how they facilitate the
interfacing between TCL and Maxima I want to integrate this scenario
into TI 89 Titanium. TI (Texas Instruments) has provided a development
IDE (with Motorola 68000 modified C and assembler) having a simulated
(virtual) calculator for both the TI 89 as well as the TI 92. I think
if I can get my act together I ought to be able to independently operate
the TI IDE so it talks to the TCL programming environemnt (interactive
with the Maxima programming environment) and vise versa by means of
serial communications. In otherwords I can use their virtual (they say
simulated) calculator to talk to my TCL IDE. I can do this because the
TI IDE has an OS (68000 based) and I can created (using C produced
assebler) packages called APPS or FLASH packages and make that
calculator do anything I want. This means I can bypass the proprietary
transfer protocal designed to LOAD the TI IDE developed APPS and FLASH
modules and deploy my transfer protocal into the TI real Calculator or
virtual Calulator or another computer. Neat eh?
Right now though my objects is first (1) above down to (5).
I'm pretty sure my problem is somewhat elementary now that I have
clarified things for you.
Thanks again and I am looking forward to your reply.
Ted Hilts
I need to understand what I would be doing. As I said I am not yet
competant enough with TCL or Maxima to recognize certain function's
behavior or the character of that behavior. So I probably missed what
would have been obvious to someone such as yourself.
Robert Dodier wrote:
> Ted,
>
> About calling other programs from Maxima and vv,
> that is possible but somewhat problematic. Be that as it may,
> several GUI's have been created as separate programs.
> See http://maxima.sourceforge.net/relatedprojects.shtml for a list.
> In every case (so far as I know) the GUI front end talks to
> Maxima via a socket. The difficult part of that approach is that
> it is hard to know when Maxima has completed a computation
> or if it is waiting for more input. There is an assumption in the
> Maxima code that there is always someone sitting at the
> console. I am considering ways to weaken that assumption
> but the problem is nontrivial.
>
> Aside from working with sockets, there is also the possibility
> of using a function call interface. It is trivial to call Lisp
> functions from Maxima -- if myprogram.lisp contains
> a function FOO then load("myprogram.lisp"); ?foo();
> is enough. myprogram.lisp can also call Maxima functions.
> There is more about Lisp & Maxima in the reference manual.
> See "Lisp and Maxima" at
> http://maxima.sourceforge.net/docs/manual/en/maxima.html .
> ? lisp at the interactive prompt should find the same text.
>
> Calling C or Fortran is theoretically possible but more work,
> as it would require using a so-called foreign function
> interface for Lisp. There is not yet a FFI which works for
> all Lisp implementations, although there seems to be
> at least one active project for that. Fortran functions can
> be translated into Lisp via f2cl, see:
> http://clocc.cvs.sourceforge.net/clocc/clocc/src/f2cl
>
> Maybe you can tell us more about what you want to do,
> then we could give some more specific advice.
>
> All the best,
> Robert Dodier
>