[BACK]Return to math2ox.texi CVS log [TXT][DIR] Up to [local] / OpenXM / src / ox_math / documents

Annotation of OpenXM/src/ox_math/documents/math2ox.texi, Revision 1.4

1.4     ! ohara       1: %% $OpenXM: OpenXM/src/ox_math/documents/math2ox.texi,v 1.3 2000/03/14 02:21:40 ohara Exp $
1.1       ohara       2:
                      3: \input texinfo
                      4: @iftex
                      5: @catcode`@#=6
                      6: @def@b#1{{@bf@gt #1}}
                      7: @catcode`@#=@other
                      8: @end iftex
                      9: @overfullrule=0pt
                     10: @c -*-texinfo-*-
                     11: @comment %**start of header
                     12: @setfilename Math2ox
                     13: @settitle Math2ox
                     14: @comment %**end of header
                     15: @comment %@setchapternewpage odd
                     16:
                     17: @iftex
                     18: @comment @finalout
                     19: @end iftex
                     20:
                     21: @titlepage
                     22:
                     23: @title Math2ox
                     24: @subtitle Math2ox User's Manual (English Edition)
                     25: @subtitle Edition 1.1.2 for OpenXM/oxmath
                     26: @subtitle March 2000
                     27:
                     28: @author  by Katsuyoshi Ohara
                     29: @end titlepage
                     30:
                     31: @synindex vr fn
                     32:
                     33: @comment  node-name,  next,  previous,  up
                     34: @node Top,, (dir), (dir)
                     35:
                     36: @menu
                     37: * Mathematica Client Functions::
                     38: * Sample Programs::
                     39: @end menu
                     40:
1.3       ohara      41: @node Starting OX servers,,, Top
                     42:
                     43: @chapter Starting OX servers
                     44:
                     45: @node Starting OX servers on the localhost,,, Starting OX servers
                     46: @section Starting OX servers on the localhost
                     47:
                     48: @c  Description of OxStart
                     49: @menu
                     50: * OxStart::
                     51: @end menu
                     52: @node OxStart,,,
                     53: @subsection @code{OxStart}
                     54: @findex OxStart
                     55: @table @t
                     56: @item OxStart[@var{s}]
                     57: ::  Start the OX server @code{s}.
                     58: @end table
                     59:
                     60: @table @var
                     61: @item return
                     62: Integer
                     63: @item s
                     64: String
                     65: @end table
                     66:
                     67: @itemize @bullet
                     68: @item  It starts the OX server @code{s}.
1.4     ! ohara      69: @item Servers are looked for in the directory $OpenXM_HOME/bin, hoge hoge.
1.3       ohara      70: @end itemize
                     71:
                     72: @example
                     73: In[1]:= Install["math2ox"]
                     74: In[2]:= pid = OxStart["ox_sm1"]
                     75: @end example
                     76:
                     77: In this example, @code{ox_sm1} is started on the local machine.
                     78:
                     79:
                     80:
                     81:
                     82: @node Starting OX servers on a remote machine,,, Top
                     83: @section Starting OX servers on a remote machine
                     84:
1.4     ! ohara      85: In order to connect to remote OX servers, it is convenient, secure and
        !            86: recommended to use @code{ssh} (Secure SHell).
        !            87: The function @code{OxStartRemoteSSH} starts remote OX servers
        !            88: by ssh.  Of course, you are supposed to be able to login the remote
        !            89: machine by @code{ssh} and @code{$Remote_OpenXM_HOME/rc/cshrc} or
        !            90: @code{$Remote_OpenXM_HOME/rc/bashrc} are executed from the login shell
        !            91: of your remote machine.
        !            92: The function @code{OxStartRemoteSSH[]} does not request your password,
        !            93: that is, you need to be using @code{ssh-agent} before calling
        !            94: @code{OxStartRemoteSSH[]}.
        !            95: Then there will be no check of password.
1.3       ohara      96:
                     97: @c  Description of OxStartRemoteSSH
                     98: @menu
                     99: * OxStartRemoteSSH::
                    100: @end menu
                    101: @node OxStartRemoteSSH,,,
                    102: @subsection @code{OxStartRemoteSSH}
                    103: @findex OxStartRemoteSSH
                    104: @table @t
                    105: @item OxStartRemoteSSH[@var{s}, @var{host}]
1.4     ! ohara     106: ::  start the OX server @code{s} on the remote machine @code{host} by ssh.
1.3       ohara     107: @end table
                    108:
                    109: @table @var
                    110: @item return
                    111: Integer
                    112: @item s
                    113: String
                    114: @item host
                    115: String
                    116: @end table
                    117:
