Actual source code: mathematica.h
1: /* $Id: mathematica.h,v 1.2 1999/06/01 20:45:51 knepley Exp $ */
2: /*
3: This is the definition of the Mathematica viewer structure.
4: */
6: #include src/sys/src/viewer/viewerimpl.h
7: #include petscsys.h
8: #ifdef PETSC_HAVE_MATHEMATICA
9: #include "mathlink.h"
10: #endif
12: typedef enum {GRAPHICS_MOTIF, GRAPHICS_PS_FILE, GRAPHICS_PS_STDOUT} GraphicsType;
13: typedef enum {MATHEMATICA_TRIANGULATION_PLOT, MATHEMATICA_VECTOR_TRIANGULATION_PLOT,
14: MATHEMATICA_SURFACE_PLOT, MATHEMATICA_VECTOR_PLOT} PlotType;
15: typedef enum {MATHEMATICA_LINK_CREATE, MATHEMATICA_LINK_CONNECT, MATHEMATICA_LINK_LAUNCH} LinkMode;
17: typedef struct {
18: #ifdef PETSC_HAVE_MATHEMATICA
19: MLINK link; /* The link to Mathematica */
20: #endif
21: char *linkname; /* The name to link to Mathematica on (usually a port) */
22: char *linkhost; /* The host to link to Mathematica on */
23: LinkMode linkmode; /* The link mode */
24: GraphicsType graphicsType; /* The system to use for display */
25: PlotType plotType; /* The type of plot to make */
26: const char *objName; /* The name for the next object passed to Mathematica */
27: } PetscViewer_Mathematica;
29: EXTERN int PetscViewerMathematicaSetFromOptions(PetscViewer);
31: EXTERN int PetscViewerMathematicaSetLinkName(PetscViewer, const char *);
32: EXTERN int PetscViewerMathematicaSetLinkPort(PetscViewer, int);
33: EXTERN int PetscViewerMathematicaSetLinkHost(PetscViewer, const char *);
34: EXTERN int PetscViewerMathematicaSetLinkMode(PetscViewer, LinkMode);