times(x: number,y: number,): number
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
times(x: number,y: array,): array
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
y: array
The second operand
The result of element-wise multiplication
times(x: array,y: number,): array
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
x: array
The first operand
The result of element-wise multiplication
times(): array
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
The result of element-wise multiplication
times(x: number,y: matrix,): matrix
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
y: matrix
The second operand
The result of element-wise multiplication
times(x: matrix,y: number,): matrix
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
x: matrix
The first operand
The result of element-wise multiplication
times(): matrix
Element-wise multiplication of arrays, matrices, or numbers.
Performs element-by-element multiplication. X and Y must have the same dimensions unless one is a number.
Element-wise multiplication of two vectors
Element-wise multiplication of two vectors
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], [3, -1, 0]), [15, -6, 0]);
Multiply a number with each element of an array
Multiply a number with each element of an array
import { assertEquals } from "jsr:@std/assert"; assertEquals(times([5, 6, 4], 10), [50, 60, 40]);
The result of element-wise multiplication