Skip to main content

Questions tagged [packages]

Questions on Mathematica packages, which are self-contained bundles of Mathematica code that add new functions and other functionality.

Filter by
Sorted by
Tagged with
2 votes
0 answers
75 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
1 answer
84 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
1 answer
120 views

Variables in a Package

If I do this: func1[x_List] := Apply[Plus, x]; func2[x_List] := Apply[Plus, x^2]; func3[x_List, y_List] := Map[(fun1[x] # - fun2[x] #^2) &, y]; ...
2 votes
1 answer
59 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 ...
2 votes
0 answers
34 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 ...
0 votes
0 answers
12 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
225 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
216 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 ...
1 vote
1 answer
359 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: ...
3 votes
1 answer
99 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 ...
4 votes
2 answers
245 views

How do packages handle local variables?

According to the documentation "$Context is searched after $ContextPath," That means that when you define variables ...
10 votes
3 answers
712 views

Why do people split packages in different files?

I am writing (it is my first time) and I don't understand why packages usually come in different files. I saw people saying that this is a modularization strategy, i.e. different files for functions ...
2 votes
0 answers
95 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. ...
2 votes
1 answer
51 views

Trouble installing the package MultipleZetaValues

I have tried to install the package MultipleZetaValues using ...
5 votes
1 answer
117 views

How to make "Get Help" entries for custom package?

I've got a small collection of Mathematica tools that I'd like to make into a package. One of the nicest features in Mathematica is the ability to right click on any built-in function and just select &...
5 votes
2 answers
170 views

How do I format the `expr` in the `::usage` message of functions in a mathematica .wl package (without using Workbench)?

This probably has an easy answer but I can't work it out. In Mathematica's documentation, the ::usage message has some text formatting for expr. In the ...
2 votes
0 answers
85 views

How to effectively substitute variables in xAct?

I am trying to find the gauge field equation by varying the Born-Infeld Action with the help of xact package. I use the following ...
1 vote
0 answers
52 views

Why I can't install this package [closed]

I am trying to run C++ in Mathematica. I got a package "LTemplate" from the answer from Szabolcs in this post: How to simplify writing LibraryLink code?. However I can't install it. This is ...
0 votes
1 answer
60 views

HypExp package throwing errors when loading

I am trying to load the package HypExp by using the instructions given on the site. The package throws an error ...
2 votes
1 answer
84 views

Defining custom operators for indexed objects [closed]

I have some symbolic indexed objects $A_i$, $B_{ij}$, $C_{ijk}$, $D_{ijkl}$, etc. I want to define a symbolic differential operator $\partial_{xy}$ that acts on these indexed objects in the following ...
3 votes
1 answer
120 views

Varying Einstein-Hilbert action through xAct gives extra terms

I am trying to find the associated field equation by varying this action: $$S=\int d^4x \sqrt{-g}(\kappa \mathcal{R}+\Lambda)$$ This should give me the below field equation when I vary above w.r.t the ...
21 votes
2 answers
1k views

How to download "ResourceFunction" packages onto a notebook, so I can place it in a USB and access it on a different computer

So I want to use "ResourceFunction" commands, but that requires internet, as it needs to retrieve it from the wolfram cloud. However, I want to access a number of them (such as, ...
0 votes
0 answers
24 views

How to define multiple folders for JLink in PacletInfo.wl file?

I have a paclet info file setup as follows: ...
0 votes
0 answers
59 views

Can IntelliJ be made to look like notebook?

I am developing a package for my company, which has grown into multiple sub-packages. I have been using the notebook frontend for .wl files which is ok but I need ...
0 votes
1 answer
105 views

Where and how can I save a mathematica package

I want to save a mathematica package and then i want to extract and run it from there. How can i do that?
5 votes
0 answers
550 views

BVPH Package 2.0

Hopefully you guys can help with this issue. I am currently using Mathematica package BVPH2.0 to solve hybrid nanofluid in boundary layer flow problem using homotopy analysis method. But I seem to ...
2 votes
1 answer
78 views

How to set the same scaling for multiple density plots while using the ColorBar package or user-defined colorfunction?

I know questions with this theme have been asked before, and the one-line answer to them is- "Use ColorFunctionScaling -> False" But my specific ...
1 vote
0 answers
316 views

How long does it take to load FormCalc package?

I've installed the package (FeynArts, LoopTools, and FormCalc) via FeynInstall. Then, I load the package by <<FeynArts` <<FormCalc` I get message <...
0 votes
0 answers
23 views

This script included in a package has some error leading to one variable having context different from others

The package modt ...
2 votes
1 answer
69 views

How do I make all the external contexts accessible within subcontexts of my package?

I have a package file MyPackage.wl it has the following commands: ...
2 votes
1 answer
93 views

Adding Greek letters to ToMatlab

I want to add Greek letters to the ToMatlab package. The most recent publicly available version I found is here. There is a section on symbols starting on line 242. I tried adding a line ...
8 votes
1 answer
255 views

Are new-style packages compatible with the Wolfram Paclet Repository?

The package I'm developing is getting hard to navigate as it gets larger. I've started experimenting with using the new-style package format described in this question to break it up to subfiles. ...
1 vote
1 answer
141 views

Legacy Finance package

There used to be an old package Finance which contained useful functionality for converting between different interest rate representations, ...
3 votes
0 answers
46 views

Strategies and practical advice for using saved compiled functions in a package

I want to use a compiled function in a package without having to rebuild it each time. This slows down unit testing and loading of the package. I have used the example in the link as my starting point:...
0 votes
0 answers
49 views

Previously loaded packages not working

I'm a complete beginner at Mathematica. I was trying to learn the basics over the last couple of days. Yesterday I downloaded the GREATER2 package from here. To start using this, I downloaded the .m ...
4 votes
1 answer
101 views

How to use a personal function in Matlab within Mathematica utilizing Matlink?

Problem description I've written a function in Matlab as follows: function z = testfuncadd(x,y) z = x + y; end I want to use this function within Mathematica ...
0 votes
0 answers
56 views

Is loading several packages in the same cell safe, or it may cause probems?

My Mathematica 13.3 crashed after working 30 minutes. It produced a beep and no output. After that, it lost the capability of loading packages. I will reinstall it now. I wonder if this happened to ...
5 votes
1 answer
124 views

Where should global variables be defined in a package?

I am trying to understand two of the answers to the question 114769 Package functions and symbolic calculations ...
1 vote
0 answers
43 views

Why my MATLink must execute the command `OpenMATLAB[]` twice to realize once normal `OpenMATLAB[]` command?

Problem description To use Matlab code in Mathematica I have tried to use the package MATLink. However, everytime I run the code below ...
1 vote
0 answers
57 views

Normal order package usage [closed]

I found a package that normal orders bosonic creation and annihilation operators for me. Here is the link to the package and explanation of normal ordering: https://en.wikipedia.org/wiki/Normal_order ...
1 vote
0 answers
39 views

Why a script stops working when moved from the beginning of a file into a package?

Here's a two command script defining L1, Der1 (which compute the first Lyapunov exponent of an ODE): ...
5 votes
1 answer
451 views

HypExp and HPL packages for hypergeometric functions: Evaluating a function HPL[{minus,plus},x]?

I am currently using the HypExp and HPL packages, which are useful for expanding hypergeometric functions in series around integer or half-integer values, as in common in dimensional regularization ...
1 vote
0 answers
191 views

Bifurcation and stability analyses of delay differential equations

Are there any packages in Mathematica for bifurcation and stability analyses of delay differential equations? For Matlab, there is a nice tool like: https://twr.cs.kuleuven.be/research/software/delay/...
4 votes
0 answers
67 views

Implications of Code vs Input Initialization Cells in Package Files

When editing package files, I've noticed that there are really two options for how to format the cells, which has major implications for how they appear in the Mathematica front end. One is to have ...
14 votes
1 answer
2k views

Installing packages on "Mathematica Online"

How can I install packages in Mathematica Online? In particular, how can I install the xAct package?
0 votes
1 answer
166 views

Is there a good package for solving the Einstein field equations given a metric tensor?

I have a very simple metric tensor. I've built a notebook to calculate the EFE solutions based on this metric. Does anyone know of a good package in the Mathematica library that takes a metric tensor ...
0 votes
0 answers
72 views

Save inline math in packages

I can enter inline math with Ctrl+( in text cells, but saving this .wl file does not save the formatting. This can be seen by examining the source. How can I save this formatting? ...
1 vote
0 answers
37 views

Derivatives in the SpinWeightedSpheroidalHarmonics package

Hello I'm using the SpinWeightedSpheroidalHarmonics package from the Black Hole Perturbation Toolkit . This package includes the SpinWeightedSphericalHarmonicY, ...
6 votes
1 answer
364 views

Browne & Park Grassman Algebra package?

This year's Wolfram Innovator awards honored David Park Jr. and mentioned work on a Grassman Algebra & calculus package. This led me to find the Grassman Algebra book by John Browne https://...
0 votes
0 answers
45 views

MermaidJS command not working from the paclet

I have installed the mermaid command line package and added it to the environment variable Path and it is accessible from the command line: But the following ...

1
2 3 4 5
18