Posts

DFT Noise Filtering

In this UW AMATH582 assignment we are provided with noisy acoustic submarine positioning data. The data comprises discrete time measurements made at half hour increments organized into a 4D array. Each time frame is a 3D array of cartesian coordinates containing the acoustically detected intensity volume. The data is transformed into reciprocal space by 3D FFT. Averaging the transformed signal increases the signal to noise ratio and allows discovery of the frequency "signature". In reciprocal space, the frequency volume containing the signal remains centered at the same position regardless of time index while the signal position in lab space follows a trajectory. The fixed location of the center frequency in reciprocal space allows placement of a Gaussian filter centered at the central frequency component. Each time frame is FFT 3D transformed, filtered in k space and subsequently transformed back. The resulting denoised echo is now positioned by a simple maximum allowing th...

Fourier Transform of Single Frequency Sines and Cosines

Image
Fourier Transform Of Single Frequency Sines And Cosines The Fourier transform (FT) of function $f(x)$ is defined as follows: $$ F(k) = \frac{1}{\sqrt{2 \pi}} \int_{-\infty}^{\infty} f(x) e^{-ikx} dx $$ The FT is dervived from a Fourier series in complex notation. The Fourier series expands a function into a weighted set of orthogonal basis functions. In case of the FT, the basis functions are sines and cosines. Sines and cosines are periodic on $2\pi$ meaning that the functions repeat themselves at increments of $2 \pi$. The principle idea is that we can represent most functions as a linear combination - a weighted sum - of sine and cosine basis functions. When a function of time $t$ is Fourier transformed, the components of the FT correspond to frequencies of the basis sines and cosines. Frequency is proportional to inverse time. The FT space is often called reciprocal space. If the function transformed were a function of position $x$, the FT is a function of inverse position. I...

Virus Spread PDE Dynamic Model

The video in this post is the result of a dynamics simulation of virus spread in California. Blue color is susceptible population, red is virus density in the environment and green indicates recovered (presumed immune) population. The model numerically integrates a set of partial differential equations that describe the process of infection, recovery contamination, etc. Population density is from census data. You may wish to use the "full screen" option to get a better view.

Matrix Calculus - Intro

Matrix Calculus Applied math very often involves matrix calculus. It is therefore a good idea to review some matrix calculus basics before diving into project specific solutions. It easier to learn the basics first and they are surprisingly simple to learn. A lot can be accomplished with a few intuitions and some notation. Tensors, matrices, vectors and scalars You can view all of these variables as tensors of differing rank. A rank $0$ tensor is scalar while a rank $1$ tensor is a vector and a rank $2$ tensor is a matrix. $$ \begin{array}{c c c} & tensor \ rank & example \\ scalar & 0 & x\\ vector & 1 & \begin{pmatrix} x_1 \\ x_2 \end{pmatrix} \\ matrix & 2 & \begin{pmatrix} x_{11} & x_{12} \\ x_{21} & x_{22} \end{pmatrix} \\ tensor & 3+ &\\ \end{array} $$ Vector and scalar valued functions We are likely all familiar with single valued functions of one variable : $$ f(x) $$ The value of the function $f$ depends on the i...

Guide To Walter Rudin's Principles, 1.17, 1.18 (Proof Details)

1.17: The definitions of an ordered field $F$, for $x,y,z \in F$ [i] $x+y \lt x+z$ if $y\lt z$ [ii] $xy \gt 0$ if $x\gt 0 \land y \gt 0$ Review the basic rules of working with inequalities. 1.18.a. Prove $x \gt 0 \implies -x \lt 0$ $$ \begin{array}{l c} x \gt 0 & \\ -x + x \gt -x + 0 & \\ 0 \gt -x & \end{array} $$ 1.18.b. Prove $x\gt 0 \land y \lt z \implies xy \lt xz$ $$ \begin{array}{l c} y \lt z & \\ y-y \lt z-y & \\ 0 \lt z-y & \\ 0x \lt (z-y)x & (?\times x) \ since \ x \gt 0 \\ 0 \lt zx - yx & \\ yx \lt zx -yx + yx & \\ yx \lt zx \end{array} $$ 1.18.c. Prove $x\lt 0 \land y \lt z \implies xy \gt xz$ $$ \begin{array}{l c} y \lt z & \\ y-y \lt z-y & \\ 0 \lt z-y & \\ 0x \lt -(x(z-y)) & \ since \ x \lt 0 \\ 0x \lt (-x)(z-y) & 1.16.c \\ 0 \lt (-x)z + (-x)(-y) & \\ 0 \lt -xz + (-x)(-y) & \\ 0 \lt -xz + (-(-xy)) & \\ 0 \lt -xz + xy & \\ xz \...

Denseness And The Limit Of A Sequence - An Example

Imagine you are a certain distance from an objective. Lets say this distance is 16 units. You are allowed to make progress toward your objective by cutting the distance in half at any time, as many times as you like. When will you reach your objective? In order to answer this question we must evaluate a limit. But before doing that, we may ask ourselves another question: how many times can we divide the distance? The distance in this case, at each step, is a rational number. A rational number is a quotient of two whole numbers in the form n/m (hence the number system is denoted “Q”). So our problem is within Q, the set of rational numbers. Mathematically we have distance $d=\frac{16}{2^n}$ where n is our step number. At one step $d=8$, at 2 steps $d=4$, and then $2$,$1$,$\frac{1}{2}$,$\frac{1}{4}$, etc. Our progress, one step at the time, is called a sequence (in Q). A sequence means we can denumerate the step number $n$. We can assign an integer number to each step. It turns ou...

Guide To Walter Rudin's Principles, 1.15, 1.16 (Proof Details)

Rudin Principles 1.15.a. Prove: $x \not = 0 \land xy = xz \implies y=z$ $$ \begin{array}{l c} y =y & \\ y = y \times 1 & multiplicative \ identity\\ y = y \times (x \times x^{-1}) & multiplicative \ inverse \ x \times x^{-1} = 1 \\ y = (y \times x) \times x^{-1} & associativity \\ y = (z \times x) \times x^{-1} & substitute \ given \ xy=xz \\ y = z \times (x \times x^{-1}) & associative \ given \ xy=xz \\ y = z \times 1 & multiplicative \ inverse \\ y = z & multiplicative \ identity \end{array} $$ 1.15.b. Prove: $x \not = 0 \land xy = x \implies y=1$ $$ \begin{array}{l c} y = y & \\ y = y \times 1 & multiplicative \ identity\\ y = y \times (x \times x^{-1}) & multiplicative \ inverse \ x \times x^{-1} = 1 \\ y = (y \times x) \times x^{-1} & associativity \\ y = x \times x^{-1} & substitute \ given \ xy=x \\ y = 1 & multiplicative \ inverse \end{array} $$ 1.15.c. Prove: $x \not = 0 \land xy = 1 \imp...