Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Questions tagged [table]

Questions on the use of the Table[] command and other functionality related to lists. Use [tag:matrix] for matrix algebra and related methods, and [tag:list-manipulation] for questions about transforming or operating on existing lists.

Filter by
Sorted by
Tagged with
1
vote
1answer
45 views

Apply conditional styling to the rows of a table

This is a follow-on from a similar question here. If I already have a table of data, say ...
0
votes
1answer
62 views

Create bold headings and rows in `TableForm` if `x` is prime

In the following table ...
0
votes
1answer
39 views

find in list almost equal elements, make new list correspond to position or some list

I have a list of elements called q and wish to compute Total Multiplicity of each element, and put these values in the list tm. ...
3
votes
2answers
103 views

How to create table with 2D function values?

Consider some function f[x,y]. I want to create a table in the form table = {{x1,y1,f[x1,y1]},{x1,y2,f[x1,y2]},...,{x2,y1,f[x2,y1]},{x2,y2,f[x2,y2]},...}, where $...
2
votes
1answer
85 views

Why is Mathematica “de-evaluating” my expressions when I try to generate a Table? [duplicate]

I am attempting to plot a combination of StreamPlot and ParametricPlot that is a function of a parameter. When using Manipulate or Animate, the evaluation is slow but the graphs are outputted as ...
2
votes
1answer
156 views

Problems with plot interference of two waves

I'm trying to make motion plot interference of two waves i used lines to represent amplitude and wave envelope separately. This works for the traveling waves, but no the interfering wave. i'm ...
0
votes
0answers
26 views

Simulates Timeseries with Table

i need your help again. I would like to calculate EW[k_] with EW[1],EW[2] and EW[3]. My code works only for one calculation from EW (in the code below it is EW[1]) but i would like to calculate the ...
0
votes
1answer
56 views

Problem with {table values} when plotting

I have a Piecewise and Nintegrate both defined with NumericQ. The NIntegrate part of the Piecewise operates when first inserted into a working program, but not when called from inside a table. Their ...
0
votes
3answers
103 views

How can I join several plots a single figure using a Table?

It is possible to joint different kind of plot using a Table, The idea is to have a single plot. I have been trying using Show function y. But I can not get it. So It is possible also to add ...
2
votes
2answers
60 views

Table counting divisors

I have a simple table that I can't quite make work. Columns are as follows A function returning 1 if x divides ...
0
votes
1answer
65 views

Narrowing down loop to only print if certain conditions are satisfied

I have the following code Table[Riffle[Mod[{i, DivisorSigma[1, 7 i + 4]}, 47], Sqrt[7 i + 4]], {i, 200}] and it works perfectly fine. There are two modifications ...
2
votes
2answers
63 views

Mix text and calculated values in table header

I have a simple table: ...
2
votes
2answers
66 views

Table Command with multiple Variables

I am new to Mathematica, so I'm not sure about the ins and outs of what's possible and what is not. I am trying to view the eigenvalues of multiple matrices at once. In particular, this matrix: $$\...
1
vote
1answer
38 views

Table of numbers and their divisors

I want to create a table of random numbers and their divisors. The random numbers are given by ...
0
votes
1answer
123 views

Printing all elements of table in Fortran form

Let's say I have some Table object. The elements of this table are accessed as Table[[i,j,k]]. For each element in the array I ...
7
votes
2answers
369 views

Formatting a table to look nice

my current code is: ...
1
vote
0answers
44 views

How can I export the values of both the dependent variable and the independent variable? [closed]

This is the first time I am using Mathematica. I am trying to calculate the bandgap of a solid using the following script. ...
2
votes
1answer
39 views

Format a table column with superscript and operator

I have two alternative forms of a simple table, both of which have problems: ...
2
votes
2answers
172 views

How does one plot a 3 dimensional table of numbers?

I've just spent three hours searching the documentation and this website for an answer. I have a rank 3 tensor: t = {{{1, 2}, {3, 4}}, {{5, 6}, {7, 8}}} How ...
3
votes
4answers
112 views

Generating $n \times n \times \cdots \times n$ table

