Questions tagged [head]
The head tag has no summary.
43 questions
2
votes
1
answer
254
views
putting image to Head [closed]
Could it be possible for the SetDelayed function to operate when an image, rather than text, is located at the head of a function? As below, Code1 works as expected, but at code2 which use image of ...
5
votes
1
answer
601
views
Why is a head called a head?
The head of an expression
In the Wolfram language / Mathematica, "everything is an expression," to quote a tutorial. I think that every expression has a head. According to the tutorial:
The ...
5
votes
1
answer
371
views
Which NDSolve method is most effective for the given chaotic system?
Note: This question is for those chaotic systems where the order of maximal Lyapunov exponent is around $10^{-3}$. So it's different from normal chaotic systems like Hénon–Heiles system, Yang-Mills-...
3
votes
4
answers
252
views
Replacing the heads of an expression in left to right order
I would like to replace the occurrences of the head f in an expression.
The expression only contains two possible heads: f and g.
These heads are applied to exactly two arguments.
Example:
...
5
votes
1
answer
118
views
Undocumented behavior of Fold for arbitrary heads [closed]
Edit: I'm apparently blind. Sorry! And thanks to those who answered anyway.
Apologies in advance if this is sort of a nitpicky question, but I'm generally very paranoid that I don't fully understand ...
5
votes
1
answer
252
views
Why is Around omitted when the uncertainty is zero?
I have a list of values with errors and I use Around[x, dx]. Some of those values have an error of zero though. Mathematica removes the ...
6
votes
1
answer
351
views
A problem on the pattern (:) of Heads
I defined
Clear[f, g]
f[(h : Exp | Log)[x_]] := x;
g[(h : Log | Exp)[x_]] := x;
The code gives a weird result:
...
11
votes
2
answers
595
views
How can I create an atomic head or treat some head as atomic during Map?
For example,
Map[g, {0, {h[1, 2, 3]}}, {-1}]
gives
{g[0], {h[g[1], g[2], g[3]]}}
I want a ...
2
votes
0
answers
93
views
When should I use Audio vs Sound Data types?
It seems like mathematica has 2 related data types Audio and sound.
Why is there 2 separate data types? When would I use one versus the other?
Guesses
I know I can convert between them by ...
2
votes
0
answers
60
views
Can't match custom head in function signature [closed]
I have written a financial charting function which has the following signature;
...
0
votes
1
answer
178
views
any way to store the values of the controls of a Manipulate so that one can reuse them in the future excutions
I’m using Manipulate[] to adjust several parameters, which will eventually generate some figures. After I get the desired view, I’d like to store the set of control parameters so that I can reuse them ...
4
votes
2
answers
322
views
How many @ need to be used when I try to use apply function? [closed]
According to the manual, $f@@A$ means apply function $f$ to $A$. If it would be the same if I only use one @? Does $f@A$ still represent apply apply function $f$ to $A$? And it would help a lot if ...
5
votes
1
answer
165
views
Extracting n-th part of an expression without any evaluation
Is it possible to extract n-th part of an expression as a string, without any evaluation?
For example,
...
18
votes
1
answer
470
views
Head[x] vs x[[0]]
Can we say Head[x] and x[[0]] are identical ?
In mathematica manual I could find : 'The head is the part with index 0'
But I am not sure whether Head[x] are x[[0]] are really interchangeable in any ...
2
votes
2
answers
120
views
Understanding f /@ g[x,y,z] [closed]
According to the Mathematica guide,
In[26]:= f /@ g[x, y, z]
Out[26]= g[f[x], f[y], f[z]]
In a simple example, this works as desired with symbolic values:
...