greatspn / SOURCES

Main repository of the GreatSPN framework
GNU General Public License v2.0
42 stars 13 forks source link

libgmp on mac #47

Closed yanntm closed 1 year ago

yanntm commented 1 year ago

Dear GreatSPN team,

I was trying to demonstrate GreatSPN on a mac (to a competent in Petri but not particularly command savy user), after some brew configuration to get brew install graphviz working, and fiddling until the machine would let us run this "untrusted" application, almost everything worked except the RGMEDDLY engine, it complains about missing "libgmp.so". I don't know whether there is a brew install libgmp-dev that could solve the issue, perhaps slipping some -static or -all-static in the LDFLAGS would be a better idea.

Demo was quite convincing, the GUI is really good looking with the latex, we just had trouble with the initial marking syntax for WN, I found in a paper by Elvio a screenshot that gave me syntax <All>.

I was trying variants of <C0> (which does not show as error in GUI, but raises an error at analysis) or S C0 (S for diffusion but that raises errors already in GUI)

The Readme on this page however does not point to documentation for the syntax of WN in the tool; that would be useful to have. Or perhaps a small set of downloadable examples that we could browse would have been enough, maybe with syntax examples also for more complex formulae. I don't believe the basic .dmg carries any of those (?).

amparore commented 1 year ago

Not sure about the first problem, without more details. Did you tried to compile it from sources, or did you used the precompiled binaries? Are these the latest versions? brew install gmp should be enough, but it should not be needed, and therefore such request is probably a bug. Can you give me more details about the raised error?

For the sample models: they are bundled with the Editor. Once you create a project, you can import one of the library models. Just click on the "New page" button (second from the left on the toolbar), then "Add library model". There are 7 CPN/SWN example models, which cover most of the supported syntax of the colored nets.

For the grammar: "Help" > "Show grammar" shows the rules used by the expression parser.

Yes, some SWN features are supported by the editor, but not all solvers are capable of handling them. For instance, an initial marking with a single named color can be drawn, but it cannot be used by the standard legacy SWN solvers.

yanntm commented 1 year ago

I used the .dmg from your download page, osx x86_64 arch Yes I thought it was probably better not to have more brew commands for gmp if it can be avoided, hence the main point of this "issue". The rest is just feedback I guess. Thanks for the pointer to the examples and help menu, I was looking for something like that but could not find it during the demo. As a last point, the first hit on google for "GreatSPN" was the di.unito page that does not obviously point back here, and adding "manual" pointed to a GSPN 2.0.2 document not really current. I pointed your nice 2022 paper as reference for tool capabilities (maybe add a ref to that to your readme.md ?). Still it was really easy to demo most of the features, the "Basic toolbar" with the graphical syphon/trap/invariants are really useful to start with, and the colored token game is super natural to use.

amparore commented 1 year ago

Yes, the gmp/gmpxx libraries were missing from the portable distribution, and this is fixed now. Thank you for noticing that. Yes that manual does not point to the modern GreatSPN net format, and it should probably be removed.

yanntm commented 1 year ago

Thanks a lot, a bientot :D