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

learn more… | top users | synonyms

1
vote
3answers
83 views

Use hfill in array

I want to have two equations, in two lines, the first the most at left, the second, the most at right: equation 1 equation 2 So, the newbie in me try to do \documentclass{article} ...
3
votes
1answer
94 views

Nested matrices with aligned columns and rows

I'm trying to represent "matrices" with more than two dimensions, like the Riemann curvature tensor or Christoffel symbols, using nested matrices. I still don't know if this can help working with ...
0
votes
0answers
41 views

Pgfmath array problem

I have a problem with pgfmath array : it work if defined outside pgfkeys, doesn't work inside. What is the problem ? \documentclass[tikz]{standalone} \usetikzlibrary{calc} ...
3
votes
4answers
139 views

Making an array in the Table

So we have an Table and there is an array which we wish to have it in the Table: Here is the code \documentclass[onecolumn,amsmath,amssymb,nofootinbib,superscriptaddress,floatfix]{revtex4} ...
0
votes
1answer
57 views

Table using array

I'm creating Latex Tables using Array One of the sample table is mentioned below with merging multi-cell of rows. Can you please help me to understand, how can i merges rows in arrays Sample Latex ...
5
votes
1answer
707 views

Block matrix equation with dimensioning

I need to write following matrix equation in LaTex. The dotted lines shown need to be present in the structure but need not have colors (could as well be black). I have used it here only to show the ...
1
vote
0answers
33 views

\arraystretch both horizontally and vertically [duplicate]

I did an \arraystretch to get taller column vectors, but not the matrices are too small. How can I also stretch them horizontally so that the matrices become square-like again? Here's the code I ...
2
votes
1answer
53 views

Aligning numbers in array

What am I doing wrong here?: \documentclass[11pt,a4paper]{article} \usepackage[latin1]{inputenc} \usepackage{amsmath} \usepackage{amsfonts} \usepackage{amssymb} \begin{document} \begin{align} ...
10
votes
3answers
1k views

How to create vertical and horizontal dotted lines in a matrix?

Similar to this question, I am trying to output a similar matrix with dotted line instead of dashed line. Is there anyway to do this? I also try to use these three packages: ...
4
votes
2answers
74 views

Multiple lines in equation environment

