0
votes
1answer
76 views

How to create an array of functions

For a project I'm working on, I need to solve a differential equation numerically. I know this is easily done with NDSolve, but I want to solve it several times ...
2
votes
2answers
94 views

What is wrong with my use of Flatten? [closed]

Why does Flatten[f[g[a, f[b]], f[c, d]]] result in f[g[a, f[b]], c, d] I expected the answer to be ...
0
votes
0answers
27 views

Unexpected results from Thread [duplicate]

I've run into an issue where threading two lists with a generic function, f: Thread[f[{{1,1}, {2, 2}, {3, 3}}, {4, 5, 6}]] ...
0
votes
2answers
71 views

How can I make my output to be added to an existing list?

v = {{0, 0, 0}, {1, 0, 0}, {1, 0, 1}, {0, 1, 1}, {1, 1, 1}} For[i = 1, i < 6, i++, For[e = 1, e < 6, e++ 1, Print[Mod[v[[i]] + v[[e]], 2]] ]] I ...
4
votes
1answer
294 views

Counting the number of operations performed during a calculation

I need to know how can I count the number of operations performed during a calculation of a CompoundExpression. In some of these expressions there are ...
0
votes
3answers
92 views

How can I generate a generalized product to two lists in a special way? [duplicate]

Let's say I have two lists, and I'd like to generate a "cartesian product" from these two. Specifically Inputs: A = {{{1}}, {{2}}, {{1}, {2}}}; B = {8, 9}; ...
18
votes
1answer
428 views

Using Transpose with a list as the second argument

I'm having difficulty understanding the Transpose function. I know what the transpose of a matrix is, not a problem, and I see that applying the ...