{array} is an environment used in {math-mode}. It can be useful when aligning terms.

learn more… | top users | synonyms

1
vote
1answer
18 views

Nested arrays with labeled rows and columns

I want to represent a four-dimensional tensor using a matrix of matrices. Additionally, I want to label the rows and columns of the inner matrices. My attempt to make this labeled matrix of matrices ...
1
vote
1answer
54 views

Help writing a matrix

I have trouble in wrtiting this block matrix Any idea? Thanks a lot.
1
vote
1answer
37 views

How can I have a label span across a set of columns in Stack Exchange's MathJax? [closed]

I'm from another Stack Exchange site where we've just had MathJax enabled. There's a table in this answer that looks like this (actual decimals just typed in for the example), which looks rather ...
-1
votes
1answer
58 views

How to write this array? [closed]

I want to write array like this photo, help me please.
4
votes
1answer
51 views

Numbering a multiline environment

How can i number a multiline environment (such as array rather than equation) so that the numbering is placed bottom right? this is the part of the code in document which would give result as on the ...
2
votes
1answer
42 views

equation inside frame in beamer causes error - Missing $ inserted

I do not find the error that latex shows, this is my code. \documentclass{beamer} \usepackage{beamerthemeshadow} \usepackage[utf8]{inputenc} \usepackage[spanish]{babel} \usepackage{amsmath,amssymb} ...
0
votes
0answers
32 views

Column color overwrites hline in array

