Maxima Plugin - Сообщения
WroteWrote
Due to registring a path to Maxima during setup, SMath is not really portable any more unless you can use the same Maxima path on different systems
[/list]
Thank you very much, Kay and Martin!!
You may want to contact the author of the portable version of Maxima at portableapps.com
http://portableapps.com/node/23391
There is now a workaround to use SMath and Maxima on a portable storage device http://smath.info/bts/Issues/IssueDetail.aspx?id=94
Remaining problems:
- Path to Maxima must be edited by hand in maxima.xml
- X-Maxima must be launched at least once on a given host system in order to create temp directories on the host system (portable Maxima is just configured like that)
WroteI did not managed to make temporary file by starting X-Maxima, and I just made it myself and it works this way.
Radovan, can you please show the output of SettingsDirectory()? Perhaps you do not use portable SMath.
WroteWroteI did not managed to make temporary file by starting X-Maxima, and I just made it myself and it works this way.
Radovan, can you please show the output of SettingsDirectory()? Perhaps you do not use portable SMath.
Here it is. USB Stick is on F: . I started X-Maxima.exe few times (seen on the screenshot) and wxMaxima opened. I just closed it then. As I could see no plot when opening the test file, on the debug window was a message of unexisting X-Maxima temp folder. Just created it manually, and then it worked.
Hmm..., should I run F:\SMath\Maxima\Bin\Maxima\bin\xmaxima.exe ? I run it, it does not help it.
Look at this video please
Anyway, I have to make X-Maxima folder manually.
Regards,
Radovan
Perhaps I found a way to tell Maxima not to use the host system. You might give it a try
Comment out the four lines immediately above the win9x label in maxima.bat
rem if "C:\Users\Kraska" == "" goto win9x
rem if "%MAXIMA_USERDIR%" == "" set MAXIMA_USERDIR=G:\SMath\Maxima\User\Maxima
rem if "%MAXIMA_TEMPDIR%" == "" set MAXIMA_TEMPDIR=D:\tmp\X-Maxima
rem goto startparseargs
:win9x
WrotePerhaps I found a way to tell Maxima not to use the host system. You might give it a try
Comment out the four lines immediately above the win9x label in maxima.bat
rem if "C:\Users\Kraska" == "" goto win9x
rem if "%MAXIMA_USERDIR%" == "" set MAXIMA_USERDIR=G:\SMath\Maxima\User\Maxima
rem if "%MAXIMA_TEMPDIR%" == "" set MAXIMA_TEMPDIR=D:\tmp\X-Maxima
rem goto startparseargs
:win9x
Ha - it works

