Skip to content

Instantly share code, notes, and snippets.

View adcroft's full-sized avatar

Alistair Adcroft adcroft

View GitHub Profile
@adcroft
adcroft / Lagrangian-remap schematic.ipynb
Created November 1, 2019 17:37
OWG/Lagrangian-remap schematic.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Quadrature example and converge test.ipynb
Created June 16, 2019 21:52
Examples of quadrature and test of convergence
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Interpolating with Lagrange polynomials.ipynb
Last active December 1, 2023 15:55
Interpolation with Lagrange cubic polynomial
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / IPCC resolution v time.ipynb
Last active November 3, 2020 22:36
GitHub/space-time-scale-schematics/IPCC resolution v time.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Tracks via list.ipynb
Created October 10, 2018 12:40
Tracks via list.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / fetch_woa13_sst.py
Created February 15, 2018 18:37
Generate test netCDF data files using the various versions of the netCDF file format
import netCDF4
import numpy
def data_url(period):
"""Returns url to OpenDAP data corresponding to WOA13 5-degree ocean temperature for given period"""
return 'https://data.nodc.noaa.gov/thredds/dodsC/woa/WOA13/DATAv2/temperature/netcdf/decav/1.00/woa13_decav_t%2.2i_01v2.nc'%(period)
def create_local_file(file_name, form, nc):
"""Creates local file "file_name" and places SST data from nc in it."""
new_file = netCDF4.Dataset(file_name, 'w', format=form)
@adcroft
adcroft / Fill missing data with zonal periodicity and Neumann conditions applied at poles and land boundaries.ipynb
Last active February 15, 2018 14:52
Fills missing data with zonal periodicity and Neumann conditions applied at poles and land boundaries
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Time-space scales in atmosphere and ocean.ipynb
Created January 17, 2018 01:18
Schematics of space and time scales for a range of atmospheric and oceanic processes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Analysis of NCAR 1-degree grid.ipynb
Last active July 26, 2017 20:58
Analysis of NCAR 1-degree grid.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@adcroft
adcroft / Interpolating+on+non-uniform+quad-mesh.ipynb
Created April 10, 2017 18:33
Interpolating on a non-uniform quad-mesh
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.