Math Structures: Matrices, Vectors, and Case Systems

In Corca, structures are not formatting elements. They are containers that hold expressions. You can edit, resize, and reorganize them without breaking the surrounding math. Existing values remain intact when the structure changes.

Matrices

A matrix is a rectangular arrangement of numbers or expressions: (1234) the 2 by 2 matrix Row 1: 1 2 Row 2: 3 4.

Creating a matrix

You can create a matrix using natural typing or structural insertion. For example, typing matrix produces a two-by-two matrix: () the 2 by 2 matrix Row 1: blank blank Row 2: blank blank.

Each box represents an editable cell where you can enter numbers, variables, or expressions.

Another way, is just open parentheses and start typing. Shift+Space adds a new column, Shift+Enter adds a new line.

Resizing a matrix

Rows and columns can be inserted or removed without rewriting the matrix. For example, adding a column into the matrix (1234) the 2 by 2 matrix Row 1: 1 2 Row 2: 3 4 produces (1234) the 2 by 3 matrix Row 1: 1 2 blank Row 2: 3 4 blank.

Vectors

Vectors can be represented as rows or columns and are commonly used in coordinate systems, physics, and machine learning.

Column vectors

A column vector is written as a vertical list of elements. Example: (123) the 3 by 1 column matrix 1 2 3. Column vectors are frequently used to represent coordinates, forces, or parameter sets.

Row vectors

A row vector is written as a horizontal list of elements. Example: (123) the 1 by 3 row matrix 1 2 3. Row vectors behave like single-row matrices and can participate in matrix multiplication and transformations.

Case system

A system of equations groups multiple equations into a single structure. This format is commonly used to represent constraints, relationships, and simultaneous equations:

{x+y=5x−y=1 2 cases Case 1: x plus y equals 5 Case 2: x minus y equals 1

Each equation remains editable and aligned automatically.

To create a system of equations in Corca, just type Cases System and choose the one from suggestions.

Cases environments

Cases structures represent piecewise definitions. They are commonly used to define functions that behave differently under different conditions.

Example:

ƒ⁡(x)={x2x≥0−xx<0 f with hook of x equals 2 cases Case 1: x squared x is greater than or equal to 0 Case 2: negative x x is less than 0

Each branch remains editable and aligned automatically.

Previous: Integrals