INNER CODE UNIT · Python

gamma

ssebastianmag/hydrogen-wavefunctions · hwf_plots.py:134

    gamma = max(0.10, 1.0 / (1.0 + exp))

    norm_linear = colors.Normalize(vmin=vmin, vmax=vmax, clip=True)
    norm_exposed = colors.PowerNorm(gamma=gamma, vmin=vmin, vmax=vmax, clip=True)
    norm = norm_exposed if exp > 0.0 else norm_linear

    im = ax.imshow(P, extent=extent, origin="lower", aspect="equal", cmap=cmap, norm=norm)

    # Axis labels
    x_z_units = r"a_\mu" if wf.use_reduced_mass else r"a_0"
    ax.set_xlabel(rf"$x / {x_z_units}$", fontsize=43, color=text_color)
    ax.set_ylabel(rf"$z / {x_z_units}$", fontsize=45, color=text_color)
    ax.xaxis.set_label_coords(x=0.5, y=-0.075)
    ax.yaxis.set_label_coords(x=-0.08, y=0.5)

    # Title and subtitle
    ax.set_title(
        "Hydrogen Wavefunction - Probability Density",

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…