Saturday, 10 April 2021

If you have a Canon DSLR try the webcam utility. The video quality is great, e.g. in Zoom or MS Teams. Link: https://t.co/Xp869lbAP0

— Jan Zwiener (@jnz_jan) April 4, 2021

Saturday, 10 April 2021

Cognitive scores of different tasks and the corresponding CO2 concentration. 1500 ppm are easily reached after 2h in a closed room.

— Jan Zwiener (@jnz_jan) April 10, 2021

Source: https://t.co/MNsuEIBMoK pic.twitter.com/rL4607eVQg

Saturday, 20 March 2021

Command line tool of the day: "mop" to track stock prices in a terminal window. https://t.co/Qv5J3AoNw2 pic.twitter.com/SZL28c0CFT

— Jan Zwiener (@jnz_jan) March 20, 2021

Saturday, 20 March 2021

Buy a pack of NFC sticker tags (from Amazon). iOS can trigger e.g. ssh commands just by going near the NFC tag.

— Jan Zwiener (@jnz_jan) March 6, 2021

Sunday, 7 October 2018

function [c] = savgol(m, nl, nr, ld) %SAVGOL Calculate Savitzky-Golay filter coefficients. % c = savgol(m,nl,nr,ld) % m is the order of the smoothing polynomial (positive integer) % nl number of left (past) data points (positive integer) % nr number of right (future) data points (positive integer) % ld is the order of the derivative desired. ld=0 for smoothing, % ld=1 for the filtered first derivate (needs to be divided % by the step size). m>=4 is recommended for derivatives. % % Example cubic smoothing: % f = [1 1.4 1.5 1.4 1.3]'; % example data % c = savgol(3, 2, 2, 0); % smooth with cubic polynomial % f_smooth = c'*f % smoothed value at index = 3 % % Example calculate first derivative with 2nd order polynomial: % f = [1 1.4 1.5 1.4 1]'; % example data % dt = 1.0; % example data step size % c1 = savgol(2, 4, 0, 1); % 1st derivate at rightmost position % df_dt = (c1'*f)/dt; % divide by step size assert(nl >= 0 && nr >= 0 && ld <= m && nl+nr >= m && ld >= 0); assert(mod(nl,1)==0 && mod(nr,1)==0 && mod(ld,1)==0 && mod(m,1)==0); i = -nl:nr; % rows of Vandermonde matrix j = 0:m; % columns of Vandermonde matrix A = i' .^ j; % Vandermonde design matrix: A(line, col) = i^j; K = (A'*A)\A'; % least squares: (A'*A)^(-1)*A' c = K(ld+1, :)'; % line 1 = smoothing, line 2 = 1st derivative ... end

Page: 1/13 | Older entries |

Copyright © 2004-2021 Jan Zwiener