6k views

### How to easily write the transpose of a matrix? [duplicate]

I have a matrix A, described using an environment bmatrix as in the MWE below. \documentclass{article} \begin{document} Consider the matrix \$A=\begin{bmatrix} 1 & 0 & -1 \\ 2 & 3 &...
7k views

### Perform matrix operations (addition, product, transpose, etc.) in LaTeX?

I know the calc package can perform infix-notation arithmetic in LaTeX... but I want more! I'd like to perform (not necessarily infix-notation) linear-algebra operations such as scalar ...
5k views

### How to do mathematical programming in LaTeX?

I typically write my programs in Matlab and then port the picture into LaTeX. At times it appears that one has better efficiency or flexibility to have the program within LaTeX itself, either you ...
20k views

### tabular input by columns (i.e. transpose a table)

I would like to be able to transpose a tabular(x) table like in the following example. It is not necessary to be completely automated, but I don't want to change the data order, which is a painful and ...
3k views

### Problem with defining shortcuts for TikZ matrices

For answering a question yesterday I wanted to define a shortcut for creating a matrix inside a tikzpicture. As a minimal example, consider \newcommand\mymatrix[1]{ \begin{tikzpicture} \...
654 views

### Plotting function ℝ² →ℝ with pole at (0,0) smoothly

I would like to plot the function f: ℝ² →ℝ, definited by f(x,y)=(xy)/(x^2+y^2). But the following problem comes up: At (0,0) the function is not continous and therefore it looks kind of jagged. To ...
1k views

### Setting up a quadratic-equation factoring worksheet: How to get rid of unwanted zeroes & ones?

I am in the midst of my second attempt to create basic high school factoring worksheets. Next up is figuring out how to reject unwanted zeroes and ones. The following code generates simple trinomial ...
13k views

### How to print a LaTeX matrix using xtable in R

I'm trying to get R to print a matrix as a LaTeX matrix using xtable, using the LaTeX environment bmatrix. a <- matrix(rnorm(25), 5 ,5) x <- xtable(x) > print(x, floating=FALSE, tabular....
2k views

### Generating a worksheet

My objective is to be able to generate worksheets in categories like: Laws of Indices Simultaneous Linear equations and Quadratic equations When I say generate is to generate for example 20 ...
1k views

### Is it possible to exchange rows and columns of a table without retyping

I wrote a table that turned out to be too wide. So I have to turn it sideways for it to fit a typical journal paper. Is there a way I can avoid typing it all over again?!
474 views

### Symbolic 3d coordinates in TikZ

Warning: answering this question may require some efforts. The purpose of question is to "teach TikZ 3d coordinates". What does that mean? If we define a coordinate in TikZ, \path (<x>,<y&...
128 views

### Automatically use \cr or & (for matrices) in macro?

I'm trying to write a macro to abstract different possible representations of matrices. In particular, we're changing whether we want to represent a particular matrix as a column or row vector. My ...
195 views

### Best practice for plots (pgfplots, gnuplot, etc.)

I am writing a fairly large article with a lot of different plots. They range from simple ones like abs(x) or x^2 to high-polynomials with their first and second derivative, and nonlinearities (...