Linked Questions

33 votes
0 answers
3k views

Custom package development: Basic steps [duplicate]

Every once in a while, I write a generic function that I use quite often for months to come. However, package development in Mathematica is not very well documented from what I can tell, and I was not ...
user avatar
  • 14.7k
4 votes
1 answer
328 views

How to efficiently split your code in several pieces [duplicate]

I want to efficiently keep my program in several documents, and initialise pieces of it automatically. I'm pretty sure that there is a manual on the subject, but I'm unable to find it on my own. At ...
user avatar
  • 41
3 votes
0 answers
485 views

How to add my own functions to the library? [duplicate]

I would like to have my own functions (some sort of helper or utility functions) available all the times I run Mathematica. How to do that?
user avatar
  • 1,993
2 votes
1 answer
130 views

How to use external Mathematica Code? [duplicate]

I have a Mathematica Notebook with a function that i would like to be able to access from another Notebook without having to have the first Notebook open. The functions calls other functions in the ...
user avatar
4 votes
0 answers
172 views

What is the current structure of a simple package? [duplicate]

Currently, from a variety of examples, and (mostly) the template generated by my IDE, I get: ...
user avatar
  • 12.7k
4 votes
1 answer
59 views

How to set the value of a symbol in a package [duplicate]

I am writing a package like this: BeginPackage["HNotation2`"]; Begin["`Private`"]; HTransR=3; End[]; EndPackage[]; When I load the package, it seems that the ...
user avatar
  • 1,203
2 votes
1 answer
134 views

Why is a function I defined in a package not visible when I load the package? [duplicate]

I made a package containing some functions in the following way. ...
user avatar
  • 21
0 votes
0 answers
133 views

Create library of custom functions [duplicate]

I have been trying to create a library of custom functions that I could just call at the start of every notebook. For instance, say I want the following functions to be part of the Library, or even ...
user avatar
1 vote
1 answer
87 views

After creating a package, how do I install it? [duplicate]

I have created the following package. ...
user avatar
  • 490
1 vote
0 answers
99 views

Programming in Mathematica [duplicate]

I am new Mathematica. I used Mupad in Matlab to write many codes. The notebook in Mupad in Matlab is convenient. But I found that Mathematica has some advantages. Therefore I would like to translate ...
user avatar
0 votes
0 answers
81 views

function from .wl produces no output [duplicate]

I'm trying to learn to reuse functions. I have created a .wl file with the following content. As I understand the last line without semicolon is the function output. Should each function have it's ...
user avatar
1 vote
0 answers
70 views

Basic mathematica coding package examples [duplicate]

Since Google and Mathematica documentation has proven utterly useless at answering my question... Does ANYONE have some BASIC examples of how to code up a package? For my course work, I have to ...
user avatar
  • 11
0 votes
0 answers
53 views

Is it possible to create complicated packages from modules which work fine by copy paste? -- A counterexample [duplicate]

Here is a module which constructs essentially several functions in a chain [Phi], sct, ks, WE, G: ...
user avatar
  • 896
0 votes
0 answers
41 views

Is it possible to have a function with non-global parameters? [duplicate]

If I have functions in two packages that have parameters such as length_, width_ and height_; is there any way to have both packages loaded without generating messages such as "Symbol length appears ...
user avatar
  • 2,065
0 votes
0 answers
23 views

Problem with using modules from a package or separate notebook [duplicate]

I saved some modules into the same package or notebook which I call ModuleLibrary.m I then get/call this package using ...
user avatar
  • 2,301

15 30 50 per page