1.4     ! ohara     118: We note that the @code{OxStartRemoteSSH[]} is an experimental implementation.
1.3       ohara     119:
                    120: @itemize @bullet
                    121: @item  It starts the OX server @code{s}.
1.4     ! ohara     122: @item Servers are looked for in the directory $OpenXM_HOME/bin, hoge hoge.
1.3       ohara     123: @end itemize
                    124:
                    125: @example
                    126: In[2]:= pid = OxStartRemoteSSH["ox_sm1", "remotehost"]
                    127: @end example
                    128:
                    129: In this example, @code{ox_sm1} is started on the remote machine @code{remotehost}.
                    130:
1.1       ohara     131: @node Mathematica Client Functions,,, Top
                    132:
                    133: @chapter Mathematica Client Functions
                    134:
                    135: The program @code{math2ox} is an external module for Mathematica
                    136: to call OpenXM servers.
                    137: The @code{math2ox} communicates with OpenXM servers by the OpenXM protocol
                    138: and communicates with Mathematica by MathLink.
                    139:
                    140: @c  Description of OxStart
                    141: @menu
                    142: * OxStart::
                    143: @end menu
                    144: @node OxStart,,, Mathematica Client Functions
                    145: @section @code{OxStart}
                    146: @findex OxStart
                    147: @table @t
1.2       ohara     148: @item OxStart[@var{s}]
1.1       ohara     149: ::  Start the OX server @code{s}.
                    150: @end table
                    151:
                    152: @table @var
                    153: @item return
                    154: Integer
                    155: @item s
                    156: String
                    157: @end table
                    158:
                    159: @itemize @bullet
                    160: @item  It starts the OX server @code{s}.
1.4     ! ohara     161: @item Servers are looked for in the directory $OpenXM_HOME/bin, hoge hoge.
1.1       ohara     162: @end itemize
                    163:
                    164: @example
                    165: In[1]:= Install["math2ox"]
1.2       ohara     166: In[2]:= pid = OxStart["ox_sm1"]
1.1       ohara     167: @end example
                    168:
                    169: In this example, @code{ox_sm1} is started on the local machine.
                    170:
1.2       ohara     171: @c  Description of OxSendMessage
                    172: @menu
                    173: * OxSendMessage::
                    174: @end menu
                    175: @node OxSendMessage,,, Mathematica Client Functions
                    176: @section @code{OxSendMessage}
                    177: @findex OxSendMessage
                    178: @table @t
                    179: @item OxSendMessage[@var{pid}, @var{s}]
1.3       ohara     180: ::  send a message @code{s} to the OX server @code{pid}.
1.2       ohara     181: @end table
                    182:
                    183: @table @var
                    184: @item return
                    185: Integer
