image thumbnail

updated 3 months ago

Moving window standard deviation by John D'Errico

A (fast) windowed std on a time series (standard deviation, std, window)

movingstd(x,k,windowmode)

image thumbnail

updated 6 months ago

HPF - a big decimal class by John D'Errico

High precision floating point arithmetic, a new class written in MATLAB (hpf, multiple precision, big decimal)

Demo script for my High Precision Floating point decimal

hpf_regression_testing

DefaultDecimalBase(DBaseNew)

image thumbnail

updated 9 months ago

Variable Precision Integer Arithmetic by John D'Errico

Arithmetic with integers of fully arbitrary size. Arrays and vectors of vpi numbers are supported. (integer, biginteger, arithmetic)

demo_vpi

base2vpi(B,base)

bin2vpi(B)

image thumbnail

updated 9 months ago

nearestSPD by John D'Errico

Finding the nearest positive definite matrix (positive definite mat..., covariance matrix, covariance)

nearestSPD_demo

nearestSPD(A)

image thumbnail

updated 1 year ago

distance2curve by John D'Errico

Find the closest point on a (n-dimensional) curve to any given point or set of points (nearest, closest, distance)

distance2curve(curvexy,mapxy,interpmethod)

image thumbnail

updated 1 year ago

Inverse (integrated) gradient by John D'Errico

Vectorized & fully sparse 1-d, 2-d, & 3-d integrated gradients (integration, cumulative, gradient)

consolidator(x,y,aggregation_mode,tol)

intgrad1(fx,dx,f1,method)

intgrad2(fx,fy,dx,dy,f11)

image thumbnail

updated 1 year ago

Inhull by John D'Errico

Efficient test for points inside a convex hull in n dimensions (convex hull, inhull, hull)

inhull(testpts,xyz,tess,tol)

image thumbnail

updated 1 year ago

IPDM: Inter-Point Distance Matrix by John D'Errico

An efficient and accurate Inter-Point Distance Matrix (distance, interpoint, distances)

demo_ipdm

ipdm(data1,varargin)

image thumbnail

updated 1 year ago

interparc by John D'Errico

Distance based interpolation along a general curve in space (interpolation, spline, linear)

interparc(t,px,py,varargin)

image thumbnail

updated 1 year ago

inpaint_nans by John D'Errico

Interpolates (& extrapolates) NaN elements in a 2d array. (nan, inpainting, replace)