I have to put an two equations inside one equation environment. I could do it with this piece o code: \begin{equation} \begin{array}{ccl} \nabla \cdot F & = & \left(\frac{\partial}{\partial ...
3
votes
5answers
293 views

An double arrows between two systems

I'm trying to have 2 equations systems separated by a double arrow, something like this : I'm actually using 3 minipage : the first and the third with and array and the arrow at the ...
2
votes
1answer
72 views

Overbraces hovering too far above matrix for some reason?

I have a matrix with two overbraces above it but they are not directly above it, there is a fair amount of space between the braces and the matrix and I can't see why it is happening. ...
2
votes
0answers
37 views

Need to split right bracket at side of matrix into three smaller brackets [duplicate]

To the right of this matrix I have a big right curly bracket with the text "2m terms" that spans the height of the matrix. I need to replace this right bracket with three smaller ones that together ...
3
votes
1answer
1k views

Package array Error: Illegal pream-token

I get the following error: Package array Error: Illegal pream-token (\renewcommand): `c' used \renewcommand When I run my minimum working example: \documentclass{article} \usepackage{hyperref} % ...
4
votes
2answers
193 views

Large curly braces for ONLY SOME rows of an array?

I'd like to use curly braces to demarcate parts of an equation. Right now I'm trying to do so using multirow. Is there a better way, ideally one that is compatible with automatic sizing? ...
2
votes
1answer
86 views

Problem with abbreviation of `\multirow` and `\multicolumn` (LaTeX)

I have had to typeset several block matrixes lately. So I thought of defining abbreviations of \multirow and \multicolumn so as to avoid having to remember the former needs {*} and the latter {r} and ...
1
vote
3answers
95 views

equations in multiple lines

I'm using the following code to generate the second figure. \begin{equation} \begin{array}{c} \displaystyle \min_{W, ...
3
votes
2answers
64 views

Braces (not)containing \underbrace

This: \left\{ \begin{array}{l} \frac{da}{dt}=\sum\limits_kJ_k\sin(D_{ok})\\ \frac d{dt}\left\{\begin{array}{c}e\\i\end{array}\right\}=A+\sum\limits_kJ_k\sin(D_{ok})\\ \frac ...
2
votes
0answers
15 views

Using array columns as arguments of a macro [duplicate]

I am creating a table using array, and I want one of my columns to be used as the argument of xrightarrow as shown below. To make the code cleaner, I want to avoid having to write xrightarrow for each ...
4
votes
2answers
86 views

Array within Align*

LaTeX fresh beginner here. Using TexStudio. In the second row of an equation array (using align*), I am trying to multiply a row vector by a column vector, using the array command. Apparently the ...
1
vote
1answer
178 views

\multicolumn in array not showing column separator

I'm trying to write three columns of equations separated by vertical lines in an array, but when I use the multicolumn command it doesn't show the column separator. I've tried using the multicols ...
4
votes
1answer
194 views

How to create an array with both vertical and horizontal braces around the elements

I want to create the matrix shown bellow in Latex. I have the horizontal curly brackets figured out, I can use undermat{}{} for that. I do not however know how to insert the vertical curly brackets ...
4
votes
1answer
365 views

Gaussian elimination with several steps in one line

I would like to have a macro for gaussian elimination, but I don't like the notation of the gauss package. I've found a great macro here, but I would like to have several steps in one line. When I ...
1
vote
0answers
19 views

Size and position of array [duplicate]

The following is an extract from my LaTeX file which describes a table. The table has a fair amount of space below it. I would, therefore, like to increase the arraystretch. However, by increasing it ...
6
votes
2answers
89 views

Problem with \pgfmathparse and font style of array elements

There are probably other ways to do that, but I was happy I've found this code working just fine for my needs: \documentclass{article} \usepackage{tikz} \newcounter{grpcnt} \def\groups{grp1, grp2, ...
1
vote
0answers
25 views

table into page width in a double columns page

I am writing a paper with double columns pages and I like to insert a table across the width of the page. This is my attempt but its output is not what I look for : the table and the text are layered ...
2
votes
1answer
133 views

writing text next to equations in array [duplicate]

I am trying to reproduce the attached picture: But I can't in any way figure out what the correct way to write text next to an equation is. Is there a package for this?
3
votes
1answer
365 views

Dynamically format labels/columns of a LaTeX table generated in R/knitr/xtable

I have some tables coming from the statistical package R that I want to export in LaTeX markup. I would like to make every column large as the longest word of its label (assuming for simplicity the ...
5
votes
2answers
601 views

Gaussian elimination

I want to demonstrate examples of Gaussian elimination/the Gauss-Jordan method as shown below. There are some things that I like about what I have right now. Each column is the same width from ...
1
vote
0answers
75 views

Error when trying to load the array package

I am writing my thesis paper in Math and I really need to use the array package. But when I wrote \usepackage{array} an error occurred. It says "pdflatex> ! Emergency stop." What should be the ...
4
votes
2answers
73 views

How to put the formula in line with the text in the example below

Be the $ \begin{array}{cccl} \gamma\ : & \! \mathrm{I} & \! \longrightarrow & \! \mathbb{R}^2 \\ & \! s & \! \longmapsto & \! \gamma(s) \end{array} $ differentiable and ...
4
votes
2answers
87 views

clean, breakable left-aligned array-like environment

The centered, yet left-aligned aspect of \begin{array}{lll} ... \end{array} is what I usually go with to give a list of conditions. My only problem with it, is that it is not breakable, so I try to ...
4
votes
1answer
84 views

Vertical bar strangely moving in a complex block matrix macro (XeTeX or pdfTeX)

The following code: \documentclass[a4paper]{report} \usepackage{amsmath,amsfonts,amssymb,multirow} \usepackage{mathtools} \newcommand{\sq}[1]{\left[#1\right]} ...
1
vote
0answers
95 views

array and loop to set frametitle, subsection, and text

In the example below, I store text into three variables (\subTa, \subTb, \subTc), and then use these variables to set the subsection, set the frametitle, and display text on each slide, all using ...
6
votes
1answer
197 views

Combining rows and columns in array

I am trying to write some kind of blockmatrix \[A_n= \left( \begin{array}{cc|cc} && 0 & 0 \\ & A_{n-2}&n-2&0 \\ \hline\\ 0&-n+2&1&n-1 \\ ...
2
votes
1answer
276 views

Wrap equation to new line, in array environment

Is it possible to wrap an equation to a new line (such as in How to wrap a long equation in latex but within an array environment? I have a column vector of regressors that I want to show over two ...
4
votes
1answer
74 views

how to adjust array inside 50% of linewidth

I've couple of tables drawn using array; one of the sample is mentioned below: How can I automatically adjust table to get fit inside 50% of line-width? $\displaystyle ...
1
vote
0answers
113 views

radix sort tikz [closed]

I want to visualize Radix sort to look like but I can't find a way based on this Thanks in advance
1
vote
1answer
290 views

Displaying long division manually with some caveats [closed]

Due to odd circumstances, I need to present long division manually (in math mode). That is, without using a macro. Moreover, I cannot use \multicolumn or \cline. Normally, I would do: \[ ...
5
votes
1answer
1k views

`missing $ inserted` Error when not putting $ before and after array environment

Considering this answer I added $ before and after the array, i. e. before \begin{array} and after \end{array} in the following code. Then the former missing $ inserted Error was gone. ...
3
votes
1answer
88 views

Creating Table using array

I'm trying to create entry similar to tables using array begin{array}{*{20}{r}} {}| & A |& B \\ \hline A_1| & {one|} & {two} \\ B_2| & {three|} & {four} \\ \hline ...
5
votes
2answers
100 views

Array spacing in multiple line environment

Consider the following MWE \documentclass{article} \usepackage{amsmath} \begin{document} \begin{gather*} \renewcommand{\arraystretch}{1.2} \begin{pmatrix} \frac{1}{2} \\ \frac{1}{2} \end{pmatrix} ...
0
votes
0answers
90 views

Equivalent of Latable for matrix/vectors generation

Does anyone know an equivalent for Latable (which is used to generate latex code for tables) but to do the same thing with matrices and arrays ?
3
votes
1answer
96 views

Center array headers but right justify numbers in columns

I'd like to center my headers but right-justify the numbers in the columns. \begin{array}{c|c|c|c|c|c} x & y & (x-\overline{x}) & (y-\overline{y}) & (x-\overline{x})(y-\overline{y}) ...
7
votes
1answer
230 views

Matrix derivation

I would like to display a matrix with a dot (derivative) on top of it. The entry of this matrix shall consist of arbitrary symbols. When I write \begin{align} \dot{\begin{pmatrix} x \\ y ...
2
votes
1answer
313 views

tikz array indexing to paint with custom palette

I have a custom palette which I want to paint with it by indexing. Here is my attempt: \documentclass{standalone} \usepackage{tikz} \begin{document} \begin{tikzpicture} \def\colorPallete{{0.00 ...
6
votes
3answers
1k views

Integral sign inside equation array becomes too small

\documentclass[12pt,a4paper]{report} \usepackage{palatino} \begin{document} \begin{equation}\label{good} \int_{0}^{1} \end{equation} \begin{equation}\label{ugly} \begin{array}{c} \int_{0}^{1}\\ ...
6
votes
2answers
115 views

How to make the this brace bigger? “}”

here is my code: \begin{equation*} \left . \substack{ 2 \beta_{r,j}^{(l)} = \beta_{r,j}^{l-1} + \beta_{R+r,j}^{(l-1)} \epsilon_{m}^{j} \\ 2 \beta_{r,m+j}^{(l)} = ...
31
votes
3answers
1k views

Programming Conway's Game of Life in LaTeX

My aim is to program Conway's Game of Life in LaTeX, and make the output into an animated PDF. I intend to use PGF/TikZ for this, especially pgfmath, but I'm stuck at the moment because I need to ...
1
vote
0answers
31 views

“]” not working [duplicate]

I tried to compile something like the following but it is not compiling: $$ \begin{array}{ccc} [u,v]=0&,&\text{if bla}\\ [u,v]=0&,&1 \end{array} $$ I also tried ...