Entries by Mark44

AVX-512 Programming: Extracting Column Subtotals from a Table

In this Insights article I’ll present an example that shows how Intel® AVX-512 instructions can be used to read a whole row of data in a single operation, and then generate subtotals for some or all of the columns of that table. To motivate the example, I’ll use a table of household expenses in several…

AVX-512 Assembly Programming: Opmask Registers for Conditional Arithmetic Conclusion

In the first part of this article (AVX-512 Assembly Programing – Opmask Registers for Conditional Arithmetic), we looked at how opmask registers can be used to perform conditional arithmetic. That article ended with two 512-bit ZMM registers that each contained 16 integer values. One of the registers contained 16 partial sums of the positive numbers…

AVX-512 Assembly Programming: Opmask Registers for Conditional Arithmetic

This is the second installment in a continuing series of articles on Intel AVX-512 assembly programming. The first installment is An Intro to AVX-512 Assembly Programming. Problem If you have an array (Array), that contains ArrLen signed integers, how would you find the sums of the positive and negative numbers in the array? A Solution…

An Intro to AVX-512 Assembly Programming

History In 1998, the Intel Corporation released processors that supported SIMD (single instruction, multiple data) instructions, enabling processors to carry out multiple arithmetic operations using one instruction. This technology was a first step toward parallelization at the instruction level.  The technology, SSE (Streaming SIMD Extensions), made it possible to perform arithmetic operations on four pairs…

Why Can’t My Computer Do Simple Arithmetic?

The first computer I owned was an Apple IIe computer, with a CPU that ran at slightly over 1 Megahertz (MHz), and with 64 Kilobytes (KB) of RAM, together with two 5 1/4″ floppy drives that could each store 140 Kilobytes (KB) of data. My current computer (which cost about the same as the Apple computer) is vastly more…

What Are Eigenvectors and Eigenvalues?

Two important concepts in Linear Algebra are eigenvectors and eigenvalues for a linear transformation that is represented by a square matrix. Besides being useful in mathematics for solving systems of linear differential equations, diagonalizing matrices, and other applications, eigenvectors and eigenvalues are used in quantum mechanics and molecular physics, chemistry, geology, and many other scientific disciplines. Some definitions: An eigenvector for…

Partial Fractions Decomposition

Partial fractions decomposition is an algebraic technique that can be used to decompose (break down) a product of rational expressions into a sum of simpler rational expressions. A rational expression is one in which both the numerator and denominator are polynomials. A proper rational expression is one in which the degree of the numerator is strictly less than the degree…

Solving Nonhomogeneous Linear ODEs using Annihilators

My previous Insights article, Solving Homogeneous Linear ODEs using Annihilators, discussed several examples of homogeneous differential equations, equations of the form F(y, y’, y”, …) = 0. In this Insights article we will look at equations of the form F(y, y’, y”, …) = g(t), for certain functions g. Ex. 1: y” – 4y’ + 3y…

Solving Homogeneous Linear ODEs using Annihilators

In this Insights article we’ll look at a limited class of ordinary differential equations — homogeneous linear ODES with constant coefficients. Although there are many differential equations that are outside the scope of this article, there are many applications in mechanics and electronics of the types of differential equations we’ll be looking at. Homogeneous Equations A…

Simple Python Debugging with Pdb: Part 2

This Insight article is the continuation of the first article, Simple Python Debugging with Pdb: Part 1. In this article, let’s look at another important capability of debuggers: breakpoints. When you set a breakpoint in a program, the debugger executes all of the code up to the breakpoint, and then halts. This allows you to inspect variables…

Simple Python Debugging with Pdb: Part 1

I’m pretty new with Python, so I was looking around for some debugging tools. At first I dismissed Pdb (Python debugger) as being too primitive, but after seeing a blog post about using Pdb, I decided that I should give it a try. To get started with Pdb import the pdb module insert a call…