(nn(:,1)<1)|(nn(:,1)>n)|(nn(:,2)<1)|(nn(:,2)>m); nn(L,...

valid{ind}; end end

inpaint_nans_demo.m

image thumbnail

updated almost 2 years ago

The Fibonacci Sequence by John D'Errico

Efficient computation of Fibonacci and Lucas numbers (fibonacci, lucas, numbers)

fibonacciEvolution

fibonacci(n,modulus)

fibrecur(N)

image thumbnail

updated almost 2 years ago

FresnelS and FresnelC by John D'Errico

Efficient and accurate computation of the Fresnel sine and cosine integrals (fresnel, sine, cosine)

fresnelC(X,fresnelType)

fresnelS(X,fresnelType)

image thumbnail

updated 2 years ago

SLM - Shape Language Modeling by John D'Errico

Least squares spline modeling using shape primitives (spline, splines, cubic)

slm_tutorial

hermite2slm(harray)

lse(A,b,C,d,solverflag,weights)

image thumbnail

updated 2 years ago

fminsearchbnd, fminsearchcon by John D'Errico

Bound constrained optimization using fminsearch (optimization, fminsearch, constraint)

fminsearchbnd_demo

fminsearchcon_demo

[x,fval,exitflag,output]=fminsearchcon(fun,x0,LB,UB,A,b,n...

image thumbnail

updated 2 years ago

arclength by John D'Errico

Compute the arclength of a general curve in any number of dimensions (arclength, spline, curve)

arclength(px,py,varargin)

image thumbnail

updated 2 years ago

A suite of minimal bounding objects by John D'Errico

Suite of tools to compute minimal bounding circles, rectangles, triangles, spheres, incircles, etc. (miminum, bound, bounding)

incircle(x,y)

insphere(xyz,tri)

minboundcircle(x,y,hullflag)

image thumbnail

updated 2 years ago

putvar, uigetvar by John D'Errico

Move (get or put) variable(s) directly between a function workspace and the base workspace (variable, assign, assignin)

putvar(varargin)

uigetvar(variableclass)

image thumbnail

updated 2 years ago

polyfitn by John D'Errico

Polynomial modeling in 1 or n dimensions (polyfit, modeling, regression)

polyfitn_demo

polydern(p,diffvar)

polyfitn(indepvar,depvar,modelterms)

image thumbnail

updated almost 3 years ago

Adaptive Robust Numerical Differentiation by John D'Errico

Numerical derivative of an analytically supplied function, also gradient, Jacobian & Hessian (adaptive, differentiation, automatic)

derivest_demo

multivariable_calc_demo

derivest(fun,x0,varargin)

image thumbnail

updated almost 3 years ago

Optimization Tips and Tricks by John D'Errico

Tips and tricks for use of the optimization toolbox, linear and nonlinear regression. (optimization, examples, tutorial)

optimtips

[x,fval,exitflag,output]=fminsearchbnd(fun,x0,LB,UB,optio...

consolidator(x,y,aggregation_mode,tol)

image thumbnail

updated 3 years ago

INTERPNS by John D'Errico

N-dimensional simplicial interpolation (interp2, interpolation, interpolant)

interpns(V,Xi,nodelist,method)

image thumbnail

updated 3 years ago

Surface Fitting using gridfit by John D'Errico

Model 2-d surfaces from scattered data (approximation, interpolation, modeling)

gridfit_demo

gridfit(x,y,z,xnodes,ynodes,varargin)

test_main.m

image thumbnail

updated almost 4 years ago

LSE by John D'Errico

A linear least squares solver, subject to linear equality constraints (least squares, regression, linear regression)

lse(A,b,C,d,solverflag,weights)

image thumbnail

updated almost 4 years ago

Derivative-based Optimization by Nassim Khaled

Derivative-based Optimization using The Gradient Descent (gradient, descent, minimum)

Gradient_Descent_maximum.m

Gradient_Descent_minimum.m

image thumbnail

updated 4 years ago

allwords by John D'Errico

Parse a sentence or any string into distinct "words" (string, char, words)

allwords(str,sepchars)

image thumbnail

updated 4 years ago

factorpairs by John D'Errico

Generate all pairs of factors N = p*q, p <= q, for positive integer N (factor, factors, divisors)

factorpairs(N)

image thumbnail

updated almost 5 years ago

The divisors of a number, perfect, amicable, and sociable numbers by John D'Errico

Tools to work (and play) with the divisors of a number (divisors, aliquot parts, aliquot sum)

The aliquot parts of a number

aliquotparts(N)

aliquotsum(N,p)

image thumbnail

updated almost 5 years ago

Cold Colormap by Joseph Kirk

Creates a COLD colormap that complements the built-in HOT colormap (colormap, hot, cold)

cold(m)

image thumbnail

updated 5 years ago

Eigenshuffle by John D'Errico

Consistently sorted eigenvalue and eigenvector sequences (eigenvalues, eig, order)

eigenshuffle(Asequence)

image thumbnail

updated 5 years ago

Circulant matrix by John D'Errico

The circulant matrix generated from a vector as the first row (or first column) (circulant, matrix, toeplitz)

circulant(vec,direction)

image thumbnail

updated 5 years ago

Accurate polygon extension by Krispijn Scholte

Enlarges polygon by a specified range. Also generates internal polygons caused by intersections. (polygon, extend, extension)

extendPoly(Polygon,varargin)

image thumbnail

updated almost 6 years ago

Partitions of an integer by John D'Errico

List all partitions of an integer (partitions, integer, partition)

partitions_demo

partitions(total_sum,candidate_set,max_count,fixed_count)

image thumbnail

updated 6 years ago

(Block) tri-diagonal matrices by John D'Errico

Generate (block) tridiagonal matrices (block diagonal, tridiagonal, matrices)

blktridiag_demo

blktridiag(Amd,Asub,Asup,n)

image thumbnail

updated 6 years ago

Estimatenoise by John D'Errico

Noise variance estimation from a signal vector or array (noise, variance, estimation)

estimatenoise(X,varargin)

image thumbnail

updated 6 years ago

Movingslope by John D'Errico

Sliding window regression to compute slope estimates along a curve (slope, moving, sliding)

movingslope(vec,supportlength,modelorder,dt)

image thumbnail

updated 6 years ago

Consolidator by John D'Errico

Consolidates common elements in x (may be n-dimensional), aggregating corresponding y. (reduction, accumarray, interpolation)

consolidator(x,y,aggregation_mode,tol)

consolidator13(x,y,aggregation_mode,tol,tolerance_style)

consolidator13(x,y,aggregation_mode,tol,tolerance_style)

image thumbnail

updated almost 8 years ago

Nonlinear Regression Shapes by John D'Errico

Curve fitting, empirical modeling, and an appreciation of shape (regression, nonlinear regression, shape)

fminspleas(funlist,NLPstart,xdata,ydata,INLB,INUB,options)

bestiary.m

shapes.m

Contact us