Please help. Why does color column overwrite just the second \hline? How do I rewrite it? \begin{document} $$P=\left[ \begin{array}{>{\columncolor{red}}c>{\columncolor{red}}c>{\columncolor{...
4
votes
1answer
58 views

Alignment problem for a matrix

I have written the following matrix on Latex: However, I would like the different elements to be aligned vertically, i.e.: I have been unable to accomplish this. My code is the following: \[\...
4
votes
2answers
34 views

Size of a matrix is too big to fit inside text block

I know there's other topics with this kind of question, but I tried a few solutions and just got errors... My code is: \documentclass[12pt,a4paper]{article} \pagestyle{myheadings} \usepackage[utf8]{...
2
votes
1answer
39 views

How to create an array while using latex \DeclareOption

I have a class in which an option is to state a code and the resulting programme of study is represented at various points throughout a document. The option also changes a number of other blocks of ...
4
votes
1answer
47 views

How can I determine the size of an array containing macros with optional parameters?

I am using my solution from How can I determine the size of an array? to count the number of entries. However, the \foreach/\IfStrEq in \SetArrayLength seems to have a problem when an entry is macro (\...
1
vote
2answers
38 views

Breaking lines of array matrix

I have a line of matrix arrays such as the next figure Below the code of that matrix. \begin{figure} \[ P=\left(\left\{\begin{array}{l} p^{(1)}(x_1,x_2,\cdots,x_{r_1}) \\ \vdots\\ p^{(m_1)}(...
6
votes
2answers
40 views

tikz array lookup

Here's a very simple example; how do I replace foo with an array lookup as a function of \k? I want the red label to be foo, the green label to be bar, the blue label to be baz. \documentclass{...
2
votes
2answers
51 views

vertical centering in tabular using array and booktabs

In the following school timetable for my 4 kids I am trying to use array and the m{} command (vertical align middle) to get the word Peter to be vertically aligned in its cell, (at the cmidrule), ...
4
votes
2answers
97 views

Numbering rows in array environment

I would like to (use the \label - \ref mechanism to) number as equations the first and third rows in the following diagram: \documentclass[10pt]{article} \usepackage{amsmath} \usepackage{amsfonts} \...
2
votes
1answer
28 views

Alignment at the inequality in a system of linear inequalities

I have a system of linear inequalities (in the variables x and y) that I have aligned at the inequality. There is no inter-line spacing. If I had expressions that were x - y < 3, there would have ...
1
vote
1answer
85 views

3x3 Normal Form Payoff Matrix in LaTeX Tabular Environment

~Disclaimer~ This question is a generalization of this question to the 3x3 case. I would like the same format as the top example in the answer to the above question; That is, "Player 1" on the left, "...
1
vote
1answer
33 views

Package array error

I'm trying to write the following on my latex $$(T_n f)(z)=n^{2k-1} \sum_{\begin{array}\ a\geq 1,ad=n \\ 0\leq b<d\end{array}} d^{-2k} f\left(\frac{az+b}{d}\right)$$ But it ends up with error: ...
0
votes
0answers
24 views

Partitioned in block matrices related [duplicate]

How to draw the following block matrix.
2
votes
3answers
24 views

Forcing equal width columns in an array environment with a custom command

I've defined a custom command tractorQ that takes four arguments and typesets them in a matrix-like notation using the array environment: \newcommand{\tractorQ}[4]{ \def\arraystretch{1.2} \...
0
votes
1answer
73 views

How to draw an 1-D array

I want to draw something like this: Easier or better way to draw 1d array. The problem is that I need to change the value of the second array and I don't know how to do that using stack instead of ...
2
votes
1answer
27 views

Changing a column type to centered

I am trying to change this code in the DYI calendar \newcolumntype{W}{>{\hfill\normalfont\footnotesize}p{\WkdayColWidthMonthTblYC}<{\hspace*{0.5em}}@{\extracolsep\fill}} to make the column ...
2
votes
1answer
49 views

Error using array and node in TikZ

I am new in TikZ and I am trying to make a graph with 12 nodes in a ring shape. My code below is not working: \begin{tikzpicture} \def \n {12} \def \radius {3cm} \def \margin {8} % margin in angles,...
1
vote
0answers
42 views

Row Operations Error (Repost) [duplicate]

I couldn't comment on my last post, that's why it's a duplicate. I'm trying to put "arrows operations" in my matrices but I keep getting a Latex error. Could you guys help me out? I used the linalgjh ...
2
votes
1answer
29 views

How to center elements of different sizes

I would like to display some matrix things \begin{frame} \begin{align*} \left( \begin{array}{c} y_1 \\ y_2 \\ \vdots \\ y_T \\ \end{array} \...
2
votes
1answer
37 views

Spacing and size of my matrix displays

I am displeased with some of my display in the following equation : \begin{frame} \begin{align*} \left[ \begin{array}{l} \dfrac{\partial \log L}{\partial b} \\ \...
0
votes
0answers
38 views

Row Operations Error

I'm trying to put "arrows operations" in my matrices but I keep getting a Latex error. Could you guys help me out? Thanks! \documentclass[11pt]{article} %size, document type \usepackage{fullpage} \...
0
votes
1answer
103 views

Dot-aligned table column with defined width

I am trying to specify a custom column command, taking a width parameter and aligning the column by the decimal point of the content. I am using the tabularx package to use columns with a pre-...
1
vote
0answers
41 views

How to write the following matrix requiring both case and block array environment?

I am trying to write the attached equation using block array environment. I am suppose to use both the case and block array environment for achieving the desire output. However, I have completed ...
2
votes
1answer
47 views

Array Problems Math mode

\documentclass[12pt,a4paper,notitlepage]{report} \usepackage{amsmath} \usepackage{array} \usepackage{multirow} \begin{document} \[ \begin{array}{llll} \hline & \multirow{2}{*}{\tilde{b}\leq b^{...
0
votes
1answer
87 views

How to create augmented matrix in iBook Author using LaTeX [duplicate]

I am very new to LaTeX so please bear with me if my question is rudimentary. I searched through other questions and while this question has been answered the solutions provided did not work for me, ...
1
vote
0answers
51 views

Diagonal line in math arrays

I have some arrays in math mode, such as the one below. I would like a diagonal line in a cell, something like diagbox (diagobx package) or diaghead (makecell package). But it seems that diagbox and ...
0
votes
0answers
23 views

Automatic table width adjustment with the array package

I was searching for a way to vertically and horizontally align my text and found a good way here. However using M I need to set the width for every column, which is what l did automatically for me ...
3
votes
1answer
66 views

Block matrix with headings

I created a matrix using easybmat and blkarrary and I would like to label the columns above the matrix. This is the code I am using and what the matrix looks like at the moment: \usepackage{easybmat}...
2
votes
2answers
92 views

Using \nearrow and \searrow to separate an equation in two alternatives

I'm tryin' to write the solution of an equation with two possible solutions, as x(ax-a+1)=0. I'm using \nearrow and \searrow with an array but I don't get it fits right. This is the code: $\...
1
vote
2answers
58 views

Incorrect space in tabular around an array

I have searched a little in the forum, and I can't find a satisfying solution to my problem. I want to create a tabular in which I compare two different situations, and a line of the comparison is an ...
2
votes
1answer
46 views

Change fontsize of an array within an align environment

I am trying to label several lines at once in a very long equation. From this question I have come up with the following minimal example: \documentclass{report} \usepackage[onehalfspacing]{setspace} \...
3
votes
2answers
57 views

Create array of specific counter values

I want to create an array containg specific values of a counter to be used in a foreach loop. So I want to define a command that adds the actual counter value at the end of the list. What I can do is: ...
1
vote
1answer
112 views

Highlight matrix cell and have arrows pointing from cell with text [duplicate]

This code is building from the solutions posted here. I am trying the approach suggested from the duplicate solutions. I am having two issues: I am not sure how to get the arrow to point to the ...
3
votes
1answer
38 views

Custom align, three \beta = statements, so the beta is custom aligned vertically, and the matrices/vectors are all vertically aligned

Something like: \beta = [], \quad \beta = [], \quad \beta = []. So that the three forms of beta fit on one line. I want the \beta = to valign with the first element of the vector/matrix. I want ...
4
votes
2answers
35 views

How to have 2 arrays of variables in one document

I've used an example from Create an array of variables By adding a new \newcommand as in the code below: \documentclass{article} \usepackage{etoolbox} \newcounter{cnt} \newcommand\textlist{} \...
1
vote
1answer
25 views

Making a beamer page that includes an array. Code included

Please help with code below. Firstly, beamer seems to insist that every line within the array code requires its own begin and end $ signs. Then, though I've checked this for hours, it insists that ...
2
votes
1answer
38 views

How to make the distance between two rows larger in array?

I found a mathematical formula in mathdesign document, it looks good and elegant When I try to type it as it looks, what I got is always not as good as origin. The code I use is \begin{equation}\...
1
vote
1answer
36 views

Missing endcsname inserted error

I have the following latex code which produces the error mentioned in the title: \documentclass{article} %\usepackage{flexisym} %\usepackage[T1]{fontenc} %\usepackage{array} \usepackage{setspace} \...
3
votes
1answer
112 views

How to use values from a 2d array in a tikz picture ? (out of bounds error)

I would like to use a list of values from a 2d array in a Tikz picture. The code bellow works while using a random number : \pgfmathtruncatemacro{\r}{round(rnd*20)} But when I replace it with the ...
1
vote
1answer
35 views

How to vertically center cells (tabular) without altering the automatic column width?

In the following file I have a table with insertion of figures. I want to vertically center the cell contents. Only the cells in the second and third rows. But I do not want to leave intact the ...
11
votes
3answers
359 views

What all those @{} resp @{\quad} in preamble of this array mean?

as I was reading different question This one I've found code of array enviroment which preamble is quite unknown to be... I see what it does but I would like to understand it to be able use that ...
1
vote
1answer
45 views

Formatted table based on arrayjob

I want to setup a rowcolor and the cell content of a tabular accordingly to the values stored into an array (arrayjob). The next MWE \documentclass[10pt]{article} \usepackage{arrayjob} %\usepackage{...
2
votes
1answer
29 views

Separators in array (for a matrix) have different, wrong sizes

Why is it so and how to fix it? \documentclass{article} \begin{document} \[ A = \left ( \begin{array}{c|c|c} \\ C_1 & \cdots & C_q \\ \\ \end{array} \right ) \] \end{document}
1
vote
1answer
49 views

Align/Array equation - explain the options

I have searched and found a solution to a problem I had here: Horizontal alignment, but now I have a follow-up question (and can't comment there because I have little reputation): The code in the ...