I also tried your Drw2D3D example. Unfortunately, there are some problems here. I've noted that the graphics files appear inside SMath install folder (not in the file folder - here F:\Temp) but they do not appear in the Worksheet. See the video please. I might missed something here of course.
I also changed the path for Maxima - it is relative path inside maxima.xml now (you deleted the post about it, but I saw it before that

-
-
One more thing. I just used maxima.xml from my regular install because I could not find it on the stick.
Regards,
Radovan
EDIT: I updated the plugins from the the Gallery for USB Stick SMath+X-Maxima. The sample file is Ok, but there might be some mess because Draw2D3D file can not be opened with SMath from the stick - here is the error
EDIT2: I tried some more files with Maxima and draw and USB Stick SMath+X-Maxima. Some of them are Ok and some of them are not. I suppose some time will be needed to stabilize the things.
The file appears when Maxima is first called in the given installation. Updates of the plugin take care of your local settings, therefore, this is normally not an issue.WroteOne more thing. I just used maxima.xml from my regular install because I could not find it on the stick.
You can install Maxima side by side to SMath and use a relative path like ..\Maxima. Thus no need to interfere with the SMath directory.Wrote-
-
Maxima\Bin\Maxima\bin\maxima.bat
I can open and execute the Draw2D3D examples except some of them (using 0.97.5189 both ordinary and portable).
Could you please inspect and show the log messages for failing plots and operations? Just issue MaximaLog() next to the plot.
It seems I figured out something. I used the USB version and wanted to get a plot with the previously saved graph file. It appeared that the formed graph files were saved in the SMath folder but there were no pictures in the SMath Worksheet. When I restarted Maxima, then plots appeared and the plot files in the same folder where the file SMath file resides. Now, after recalculation SVG is reloaded but PNG is not - that was strange. I am not sure this behavior is expected. Anyway, see this video file please. I hope you could see it because I used large portion of the screen.
The same error with your Draw2D3D examples file and the USB version. I could not opened it here on my office computer (Win7 x64) and therefore could not produce Log file. I have the impression that for the moment this portable version on the stick is working quite good.
Regards,
Radovan
- load(draw) is not required, when using Draw2D() and Draw3D()
- when no image file names are given, then the names are randomized and the files reside in a temporary directory in the plugin dir, regardless what the current directory is.
- when image file names are given, then they are relative to the current directory. This may or may not be the directory of the current document. Check or set this using CurrentDirectory().
- You can set the current directory to the document directory using CurrentDirectory(DocumentDirectory())=, that is what I recommend to do when using explicit file names.
- In order to identify the SMath-version and current directory in videos, I recommend to show the output of SettingsDirectory() (which tells portable from standard) and CurrentDirectory()
- I observed problems with the image files. They are not written by Maxima if they are in use by the image region. I don't know, if that is an image region problem or a Maxima problem and when exactly this emerged. If you slightly change the name, then the image is updated. For randomized names, this problem does not occure, because the name changes upon each re-calculation.
@uni: Do you have any idea, what recent change could stop another program to write files that are opened in the image region? If not, we have to search for reasons inside Maxima or inside the plugin.
Edit: The image region is perhaps not to blame. The problem is limited to png files (svg files can be written locally and also be updated when they are open in the image region).
I filed this as issue SS-97 in the bug tracker.
I figured out what happened and I will take care on your remarks. It seems that the *.png bug is a bit problematic. I think that crashes on my office machine happened due to this problem - not sure.
Moreover, I figured out that I had to put:
MaximaControl(restart)=
in order Draw2d() to write files inside document directory, otherwise they will be written in SMath folder.
The command
CurrentDirectory(DocumentDirectory())=
did not help at all.
Regards,
Radovan
installer for Maxima-5.33.0
This version seems to work with SMath including the Draw features.
It seems that png still does not reload
Regards,
Radovan
Changes:
- diff(1) fixed
- extended logging functions, including export to wxm (wxMaxima file)
- New function MaximaDefine() to set variables in Maxima.
- SS-84 implemented. Draw2D/3D now can handle units (expressions with units do not
freeze maxima any more)
- SS-90 implemented. Warnings of float to rational conversions are suppressed.
- SS-87 implemented. Maxima sets can be specified (mainly for use in draw options)
- SS-57 fixed. Names with multiple separators are translated correctly
Plugin Maxima Test.sm (469 КиБ) скачан 97 раз(а).
[albumimg]348[/albumimg]
Everything else seems to be correct.
Regards,
Radovan
WroteJust opening the PluginMaximaTest.sm file. The plot2d was not presented.
it works for me (Maxima 5.30.0)
Best regards,
Davide
That seems to be a path or current dir issue. Has the png file been generated at the location indicated by the plot command? Then, using this path for the image region should do the job.WroteJust opening the PluginMaximaTest.sm file. The plot2d was not presented.
WroteThat seems to be a path or current dir issue. Has the png file been generated at the location indicated by the plot command? Then, using this path for the image region should do the job.WroteJust opening the PluginMaximaTest.sm file. The plot2d was not presented.
You are right. I just used the full path and there is png files saved there. Should it be this way?
Regards,
Radovan
WroteYou are right. I just used the full path and there is png files saved there. Should it be this way?
Definitely not, because this is not portable. Send the sheet to someone else and it will fail. Somehow the current directories in SMath (where the image region acts) and Maxima (where the image is generated) do not match.
Kay and me, we discussed the issue of how to match the paths in a reliable way and we decided to leave everyting that depends on current directory settings in the responsibility of the user. Thus, if you set a relative file name for the image, you must make sure yourself that you find the image.
Normally I find using CurrentDirectory(DocumentDirectory()) or just opening the sheet by doubleclick in the file manager (thereby starting an SMath session with current dir where the file is and a clean new maxima session) being sufficient to avoid path problems.
If you do not need the image as a separate product but just want to display it, then we offer the temporary storage in the plugin dir, using dynamically created absolute paths. If you still badly need matching current directories in SMath and Maxima, then you might file a feature request. However, this might not be easy going to implement.
Regards,
Radovan
-
Новые сообщения
-
Нет новых сообщений