Questions tagged [packages]
Questions on Mathematica packages, which are self-contained bundles of Mathematica code that add new functions and other functionality.
883
questions
4
votes
0
answers
110
views
Packaging and Distributing Mathematica Code
I am trying to distribute my Mathematica Code in the form of a package. It can be compiled to a single file, numerous functions. So, I created the following directory structure:
...
4
votes
2
answers
158
views
Help with using the flux balance analysis tool SNA of R. Urbanczyk
I would like to call a function from the SNA package at https://www.bioinformatics.org/groups/?group_id=546, but this doesn't work, and the email of the provider doesn't accept messages. Trying to ...
0
votes
0
answers
63
views
Function in package not evaluated and loaded
I have a short Mathematica package that I update with new functions every now and then. Up to now, this was never a problem and every new function would work without any problems after I reinstall the ...
4
votes
2
answers
189
views
Why does Mathematica says it didn't create a context when Needs was evaluated but it does?
In Mathematica 14.0.0 (MacOS Sonoma 14.4.1) I made a simple package consisting of two "sub packages". One of them is loaded as "private" from with the main package:
The package ...
2
votes
1
answer
127
views
Mathematica package for validating effective string theory solution
I am asking for Mathematica package that given an input of:
symmetric matrix $G_{\mu\nu}$, antisymmetric matrix $B_{\mu\nu}$ and a scalar function $\Phi$
will check whether it is a solution to the one-...
2
votes
0
answers
37
views
How to make small package (new style) in notebook for testing?
Sometimes it is easier to test package inside notebook without having to make .m file and read it each time. This can be done using the official package style like this
In new cell we type
...
2
votes
1
answer
62
views
Trying to reproduce the behavior of Graph objects with visual representation
I am working on a package dealing with a specific type of object that has a visual representation, so I'm trying to reproduce the behavior of the Graph objects in Mathematica. By that, I mean that ...
0
votes
0
answers
15
views
How can I force ParallelNeeds on Remote Kernels to load custom package from local machine?
I am running serial computation using 4 of 8 cores on my local Windows machine and 56 of 60 cores on a remote Linux machine:
...
6
votes
1
answer
232
views
On the new package style. Conflict using the same name in the parent and in the child packages
I am learning the new package style as current one is not working for me. I know it is probably not a good idea to use something with no official Wolfram documentation and not officially released. But ...
4
votes
2
answers
218
views
How to keep private package function private when adding package name to function name inside the package?
I like to call my package private functions using
mypkg`functionName[...]
i.e. add an explicit mypkg to each call. This ...
3
votes
1
answer
101
views
How to make my OOP class work inside a package?
I like to use this simple OOP setup in Mathematica that I learned from reading posts here over the years and playing around with it. This makes a Class and implement basic OOP (nothing fancy like ...
1
vote
1
answer
364
views
Gillespie (stochastic simulation) algorithm
I want to apply the Gillespie algorithm to a set of reactions. First, I run the source code presented here, and then run my model:
...
4
votes
2
answers
250
views
How do packages handle local variables?
According to the documentation "$Context is searched after $ContextPath,"
That means that when you define variables ...
2
votes
1
answer
85
views
Package function doesn't plot math function when given as input
I'm new to Mathematica and I'm trying to learn to write some basic code to create a DialogInput in which the user writes the function to plot.
I'd like to ...
1
vote
0
answers
100
views
Need help to install a package in Mathematica [closed]
today I just downloaded the trial version of Mathematica for 15 days. I am completely new to CAS (Computer Algebra System) and have never used any CAS before, so I am not able to express everything. ...