Skip to main content

Questions tagged [object-oriented]

Questions related to using or implemented object-oriented design patterns in Mathematica

3 votes
1 answer
159 views

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 ...
Nasser's user avatar
  • 156k
3 votes
3 answers
175 views

I'm following this example here; Code Readability and Object-Oriented Code ...
RobertNathaniel's user avatar
1 vote
2 answers
161 views

How can I make it so that what is under the dropdown block is not calculated/constructed at once? Example code: ...
Kirill Belov's user avatar
4 votes
2 answers
280 views

I learned how to use OOP in Mathematica as shown by Leonid Shifrin (and others in this forum over the years). It works well, until I moved the module that represents the object to inside a package, ...
Nasser's user avatar
  • 156k
7 votes
4 answers
942 views

I wrote some Mathematica code that defines a function I want to use repeatedly (f) inside another function (finit) that pre-...
jjoIV's user avatar
  • 303
3 votes
0 answers
114 views

I need to know if I need to submit a bug report. I finally got my HeaderSize the way I want it but I had fudge it. It gives the correct widths but does this look ...
Jules Manson's user avatar
  • 2,507
7 votes
0 answers
323 views

I've seen some posts about mutable objects in WL and some implementations: Once more on object orientation in Mathematica: does it have to be so hard? Immutability, Association and typing Code ...
daneelsan's user avatar
  • 368
4 votes
1 answer
163 views

The below code defines a couple "objects" in the Mathematica sense using a convention consisting of so-called Q-functions for creating types and data validation, ...
rfrasier's user avatar
  • 612
0 votes
1 answer
99 views

In my version of object-oriented programming in Mathematica, essentially (without going into details) obj[a] is a reference to an object whose actual data is stored ...
user avatar
1 vote
0 answers
137 views

How would I declare a list of arrays and treat them as single objects? For example, I may have the Pauli matrices: $$ \sigma_0 = \begin{bmatrix}1 & 0 \\ 0 & 1\end{bmatrix}, \sigma_1 = \begin{...
QuestionEverything's user avatar
8 votes
2 answers
311 views

This follows on from my previous question answered here. Ultimately, I now have a graph which I've simplified for posting here: ...
Jordan MacLachlan's user avatar
2 votes
1 answer
385 views

It is possible to implement OOP in Mathematica using something like obj=c[<|a->1,b->2|>] and it's convenient to extract value from the object by ...
Wjx's user avatar
  • 9,700
24 votes
2 answers
454 views

My friends and I don't want to use Slack or Gitter, but instead a pure-Mathematica chat system. Now that the ChannelFramework exists, how could we do this?
b3m2a1's user avatar
  • 48k
4 votes
0 answers
121 views

So in this answer we see the only use I know of of the function Language`SetMutationHandler. And just to see what it could do I tried it on one version of my OOP ...
b3m2a1's user avatar
  • 48k
7 votes
3 answers
300 views

In an earlier post I described a special kind of list (actually, a special kind of multiset) that can be represented more efficiently with a structure like this: ...
kjo's user avatar
  • 11.9k

15 30 50 per page