Suppose I want to write a function that automatically create a $n \times n \times \cdots \times n$ (all $D$ $n$'s) multiplication table with $D$ as the argument of the function, which is automatically ...
2
votes
1answer
59 views

Improving efficency in generating Tables with large numbers of values

I'm simulating some transient data for fast Fourier transform -- on the order of 20 million points. Understandably MM takes a while to do this. Are the any techniques in table generation optimisation ...
0
votes
1answer
46 views

Combine list with table

I want to create a three-column table that has a list for one column. But when I do this, using TableForm with TableHeadings, ...
1
vote
1answer
171 views

Creating a diagonal matrix from from a vector [closed]

I try to create a function that create a diagonal matrix in which the diagonal are: $\qquad 1,a,a^2, \cdots,a^n,1,a,a^2, \cdots,a^n$ Here is my attempt: ...
1
vote
2answers
101 views

Having problems with using TableForm to format a table

I want to make a table of various values of the logistic curve given by l[x_] := 1/(1 + E^((-k)*(x - \[Alpha]))). In basic form, this is dead easy. However, I want ...
0
votes
1answer
95 views

NonlinearModelFit : How to get the values of the individual parameters from the matrix “ParameterTable” [closed]

I just made a NonlinearModelFit : ...
1
vote
1answer
44 views

Make a plot from data [closed]

I have two variables $x$ and $y$ satisfying, say, $y^2 + x < 1$, such that $0 \le x < 1$ and $0\le y<1$. I want to plot all the points satisfying the inequality $y^2 + x < 1$ and also show ...
0
votes
1answer
167 views

multiply elements of two different lists

I have a data file which I have imported and form a table. list1 = Flatten[Table[{relic[[i]]}, {i, 1, 5}], 1] the output looks like this ...
0
votes
0answers
38 views

Interpolation of a list defined on a region

I have a three-dimensional table (each element has the form { x, y, f( x, y ) }), and the x, y coordinates spans a region of a parallelogram. If I do a list contour plot of the data, it gives the ...
3
votes
1answer
50 views

Is it possible to make double tables more efficiently coded? [closed]

I am wondering about the following situation, suppose I have Table[Table[x^Length[l[[j]][[i]]], {i, Length[l[[1]]]}] // Total, {j, Length[l]}]; where ...
1
vote
1answer
47 views

Precalculating ThreeJSymbols to make my program faster

Does anybody have an idea what is the best way to pre-calculate the ThreeJSymbols in order to use them in a loop? (I want to make my program work faster that is why ...
4
votes
3answers
431 views

Generate this sequence more efficiently

Is there a more effecient way to generate the sequence shown below. ...
6
votes
1answer
246 views

How do I include table headings in Excel data?

I am trying to generate a table with Manipulate and export the results into an MS Excel file. Fortunately, after a lot of troubles, I was able to get the file ...
0
votes
0answers
24 views

Using Table to determine Plotrange coordinates

Hello I have a more pragmatic problem. Let's start from the beginning so everyone knows what I mean. I have a listplot such that ...
3
votes
3answers
174 views

ListPlot from Table of single input x and many y(x) output

Suppose have data for several x and several y(x), for example mydata = {{11, 1.1, 2.3, 2.4}, {12, 1.3, 1.4, 1.9}, {13, 1.8, 1.7, 1.2}} mydata // MatrixForm So ...
0
votes
1answer
236 views

Table in NIntegrate

I have an integral that I want to evaluate it once and store its values in a table so that I don't run the integration each time that I want to plot it. Its form is ...
2
votes
1answer
99 views

Is it possible to enter tabular data in Mathematica? [duplicate]

I want to enter table of X and Y values then plot them. I don't want to enter brackets and or commas. Can I prepare grid for myself and them fill it with data in Mathematica, like in Excel? I found ...
0
votes
1answer
25 views

Looping Constructs to create a set of varibale matrices

I am trying to create an $ n \times n $ matrix, which has cosine terms. I would like to select the values of the arguments of cosine terms from a random set of values that I have generated. My code ...
0
votes
2answers
66 views

How to show the whole table

I have this code ...
1
vote
1answer
110 views

Inverting the order of a Table - Prime numbers

In a previous post I asked for the possibility to have a binary image of the coprimality inside the natural numbers. The following code ...
1
vote
1answer
75 views

Problem displaying Killing equations

What I'm trying to do is to compute the Killing equations and then solve them using DSolve to determine their solutions. I have a problem understanding where my Mathematica program doesn't work ...
0
votes
1answer
121 views

How to get Lissajous curve like the following gif [duplicate]

parameter equation $x= \sin(m t)$, $y= \sin (nt)$,(fix $m=13$, $n=18$ not to change) I need the picture show the generation of the curve.(start from one point to the final curve like you draw it ...
2
votes
2answers
234 views

Kronecker product $ n $ matrices

I would like to write code to realize the Kronecker Product of $ n $ matrices, for instance when $ n=4 $ and the matrices are Pauli matrices ...
1
vote
1answer
100 views

Use iterator outside of iteration

I want to Map something that is depending on an iterator from the outside of e.g. Table into the procedure. What would be the ...
1
vote
2answers
69 views

Extracting first 2 elements of table

I have a table in Mathematica as follows: table1 = {{2,4,51,2017},{20,5,21,2018},{300,1,22,2016}} From this, I was wondering how one could extract only the first ...
1
vote
2answers
87 views

Storing values of NDSolve or NIntegrate

I am looking in plotting some solutions of NDSolve or NIntegrate but they take too much time to run, thus it is not handy if I ...
1
vote
1answer
84 views

Is there any way to save time using of “Cross” or “Table”?

I need to solve a equation by NDSlove, so I write the equation first, but it takes me a lot of time. The follow is my code ...
1
vote
1answer
45 views

How can I know the value of parameters?

In the the attached image I plot two function for the parameter $a1, a2, a4$. I take $a2$ as particular value, $a1$ as discrete set and $a4$ continuous value. In the plot how can i recognize for which ...
3
votes
2answers
135 views

How to generate a “value-frequency” table with random numbers?

I want to create a "value-frequency" table from the following expression. Counts[Sort[RandomInteger[{1, 5}, 500]]] // TableForm The generated table should be in ...
1
vote
2answers
72 views

how can I make a grid? [closed]

I would like to make a grid for x between 0 to 1 and use following Table ...
-1
votes
1answer
162 views

Why can”t I get a smooth curve?

I used "Table" to calculate and plot the following complicated function. First, we choose an initial value for $G$ and other parameters, but at later times $G$ changes with function $I_a$. ...