Questions tagged [arrays]

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

Filter by
Sorted by
Tagged with
0
votes
0answers
16 views

Arrays cutoff in multicol - 2 columns

The Problem Hey, I spent about 3 hours trying to solve this problem with multicol in LaTeX. Hope it would help some people out: arrays cuttoff in LaTeX So as you could see, my arrays in the \align* ...
1
vote
3answers
77 views

\rowcolor and @{} issue

In the next example we can see that \rowcolor does not take into account the declaration @{} in tabular preambles. Is this a normal behavior? Is there some elegant way to avoid that spurious filled ...
1
vote
1answer
20 views

How to put the caption of a subfigure in table style (or array style)

I have the following code to put some figures alongside. \begin{figure*}[!htb]{ \subfigure[test]{\label{fig:test}\includegraphics[scale=0.3]{test.pdf}} \end{figure*} This code works correctly. I ...
11
votes
5answers
6k views

Border matrix with multiple indices on top and bottom

How can I write a matrix where there is an index at the top and also at the bottom? \bordermatrix doesn't seem to have an option for multiple indices.
3
votes
2answers
115 views

Table (or similar) of numbered displayed math

I want to refer to a "table" of equations, but I want every "cell" to be numbered. All answers I have seen of anything similar deal with numbering lines, but I'd like to number ...
1
vote
2answers
22 views

align in array causes right shift

Compile the code: \documentclass{article} \usepackage{enumitem,amssymb} \usepackage{amsmath} \usepackage{multicol} \usepackage{hyperref} \usepackage{multirow} \usepackage{xcolor} \usepackage{array} \...
1
vote
0answers
21 views

How to add a large equation in Latex (problem with \right] \left[) [duplicate]

I want to add this equation to my letter, but it doesn't fit the page: $$ I_{GRV3}=\int_{\Sigma_{i}}\left[4 \pi S_{i}^{i}-v^{\mid i} v_{\mid i}+\frac{1}{4} h^{i j}\left(\Delta_{i m}^{l} \Delta_{j l}^{...
1
vote
1answer
38 views

Why put the dollar sign before and after the array environment

So I am trying to type in a table ducumenting different mathematical equations under different heading, something like this: and it is suggested to me that array environment is better than table ...
3
votes
2answers
33 views

Alignment of 3 arrays: first on left, second on top-right and third on bottom-right

I am having 3 arrays with different dimensions. I want to place the first array on the left, second on the top-right and third on the bottom right. So, far I am able to place only two arrays, below is ...
5
votes
3answers
84 views

Adding arrayrulecolor command removes top rule

The code below results in the image below. \documentclass{beamer} \usetheme{Montpellier} \usecolortheme[named=gray]{structure} \usepackage{colortbl} \usepackage{array} \newcommand{\gr}[1]{\textcolor{...
0
votes
1answer
51 views

Procedure to produce a Latex source modifable Latex file from initially a MS Word table

Sorry to post again from the same subject I posted a few days ago. I have had an answer but impossible to reproduce the generation of a Latex source from a docx MS Word document. So, I attempt here on ...
0
votes
2answers
57 views

multine line array in table cell

\begin{table} \centering \renewcommand{\arraystretch}{1.3} \begin{tabular}{c | l} Group element & $\begin{array} {r@{}l@{}} U(\xi) & {}= e^{\xi^a P_a} \\ U(\Lambda) & {}= e^{-\frac{1}{2}\...
1
vote
2answers
30 views

I can't change \hhline color with \arrayrulecolor{}

I have created a table with tabular and cellcolor, and you know what hapends: the cell color overlap the border. I have found that this is often solved with hhline. In order to change the color in ...
3
votes
1answer
37 views

Refinement of nested cases / aligned equations

For the following two approaches or sets of equations, I would like to 1- (in the first set) make the first for align with the two fors below 2- (in the second set) keep the font and interspaces the ...
0
votes
0answers
21 views

csvsimple inside tabular environment, but csv data includes LaTeX arrays/tables/aligned etc

I am trying to import a csv using csvsimple, and I have already overcome the challenge of the csv delimiter (by adding curly braces around every field), but I am now stuck with a admittedly weird ...
5
votes
3answers
163 views

Issue with the alignment of the array

I am having the issue with the alignment of an array. Please, find the below code: \documentclass[12 pt, a4paper]{book} \usepackage{multicol} \usepackage{geometry} \geometry{ a4paper, ...
4
votes
5answers
276 views

How to change the vertical position of a horizontal line in a matrix?

I need to adjust the vertical position of a horizontal line inside a matrix. Here's a MWE code to play with: \documentclass[11pt,letterpaper,twoside]{book} \usepackage[T1]{fontenc} \usepackage{...
1
vote
3answers
32 views

Alignment at equals signs in two columns of an array environment

I would like to make a table of two columns of the squares of all the digits. With the following code, there is no proper spacing between the equals sign and the numbers in the first column, and the ...
1
vote
0answers
22 views

Vertical space at the bottom of nested tabulars

I'm trying to make a macro which typeset a text "accross a vertical line", and I'm using a tabular for that : \documentclass{article} \begin{document} \makeatletter \newlength\tdv@temp \...
5
votes
2answers
158 views

How can I improve displaying repetitive equations

I'm looking to improve my report quality by making equations more clear. As the equations I'm stating are repetitive a couple of times throughout the report I thought it would be better to use matrix ...
2
votes
1answer
29 views

Place arrays one next to the other with caption and shape value

I have the following code snippet executed on Overleaf, \documentclass{article} \usepackage[T1]{fontenc} \usepackage{mathtools,siunitx} \usepackage{amsmath} \title{test} \author{spanos.nikolaos } \...
0
votes
0answers
33 views

What is causing (and how can I fix) “Misplaced \cr” and “Misplaced alignment tab” errors in an array environment when trying to compile my .dtx?

I created a small package to help me typeset various tidbits in papers for a specific domain of theoretical computer science that I sometimes work in. So far, it has been working well, but I decided ...
0
votes
1answer
27 views

Internal delimiters for matrix and array

I would like to customize the array environment in such a way that I can write arrays with dashed delimiters that are internal to the arrays as in the figure below. Question. How do I place the ...
7
votes
1answer
198 views

delarray and colortbl issue

There seems to have a compatibility issue between the colortbl and delarray packages because when compiling the following code : \documentclass{article} \usepackage[T1]{fontenc} \usepackage[ansinew]{...
4
votes
1answer
104 views

Draw path only if condition is met

I am using TikZ and would like to draw a path from one node to another if a condition is met. Here is my code: \documentclass{article} \usepackage[utf8]{inputenc} \usepackage{tikz} \begin{document} \...
0
votes
1answer
18 views

pgfmathmin and pgfmathsetmacro and array

I am trying to calculate the minimum and maximum of an array. The only problem unsolved is to save the value in a macro/variable. \documentclass[utf8,fleqn]{scrartcl} \usepackage[ngerman]{babel} \...
2
votes
2answers
37 views

\baselineskip not working on array

I want to add a linebreak with distance proportional to \baselineskip in array environment, in order to make my document more stable to format change. However, it seems as \baselineskip is zero in ...
2
votes
2answers
32 views

How to align these objects in a function mapping

I'm trying to write a function mapping between three sets. I'd like to keep the alignment of the first "array" environment in the second one, because I'd like the tips and the tails of the ...
1
vote
4answers
87 views

How to put upward arrow with text below the elements of an array

I want to put upward arrow with text below some elements of an array. Code: \documentclass[12 pt, a4paper]{book} \usepackage{multicol} \usepackage{geometry} \geometry{ a4paper, ...
2
votes
2answers
28 views

How to vertically center all elements of array

I want to put all elements of the array vertically centered. I have tried \arraystretch command to do so, but it is not working. Code: \documentclass[12 pt, a4paper]{book} \usepackage{multicol} \...
0
votes
1answer
90 views

Aligning linear system in optimization problem

There are a lot of similar problems I found on stackexchange, but none quite worked for my problem. Given an objective function and a set of (in-)equalities, I want to neatly align the variables in ...
1
vote
0answers
51 views

table into page width in a double columns page [closed]

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 !...
0
votes
1answer
36 views

Align, multiline, … more equationsymbols in one line under each other

I could not find a method to use \begin{align} or the other similar commands, s.t. in one line ist not only one = symbol, they are more. And I want arrange the equality sign under each other. No ...
2
votes
2answers
24 views

Remove whitespace left of an array

I would like to display equations one on top of the other with a large brace on the left, with the array environment for instance. However, there always is a consequential white space between the ...
2
votes
2answers
43 views

Aligning a group of muti-line equations within along align environment

I'm trying to get 3 really long equations (that I've split) to be aligned more elegantly with their respective equal signs in some way. Shortening the LHS of those 3 equalities (perhaps splitting it 3 ...
2
votes
2answers
59 views

Using align* and array together to show relationship between matrix and system

I am trying to align an entire matrix with a system of equations with an arrow between them. Here is what I have so far, \begin{align*} \left[\begin{array}{ccc|c} 1 & 0 & 0 & \...
2
votes
3answers
70 views

How to programmatically insert an \hline between each line of an array

I'm trying to create an environment for matrices that are divided in four sections, such as the following: Ideally, I'd like to make it so that it can be used like the following: M = \left( \begin{...
0
votes
1answer
21 views

Partioned/block matrices with “empty” cells

I am trying to create a matrix like the following where notice that I envision it as a 4x4 matrix, with 4 blocks, one 1x1 block, one 3x1 block, one 1x3 block, and one 3x3 matrix. My confusion in ...
0
votes
1answer
28 views

Left align entire array environment

I want to create a notation section a la the Matrix Cookbook (PDF). Here's a screenshot: I can create this using an array, so \begin{array}{r l} but then the whole array is centered. How can I left ...
1
vote
0answers
24 views

Adjusting Column Widths in Tables

I'm new to Latex and struggling with adjusting the widths of a few columns in a Table. From the table attached here, I just need columns 2 & 4 to be reduced so that column 5 can be enlarged. Here ...
1
vote
1answer
65 views

`\readlist{}` inside a table not working

I am writing a package, which contains the following code as its part. The problem is \readlist inside longtable environment. When I write the code, not as a macro but in the main body it works, in ...
2
votes
1answer
22 views

aligning addition symbols in array

I have been trying to figure out how to put addition symbols in between each of the following characters for this code: \begin{equation} \begin{array}{c|ccccc} &a_0 &...
0
votes
1answer
19 views

array/matrix specify default alignment

normally you write a matrix something like this \begin{align*} \begin{pmatrix} ele1 & ele2 & ele3 \\ longEle1 & longEle2 & longEle3 \end{pmatrix} \end{align*} ...
1
vote
2answers
94 views

! LaTeX Error: Illegal character in array arg

I'm having the following error message ABD: EveryShipout initializing macros geometry driver: auto-detecting geometry detected driver: pdftex No file main.bbl. ! LaTeX Error: Illegal ...
3
votes
1answer
35 views

array environment: missing $ inserted and some other issues

I have the following code: \begin{array}{cc|c|c|} & & \multicolumn{2}{c}{odd} \\ & & 0 & 1 \\ \cline{3-4} \multirow{2}{*}{even} & 0 & $(+1,-1)$ & $(-...
1
vote
3answers
51 views

How to prevent superscript getting too close to line above

The below code is working but the superscript H appears to be too close to the line above. How can I put some space in between the H and the line right above it? Thx. \documentclass{article} \...
0
votes
1answer
23 views

“missing { inserted” what was the problem

I basically copy pasted an example from here Yet it won't compile. I would really appreciate some help here \documentclass{article} \usepackage{array} \begin{document} \begin{tabular}% {>{\ttfamily\...
2
votes
3answers
54 views

Diagonal dashed line in array

I would like to have a diagonal dashed line in an array cell. In the example, it should replace \ddot. For me, \ddot is inconvenient since I already use dots with different meaning. \documentclass{...
3
votes
2answers
104 views

Highlight sub array of tikzpicture generate array

In the generated 28 x 28 array of circles from the given code, I wanted to be able to highlight a specific sub array and have the respective arrows pointing out as follows: Here is the code I have so ...
-1
votes
2answers
131 views

Help me typeset math formulas!

I want to type these but i just don't know how to do it. Here are the pictures: Please give me the code to each one of them. Thank you all in advance.

1
2 3 4 5
17