Skip to content

Instantly share code, notes, and snippets.

View Rodbourn's full-sized avatar

Charles Rodbourn Cook, PhD Rodbourn

View GitHub Profile
@Rodbourn
Rodbourn / gist:2a00499f8b6586f08403db193124067e
Created July 2, 2026 21:25
Fable departure skill creation
You are a distinguished fellow on this project who is retiring. Your final task: build a
complete skill library under `.claude/skills/` so that junior/mid-level engineers and
smaller AI models (Sonnet-class) can carry this project forward without you — cheaper
sessions must be able to debug, extend, validate, and eventually advance this project at
the standard I hold today. Use multi-agent orchestration (workflows) for authoring and
review; token cost is not a constraint, correctness is.
## Phase 1 — Discover before you write (no skill authoring yet)
Investigate the repo like an incoming principal engineer: README/manifest/contributor
docs, the build system, the test suite and how it's actually run, CI config, docs
"""
1D Finite Difference Solver
This module provides a high-performance, flexible implementation of the 1D finite difference
method for solving partial differential equations. It uses advanced numerical techniques
and adheres to best practices in scientific computing and Python development.
Features:
- Supports various boundary conditions (Dirichlet, Neumann, periodic)
- Implements multiple time-stepping schemes (explicit, implicit, Crank-Nicolson)
import numpy as np
import matplotlib.pyplot as plt
def heat_equation_1d(L, nx, nt, alpha, T_initial, T_left, T_right):
"""
Solve the 1D heat equation using explicit finite difference method.
Parameters:
L : float
Length of the domain
import numpy as np
from scipy import linalg
from scipy.interpolate import interp1d
import matplotlib.pyplot as plt
from typing import Callable, Tuple, List
from dataclasses import dataclass
@dataclass
class FDCoefficients:
"""Dataclass to store finite difference coefficients and related information."""
import numpy as np
from scipy.sparse import diags
from scipy.sparse.linalg import spsolve
def finite_difference_fit(x, y, order=2):
"""
Implement an arbitrary order one-dimensional finite difference scheme
to fit a given set of data points.
Parameters:
@Rodbourn
Rodbourn / IEdmModelToCsdlJson.cs
Created December 4, 2019 10:22
Convert Microsoft.Data.Edm.IEdmModel to CSDL JSON suited for breezejs.
using System.IO;
using System.Linq;
using System.Text;
using System.Xml;
using Microsoft.Data.Edm;
using Microsoft.Data.Edm.Csdl;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using Formatting = Newtonsoft.Json.Formatting;
@Rodbourn
Rodbourn / reclaimWindows10.ps1
Last active January 6, 2017 13:05 — forked from alirobe/reclaimWindows10.ps1
"Reclaim Windows 10" turns off a bunch of unnecessary Windows 10 telemetery, removes bloatware, and privacy invasions. Review and tweak before running. Scripts for reversing are included and commented. Fork via https://github.com/Disassembler0 (different defaults)
##########
# Win10 Initial Setup Script
# Author: Disassembler <disassembler@dasm.cz>
# Version: 1.7, 2016-08-15
# dasm's script: https://github.com/Disassembler0/Win10-Initial-Setup-Script/
# THIS IS A PERSONALIZED VERSION
# This script leaves more MS defaults on, including MS security features.
# Tweaked based on personal preferences for @alirobe 2016-11-16 - v1.7.1