1.3       ohara     186: @item pid
1.2       ohara     187: Integer
                    188: @item s
                    189: String
                    190: @end table
                    191:
                    192: @example
                    193: In[4] := OxSendMessage[pid, "(CMO_LIST, (CMO_STRING, "hello world"), (CMO_ZERO))"]
                    194: In[5] := OxSendMessage[pid, "(OX_COMMAND, (SM_popCMO))"]
                    195: @end example
                    196:
                    197: In this example, an OX data message
                    198: (OX_DATA, (CMO_LIST, (CMO_STRING, "hello world"), (CMO_ZERO))
                    199: and an OX command message (OX_COMMAND, (SM_popCMO)) are sent to
                    200: the OX server @code{pid}.
                    201:
1.3       ohara     202: @c  Description of OxPopCMO
                    203: @menu
                    204: * OxPopCMO::
                    205: @end menu
                    206: @node OxPopCMO,,, Mathematica Client Functions
                    207: @section @code{OxPopCMO}
                    208: @findex OxPopCMO
                    209: @table @t
                    210: @item OxPopCMO[@var{pid}]
                    211: ::  pop an object on the top of the stack.
                    212: @end table
                    213:
                    214: @table @var
                    215: @item return
                    216: Manual
                    217: @item pid
                    218: Integer
                    219: @end table
                    220:
1.4     ! ohara     221: The @code{OxPopCMO[]} function pops an object on the top of the stack of
1.3       ohara     222: the OX stack machine @code{pid} and returns the object.
1.4     ! ohara     223: The return type of the function @code{OxPopCMO[]} is @code{Manual} in
        !           224: terms of MathLink, that is, an object of suitable type is returned.
1.3       ohara     225:
                    226: @example
1.4     ! ohara     227: In[5] := cmo = OxPopCMO[pid]
1.3       ohara     228: @end example
                    229:
                    230: @c  Description of OxPopString
                    231: @menu
                    232: * OxPopString::
                    233: @end menu
                    234: @node OxPopString,,, Mathematica Client Functions
                    235: @section @code{OxPopString}
                    236: @findex OxPopString
                    237: @table @t
                    238: @item OxPopString[@var{pid}]
                    239: ::  get a string from the OX server @code{pid}.
                    240: @end table
                    241:
                    242: @table @var
                    243: @item return
                    244: String
                    245: @item pid
                    246: Integer
                    247: @end table
                    248:
1.4     ! ohara     249: The @code{OxPopString[]} function pops an object on the top of the stack
1.3       ohara     250: of the OX stack machine @code{pid} and returns a string which is
1.4     ! ohara     251: translated from the object by the OX stack machine.
1.3       ohara     252:
                    253: @example
1.4     ! ohara     254: In[5] := string = OxPopString[pid]
1.3       ohara     255: @end example
                    256:
                    257: @c  Description of OxClose
                    258: @menu
                    259: * OxClose::
                    260: @end menu
                    261: @node OxClose,,, Mathematica Client Functions
                    262: @section @code{OxClose}
                    263: @findex OxClose
                    264: @table @t
                    265: @item OxClose[@var{pid}]
                    266: ::  close the connection to the OX server @code{pid}.
                    267: @end table
                    268:
                    269: @table @var
                    270: @item return
                    271: none
                    272: @item pid
                    273: Integer
                    274: @end table
                    275:
1.4     ! ohara     276: The @code{OxClose[]} function closes the connection to the OX server
1.3       ohara     277: @code{pid}.
                    278:
                    279: @example
1.4     ! ohara     280: In[5] := OxClose[pid]
1.3       ohara     281: @end example
                    282:
                    283: @c  Description of OxExecuteString
                    284: @menu
                    285: * OxExecuteString::
                    286: @end menu
                    287: @node OxExecuteString,,, Mathematica Client Functions
                    288: @section @code{OxExecuteString}
                    289: @findex OxExecuteString
                    290: @table @t
                    291: @item OxExecuteString[@var{pid}, @var{command}]
                    292: ::  execute @code{command} on the OX server @code{pid}.
                    293: @end table
                    294:
                    295: @table @var
                    296: @item return
                    297: none
                    298: @item pid
                    299: Integer
                    300: @item command
                    301: String
                    302: @end table
                    303:
                    304: The @code{OxExecuteString[]} function executes @code{command} on the OX server
                    305: @code{pid}.
1.4     ! ohara     306: The string @code{command} is interpreted in local language of the OX server.
1.3       ohara     307:
                    308: @example
                    309: In[5] := OxExecuteString["print(1+2);"]
                    310: @end example
                    311:
                    312: @c  Description of OxGet
                    313: @menu
                    314: * OxGet::
                    315: @end menu
                    316: @node OxGet,,, Mathematica Client Functions
                    317: @section @code{OxGet}
                    318: @findex OxGet
                    319: @table @t
                    320: @item OxGet[@var{pid}]
                    321: ::  get an object from the connection to the OX server @code{pid}.
                    322: @end table
                    323:
                    324: @table @var
                    325: @item return
                    326: Manual
                    327: @item pid
                    328: Integer
                    329: @end table
                    330:
1.4     ! ohara     331: The @code{OxGet[]} function gets an object from the connection to the OX server
1.3       ohara     332: @code{pid}.
1.1       ohara     333:
1.3       ohara     334: @example
1.4     ! ohara     335: In[5] := cmo = OxGet[pid]
1.3       ohara     336: @end example
1.2       ohara     337:
1.3       ohara     338: @c  Put descriptions of a next function.
1.1       ohara     339:
                    340: @node Sample Programs,,, Top
                    341: @chapter Sample Programs
                    342:
                    343: @tex
                    344: \noindent
                    345: 1.
                    346: {\tt OpenXM/lib/math/primadec.m} is a Mathematica program
                    347: to make primary ideal decompositions by calling
                    348: {\tt ox\_asir}.
                    349: As to usages, see comments in this file.
                    350:
                    351: \noindent 2.
                    352: {\tt OpenXM/lib/math/beta.m} is a Mathematica program
                    353: to get beta-nbc bases by calling {\tt ox\_asir}.
                    354: @end tex
                    355:
                    356:
                    357:
                    358: @node Index,,, Top
                    359: @unnumbered Index
                    360: @printindex fn
                    361: @printindex cp
                    362: @iftex
                    363: @vfill @eject
                    364: @end iftex
                    365: @summarycontents
                    366: @contents
                    367: @bye
                    368:

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>