% Pauli operators and Hamiltonian for a two-level atom (Sec. III.C) % H = (hbar*omega_0/2) sigma_z % sigma_+ raises (|g> -> |e>) and sigma_- lowers (|e> -> |g>). clear; % Clear memory clc; % Clear the command window/screen hbar = 1; Omega_0 = 1; % atomic transition frequency Sz = [1 0; 0 -1] % sigma_z operator Splus = [0 1; 0 0] % raising operator sigma_+ Sminus = [0 0; 1 0] % lowering operator sigma_- H = hbar*Omega_0/2*Sz % Hamiltonian for a two-level atom