plateform
stringclasses
1 value
repo_name
stringlengths
13
113
name
stringlengths
3
74
ext
stringclasses
1 value
path
stringlengths
12
229
size
int64
23
843k
source_encoding
stringclasses
9 values
md5
stringlengths
32
32
text
stringlengths
23
843k
github
jhausser/ParTI-master
givensrot.m
.m
ParTI-master/SeDuMi_1_3/givensrot.m
1,768
utf_8
c06e2ebf2373bf05293d82dfbba507a1
% y = givensrot(gjc,g,x,K) % GIVENSROT % % ********** INTERNAL FUNCTION OF SEDUMI ********** % % See also sedumi function y = givensrot(gjc,g,x,K) % % This file is part of SeDuMi 1.1 by Imre Polik and Oleksandr Romanko % Copyright (C) 2005 McMaster University, H...
github
jhausser/ParTI-master
sparbwslv.m
.m
ParTI-master/SeDuMi_1_3/sparbwslv.m
2,035
utf_8
0549765090e0d9f6f70449eb65e4c1fb
% SPARBWSLV Solves block sparse upper-triangular system. % y = sparbwslv(L,b) yields the same result as % y(L.perm,:) = L.L'\b % However, SPARBWSLV is faster than the built-in operator "\", % because it uses dense linear algebra and loop-unrolling on % supernodes. % % Typical use, wit...
github
jhausser/ParTI-master
cellK.m
.m
ParTI-master/SeDuMi_1_3/cellK.m
3,587
utf_8
16c58714b6e3f669c6a2647fbfa79272
% xcell = cellK(x,K) % CELLK Stores SeDuMi cone K-vector in cell-array format. % % On output xcell.f and xcell.l are the free and >=0 components, % xcell.q{k}, xcell.r{k} and xcell.s{k} contain the Lorentz, % Rotated Lorentz, and PSD-components, resp. % xc...
github
jhausser/ParTI-master
prelp.m
.m
ParTI-master/SeDuMi_1_3/conversion/prelp.m
3,887
utf_8
8c7e67b2e1d395fd955562d7f31a033d
% PRELP Loads and preprocesses LP from an MPS file. % % > [A,b,c,lenx,lbounds] = PRELP('problemname') % The above command results in an LP in standard form, % - Instead of specifying the problemname, you can also use PRELP([]), to % get the problem from the file /tmp/default.mat. % - Also, you may ty...
github
jhausser/ParTI-master
feasreal.m
.m
ParTI-master/SeDuMi_1_3/conversion/feasreal.m
4,269
utf_8
696a3a72691eca524fa51b16e3d66676
% FEASREAL Generates a random sparse optimization problem with % linear, quadratic and semi-definite constraints. Output % can be used by SEDUMI. All data will be real-valued. % % The following two lines are typical: % > [AT,B,C,K] = FEASREAL; % > [X,Y,INFO] = SEDUMI(AT,B,C,K); % % An extended version i...
github
jhausser/ParTI-master
sdpa2vec.m
.m
ParTI-master/SeDuMi_1_3/conversion/sdpa2vec.m
2,413
utf_8
f31450c6f37447ae7b4723b129db9d4f
% x = sdpavec(E,K) % Takes an SDPA type sparse data description E, i.e. % E(1,:) = block, E(2,:) = row, E(3,:) = column, E(4,:) = entry, % and transforms it into a "long" vector, with vectorized matrices for % each block stacked under each other. The size of each matrix block % is given in the field K.s. % ****...
github
jhausser/ParTI-master
blk2vec.m
.m
ParTI-master/SeDuMi_1_3/conversion/blk2vec.m
1,699
utf_8
75235ffac1810910d18fb37b99a3223a
% x = blk2vec(X,nL) % % Converts a block diagonal matrix into a vector. % % ********** INTERNAL FUNCTION OF FROMPACK ********** function x = blk2vec(X,nL) % % This file is part of SeDuMi 1.1 by Imre Polik and Oleksandr Romanko % Copyright (C) 2005 McMaster University, Hamilton, CANADA (since 1.1) % % C...
github
jhausser/ParTI-master
writesdp.m
.m
ParTI-master/SeDuMi_1_3/conversion/writesdp.m
4,988
utf_8
6377c90a7877157dfb9ec61ed8005def
% This function takes a problem in SeDuMi MATLAB format and writes it out % in SDPpack format. % % Usage: % % writesdp(fname,A,b,c,K) % % fname Name of SDPpack file, in quotes % A,b,c,K Problem in SeDuMi form % % Notes: % % Problems with complex data are not allowed. ...
github
jhausser/ParTI-master
frompack.m
.m
ParTI-master/SeDuMi_1_3/conversion/frompack.m
2,583
utf_8
76beec126c8e1d01e6d87f189e024662
% FROMPACK Converts a cone problem in SDPPACK format to SEDUMI format. % % [At,c] = frompack(A,b,C,blk) Given a problem (A,b,C,blk) in the % SDPPACK-0.9-beta format, this produces At and c for use with % SeDuMi. This lets you execute % % [x,y,info] = SEDUMI(At,b,c,blk); % % IMPORTANT: this function assumes...
github
jhausser/ParTI-master
feascpx.m
.m
ParTI-master/SeDuMi_1_3/conversion/feascpx.m
4,513
utf_8
4de33ab70c8cb03bdda2f32a1796fe05
% FEASCPX Generates a random sparse optimization problem with % linear, quadratic and semi-definite constraints. Output % can be used by SEDUMI. Includes complex-valued data. % % The following two lines are typical: % > [AT,B,C,K] = FEASCPX; % > [X,Y,INFO] = SEDUMI(AT,B,C,K); % % An extended version is:...
github
jhausser/ParTI-master
VCA.m
.m
ParTI-master/mvsa_demo/VCA.m
6,902
utf_8
9a6dbc371d8802fabaa638ad49228eb9
function [Ae, indice, Rp] = VCA(R,varargin) % Vertex Component Analysis % % [Ae, indice, Rp ]= vca(R,'Endmembers',p,'SNR',r,'verbose',v) % % ------- Input variables ------------- % R - matrix with dimensions L(channels) x N(pixels) % each pixel is a linear mixture of p endmembers % signatures R = M...
github
jhausser/ParTI-master
VCA.m
.m
ParTI-master/sisal_demo/VCA.m
6,901
utf_8
199e5f4efaea0fa3496f9329ad174010
function [Ae, indice, Rp] = VCA(R,varargin) % Vertex Component Analysis % % [Ae, indice, Rp ]= vca(R,'Endmembers',p,'SNR',r,'verbose',v) % % ------- Input variables ------------- % R - matrix with dimensions L(channels) x N(pixels) % each pixel is a linear mixture of p endmembers % signatures R = M...
github
jhausser/ParTI-master
MVES.m
.m
ParTI-master/MVES_code/MVES.m
4,342
utf_8
71a186219f617242b9caecd5c2f8f414
%===================================================================== % Programmer: % Tsung-Han Chan, E-mail: chantsunghan@gmail.com % Date: May 20, 2009 % ------------------------------------------------------- % Reference: % T.-H. Chan, C.-Y. Chi, Y.-M. Huang and W.-K. Ma, ``A convex analysis % based minim...
github
Christiaanvandertol/Fluspect-master
fluspect_B_CX.m
.m
Fluspect-master/fluspect_B_CX.m
9,957
utf_8
6267d3fac6b4949c8516aa82e4550ff8
function leafopt = fluspect_B_CX(spectral,leafbio,optipar) % % function [leafopt] = fluspect_B_Cx(spectral,leafbio,optipar) % calculates reflectance and transmittance spectra of a leaf using FLUSPECT, % plus four excitation-fluorescence matrices % % Authors: Wout Verhoef, Christiaan van der Tol (c.vandertol@utwente.n...
github
Christiaanvandertol/Fluspect-master
numjacobian.m
.m
Fluspect-master/numjacobian.m
684
utf_8
015794f595dc83db4b6b9028006165a1
function J=numjacobian(x,spectral,leafbio,optipar) n=length(x); [r,t]=calc_fluspect_bcar(x,spectral,leafbio,optipar); % fx = [r,t]; step=1e-6; % J = zeros(length(r),2,n); for i=1:n xstep = x; xstep(i)=x(i)+step; [r,t] = calc_fluspect_bcar(xstep,spectral,leafbio,optipar); fxstep = [r,t]; J(:,:,i)= (...
github
gustavla/caffe-weighted-samples-master
prepare_batch.m
.m
caffe-weighted-samples-master/matlab/caffe/prepare_batch.m
1,298
utf_8
68088231982895c248aef25b4886eab0
% ------------------------------------------------------------------------ function images = prepare_batch(image_files,IMAGE_MEAN,batch_size) % ------------------------------------------------------------------------ if nargin < 2 d = load('ilsvrc_2012_mean'); IMAGE_MEAN = d.image_mean; end num_images = length...
github
gustavla/caffe-weighted-samples-master
matcaffe_demo.m
.m
caffe-weighted-samples-master/matlab/caffe/matcaffe_demo.m
3,344
utf_8
669622769508a684210d164ac749a614
function [scores, maxlabel] = matcaffe_demo(im, use_gpu) % scores = matcaffe_demo(im, use_gpu) % % Demo of the matlab wrapper using the ILSVRC network. % % input % im color image as uint8 HxWx3 % use_gpu 1 to use the GPU, 0 to use the CPU % % output % scores 1000-dimensional ILSVRC score vector % % You m...
github
shyingCy/Financial-time-series-prediction-master
uninstall_emd.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/uninstall_emd.m
2,128
utf_8
f1f4135f0d97101408694ab4f544d561
% UNINSTALL_EMD.M uninstall the EMD package % reverts the modifications made by INSTALL_EMD: % removes the following locations from Matlab's path: % <EMD_BASEDIR> % <EMD_BASEDIR>/utils % <EMD_BASEDIR>/examples/NSIP2003 % <EMD_BASEDIR>/examples/SPL2007 % % where <EMD_BASEDIR> is the directory containing uninstall_emd.m ...
github
shyingCy/Financial-time-series-prediction-master
install_emd.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/install_emd.m
1,562
utf_8
edba7a4d545fe9776097f92bd1ed273e
%INSTALL_EMD.M install the EMD package % add the following locations to Matlab's path: % <EMD_BASEDIR> % <EMD_BASEDIR>/emd % <EMD_BASEDIR>/utils % <EMD_BASEDIR>/examples/NSIP2003 % <EMD_BASEDIR>/examples/SPL2007 % % where <EMD_BASEDIR> is the directory containing install_emd.m % % and compiles the C codes % % IMPORTANT...
github
shyingCy/Financial-time-series-prediction-master
cemd_visu.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/cemd_visu.m
2,823
utf_8
5c2f5edbd41b0b0d83980d462bebf66c
%CEMD_VISU visualization of bivariate/complex EMD % % inputs : - x : complex analyzed signal % - t : time instants % - imf : set of complex IMFs % - i (optional) : figure number for display % % % The slider on the right hand side of the figure controls the direction on % which the co...
github
shyingCy/Financial-time-series-prediction-master
disp_hhs.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/disp_hhs.m
1,583
utf_8
dd6aace2bcf71483ee9329121ce38729
%DISP_HHS display Hilbert-Huang spectrum % % DISP_HHS(im,t,inf) % displays in a new figure the spectrum contained in matrix "im" % (amplitudes in dB). % % inputs: - im: image matrix (e.g., output of "toimage") % - t (optional): time instants (e.g., output of "toimage") % - inf (optional): -dynamic ...
github
shyingCy/Financial-time-series-prediction-master
plotc.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/plotc.m
3,243
utf_8
9e878242623f66dbe1f061cca4f876b9
%PLOTC plots a complex signal in 2D projection with variable projection angle. %The angle can be modified at any time using the slider: % slider at bottom: angle=0 the projection is the real part of the signal % slider at 1/4: angle=pi/2 the projection is the imaginary part of the signal % slider at top: angle=2pi sam...
github
shyingCy/Financial-time-series-prediction-master
findtag.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/findtag.m
1,044
utf_8
7454c7afdd89ce124034fa98264cb74e
%FINDTAG locate objects with specific tag % % FINDTAG(STR) % Locate objects with specific tag STR % % FINDTAG(OBJECT_HANDLES,STR) % Restricts the search to objects listed in objhandles and their descendants. % % FINDTAG(...,'-depth',d) % The depth argument d controls how many levels under the handles in objhandles %...
github
shyingCy/Financial-time-series-prediction-master
emd_visu.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/emd_visu.m
3,216
utf_8
b14b325a26ce79c2d4107444497d6eee
%EMD_VISU visualization of EMD and partial reconstructions (fine to coarse & coarse to fine) % % inputs : - x : analyzed signal, if x is complex cemd_visu is called % - t : time instants % - imf : output of emd.m % - i (optional) : figure number for display % % outputs : - f2c : fin...
github
shyingCy/Financial-time-series-prediction-master
boundary_conditions_emd.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/boundary_conditions_emd.m
3,546
utf_8
bde5088d1c5d540f2f15221e7130a453
%BOUNDARY_CONDITIONS_EMD extends an extrema set to limit edge effects on the interpolations % % % [TMIN,TMAX,ZMIN,ZMAX] = BOUNDARY_CONDITIONS_EMD(INDMIN,INDMAX,T,X,Z,NBSYM) % % inputs: % - INDMIN, INDMAX: indices of minima and maxima in the real signal X % - T: sampling times % - X: real signal in which INDMIN ...
github
shyingCy/Financial-time-series-prediction-master
plot3c.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/plot3c.m
798
utf_8
18cd6c9a1aa6a3a04e75a7a24b35a431
%PLOT3C plots a complex signal in 3D % % use: same as plot % % % See also % plotc (another type of visualization of complex signals) % % G. Rilling, last modification 12.2006 % gabriel.rilling@ens-lyon.fr function varargout = plot3c(varargin) % if first arument is a handle to some axes object if nargin >=2 && isscal...
github
shyingCy/Financial-time-series-prediction-master
cemd_disp.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/cemd_disp.m
2,547
utf_8
bcfc94ab889ec17222f5ac9d56aeebdd
%CEMD_DISP displays complex envelope curves and the corresponding tube envelope % % %CEMD_DISP(T,X,ENV,MODE) % % inputs: % - T: time instants % - X: analyzed signal (complex) % - ENV: matrix returned by cenvelope.m Each line is an envelope curve % - MODE: 'render' -> 3D rendering of the tube en...
github
shyingCy/Financial-time-series-prediction-master
extr.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/extr.m
1,938
utf_8
b255b6a18f2f3ebfbd1655dfddc2017b
%EXTR finds extrema and zero-crossings % % [indmin, indmax, indzer] = EXTR(x,t) % % inputs : - x : analyzed signal % - t (optional) : sampling times, default 1:length(x) % % outputs : - indmin = indices of minima % - indmax = indices of maxima % - indzer = indices of zero-crossings % % See...
github
shyingCy/Financial-time-series-prediction-master
addtag.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/addtag.m
791
utf_8
7753834d0f8132b47b2646f9a79bde33
%ADDTAG add a tag to an object % % ADDTAG(OBJ_HANDLE,STR) % % Adds the tag STR to the object referrenced by OBJ_HANDLE % When OBJ_HANDLE is an array of handles, STR is added to all corresponding % objects. % % Rem: In order for this to work properly, the object's tag field must be a string % containing keywords (or...
github
shyingCy/Financial-time-series-prediction-master
dirstretch.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/dirstretch.m
1,248
utf_8
ac3b11257589d22ec8b3705e588d54a2
%DIRSTRETCH variable directional stretching of a complex vector % % DIRSTRETCH(X,D) where X is a complex vector and D a complex scalar stretches X by abs(D) along the direction arg(D) % if D is a vector the same size as X, then X(i) is stretched by abs(D(i)) along the direction arf(D(i)) % DIRSTRETCH(X,DIR,COEF) whe...
github
shyingCy/Financial-time-series-prediction-master
hhspectrum.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/hhspectrum.m
1,445
utf_8
a2e3601a6b074460a64f0ee5c73e4a9c
%HHSPECTRUM compute Hilbert-Huang spectrum % % [A,f,tt] = HHSPECTRUM(x,t,l,aff) computes the Hilbert-Huang spectrum % % inputs: % - x : matrix with one signal per row % - t : time instants % - l : estimation parameter for instfreq (integer >=1 (1:default)) % - aff : if 1, displays the computation evolut...
github
shyingCy/Financial-time-series-prediction-master
hastag.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/hastag.m
659
utf_8
98c2d59c6e9ddf7de584ddba67f6ec51
%HASTAG tests if an object has a specific tag % % BOOL = HASTAG(OBJ_HANDLE,STR) % % Tests if the object corresponding to OBJ_HANDLE has the tag STR. % When OBJ_HANDLE is an array of handles HASTAG returns a logical array of % the same size. % % Rem: In order for this to work properly, the object's tag field must be ...
github
shyingCy/Financial-time-series-prediction-master
rmtag.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/rmtag.m
820
utf_8
c8cca7ed559bb8d9f89e3f8e3b34fc72
%RMTAG removes tag from object % % RMTAG(OBJ_HANDLE,STR) % % Removes the tag STR from the object referrenced by OBJ_HANDLE % When OBJ_HANDLE is an array of handles, the tag is removed from all % corresponding objects. % % Rem: In order for this to work properly, the object's tag field must be a string % containing ...
github
shyingCy/Financial-time-series-prediction-master
toimage.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/utils/toimage.m
3,003
utf_8
82d44ccfe64bb1323e00c307e16baa67
%TOIMAGE transforms a spectrum made of 1D functions in an 2D image % % [im,tt,ff] = TOIMAGE(A,f,t,splx,sply) transforms a spectrum made % of 1D functions (e.g., output of "hhspectrum") in an 2D image % % inputs : - A : amplitudes of modes (1 mode per row of A) % - f : instantaneous frequencies % ...
github
shyingCy/Financial-time-series-prediction-master
make_emdc.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/EMDs/make_emdc.m
1,361
utf_8
403408e17b436e17594d8a2bdd27ce6a
%MAKE_EMDC Compiles the C codes for Empirical Mode Decomposition % % Note: The compilation can fail on some systems (e.g. MacOS) if Matlab cannot find the C compiler. % In this case, you should either install a C compiler or check Matlab configuration. % The configuration files for compilation are mexopts.sh (Unix / M...
github
shyingCy/Financial-time-series-prediction-master
bivariate_EMD_principle.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/examples/SPL2007/bivariate_EMD_principle.m
3,936
utf_8
8ce99e0c1f645e2df06b921e64862397
%bivariate_EMD_principle.m %shows principle of the bivariate EMD extension %reproduces Fig. 1 in "Bivariate Empirical Mode Decomposition", G. Rilling, %P. Flandrin, P. Goncalves and J. M. Lilly, IEEE Signal Processing Letters % %G. Rilling 3/2007 email: gabriel.rilling@ens-lyon.fr function bivariate_EMD_principle N =...
github
shyingCy/Financial-time-series-prediction-master
dirstretch.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/examples/SPL2007/dirstretch.m
614
utf_8
6bd1c732deb536d078fbca3cc50b8d6e
%DIRSTRETCH variable directional stretching of a complex vector function y=dirstretch(x,dir,coef) if nargin == 3 if ~isreal(dir) && all(abs(dir) ~= 1) warning('non unit modulus of direction argument ignored') end if isreal(dir) && any(abs(dir) ~= 1) dir = exp(i*dir); end if any(dir==0) error('inv...
github
shyingCy/Financial-time-series-prediction-master
triangular_signal.m
.m
Financial-time-series-prediction-master/push5.2.7/indicatorLIB/package_emd/examples/NSIP2003/triangular_signal.m
378
utf_8
902a9084037dff3a52b19cd810a75795
% TRIANG.M % % P. Flandrin, Mar. 13, 2003 % % generates a triangular waveform % % inputs : - N : # of data samples % - p : period % % output : - x : signal function x = triang(N,p); K = ceil(N/(2*p-2)); w = zeros(1,K*(2*p-2)+1); rp = linspace(-1,1,p); rn = linspace(1,-1,p); r = [rp rn(2:p)]; for k = ...
github
shyingCy/Financial-time-series-prediction-master
testmop.m
.m
Financial-time-series-prediction-master/push5.2.7/backTestLib/GAopt/testmop.m
1,374
utf_8
ea01f7003b567d0df39a45ccf0794d63
function mop = testmop( testname, dimension ) %Get test multi-objective problems from a given name. % The method get testing or benchmark problems for Multi-Objective % Optimization. The implemented problems included ZDT, OKA, KNO. % User get the corresponding test problem, which is an instance of class % mop, ...
github
BrainDynamicsUSYD/nftsim-master
read.m
.m
nftsim-master/+nf/read.m
3,778
utf_8
764f4890af3172dde2bc821f21bb6aa5
%% Read a nftsim output file and return a nftsim output struct. % % ARGUMENTS: % fname -- The name of the nftsim output file to read (absolute % or relative path). % % OUTPUT: % obj -- A nftsim output struct. A Matlab struct containing data % and parameters from a simulation....
github
BrainDynamicsUSYD/nftsim-master
spatial_spectrum.m
.m
nftsim-master/+nf/spatial_spectrum.m
6,208
utf_8
bdfe9b366d0ab57ab639a71fb8e71652
%% Given a grid of voltages, applies a spatial filter % % Returns the spatially summed spectrum. % % ARGUMENTS: % obj -- nf object | a 3D matrix of values % p -- trace to use | sampling rate % kmax -- is the number of k-values to use. This should match with whatever kmax is set to in the analytic s...
github
BrainDynamicsUSYD/nftsim-master
movie.m
.m
nftsim-master/+nf/movie.m
5,326
utf_8
d848944f5fff28aef40cb6aa1d54a530
%% Script to generate a movie of a field with spatial variation. % % This script assumes the nodes are continuous, and the grid is a square. % % ARGUMENTS: % obj -- a structure returned by nf.read('config_name.conf') % tracename -- is a string with the name of the variable to plot e.g. "Propagator.2.ph...
github
BrainDynamicsUSYD/nftsim-master
report.m
.m
nftsim-master/+nf/report.m
879
utf_8
49f50c85f6613482dfa15d603cf62c47
%% Given a nftsim output struct, print some information about it. % % ARGUMENTS: % obj -- A nftsim output struct (a Matlab struct containing data % from a simulation). % % OUTPUT: Prints to terminal. % % AUTHOR: % Romesh Abeysuriya (2012-03-22). % % USAGE: %{ % %} %%%%%%%%%%%%%%%%%%%%%%%%%%...
github
BrainDynamicsUSYD/nftsim-master
spectrum.m
.m
nftsim-master/+nf/spectrum.m
3,131
utf_8
c9000abf4f7801e77a12a65bd526db1b
%% Returns the frequency vector and frequency power spectrum of a given nftsim structure. % By default this function returns the one-sided power spectrum from 0 to fs/2, where fs is the % sampling frequency. % ARGUMENTS: % obj -- A nftsim output struct (a Matlab struct containing data % from a si...
github
BrainDynamicsUSYD/nftsim-master
rfft.m
.m
nftsim-master/+nf/rfft.m
3,260
utf_8
2f627e153c2f972a62cbd0fd1ed36d99
%% Fourier transform % % Heavily based on Chris Rennie's notes, see REFERENCES below. % % The normalization is such that sum(abs(y).^2)/length(y) = trapz(f,P) % % ARGUMENTS: % y -- a 2D array of size (timepoints x N), where N is the number of signals/timeseries or traces. % fs -- sampling frequency (Hz) ...
github
BrainDynamicsUSYD/nftsim-master
run.m
.m
nftsim-master/+nf/run.m
3,445
utf_8
2fd1673511949f6f9ca25ca553d6c661
%% Function to run nftsim and return a nftsim output struct. % % Provided a configuration file-name (fname.conf), run the nftsim % executable, generating an output file (fname.output). Optionally, if an % output argument is provided then, parse the output file and return a % nftsim output struct containing the simulati...
github
BrainDynamicsUSYD/nftsim-master
partition.m
.m
nftsim-master/+nf/partition.m
2,416
utf_8
0076489b8fc79ea3f9e54187a639e067
%% Partition a list of n items into m groups. % % This function calculates the boundaries of each group e.g 16 elements % with pool=4 means that id=1,2,3,4 returns [1 4] [5 8] [9 12] and [13 16] % respectively. % % ARGUMENTS: % n_items -- . % pool -- total number of partitions % id -- the ID of thi...
github
BrainDynamicsUSYD/nftsim-master
get_frequencies.m
.m
nftsim-master/+nf/get_frequencies.m
2,634
utf_8
bcb4d50db18eba8ce258fe45bac00466
%% Take in the size of the data matrix, the sampling rate, and spatial distances % Return corresponding grids of frequencies and positions % % ARGUMENTS: % data -- an 1D or 3D array of size space points along x, space points along y, tim points, % fs -- sampling temporal frequency in [Hz] % Lx -- ...
github
BrainDynamicsUSYD/nftsim-master
field.m
.m
nftsim-master/+nf/field.m
589
utf_8
3ded4ba55784f7d2bc995cb84c328603
%% Returns field name according to the pre-/postfix and array of indices. % % ARGUMENTS: % prefix -- . % index -- . % postfix -- . % % OUTPUT: % ret -- . % % AUTHOR: % Romesh Abeysuriya (2012-03-22). % % USAGE: %{ % %} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%...
github
BrainDynamicsUSYD/nftsim-master
grid.m
.m
nftsim-master/+nf/grid.m
1,903
utf_8
c0c5ee8d5ce1a196baaa2c6b81d64f64
%% This function reshapes a 2D array into a 3D array, with the 1st and 2nd dimensions, % corresponding to X and Y coordinates and the 3rd dimension corresponding to time. % % e.g. data = nf.grid(nf,'Propagator.2.phi') will return the data for Propagator.2.phi % as a 3D matrix, with X and Y coordinates referring to g...
github
BrainDynamicsUSYD/nftsim-master
plot_timeseries.m
.m
nftsim-master/+nf/plot_timeseries.m
3,934
utf_8
dfa8c8910e5bbe2798a2db1afd7451e0
%% Plots time-series formatted like a typical EEG view. % % That is, nodes are displayed with vertical space between lines. By % default, for each time-step the spatial average is removed -- this % corresponds to a rereferencing to the "grand average". One figure window % is created for each trace. % % ARGUMENTS: %...
github
BrainDynamicsUSYD/nftsim-master
extract.m
.m
nftsim-master/+nf/extract.m
3,904
utf_8
35363066623a82b4c145827cfcbe859f
%% Extract a specific subset of data from a nftsim output struct. % % The subset can be specified in terms of: traces; times; and nodes. % % ARGUMENTS: % obj -- A nftsim output struct (a Matlab struct containing data % from a simulation). % traces -- A cell array or a comma separated string ...
github
gerac83/clifford_toolbox-master
AlgoCDE.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/CDE/AlgoCDE.m
1,729
utf_8
ebd3f19c96d3a0197eca990315d9ab0f
function [c, B] = AlgoCDE(A, treshold, verbose) if nargin < 2 || isempty(treshold) treshold = eps; end if nargin < 3 verbose = 1; end if verbose disp('**************************************************'); disp('A:'); disp(num2str(A)); end AT = A'; CanonicalB = [zeros(length(AT),...
github
gerac83/clifford_toolbox-master
NestReflectByHyper.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/CDE/NestReflectByHyper.m
828
utf_8
4e9d2f76945c5fa71d6bd9d24d0a3b99
function out = NestReflectByHyper(v, a, h) if h - 1 > 1 if ~isempty(Coefficient(v{h-1})) % ReflectByHyper[v[[h - 1]], NestReflectByHyper[v, a, h - 1]] out = ReflectByHyper(v{h - 1}, NestReflectByHyper(v, a, h - 1)); return; else % ReflectByHyper[v[[h - 2]], NestReflectBy...
github
gerac83/clifford_toolbox-master
phi.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/CDE/phi.m
1,365
utf_8
dcf269ed745133be170752bfaad9585c
function out = phi(s,B) if size(B,1) < 2 error('TBD!'); end if s == 0 out = eye(size(B,1)); return; end one = -1 / getScalar(GAproduct(s,s)); res = zeros(size(B,1),size(B,1)); for l = 1:size(B,1) for j = 1:size(B,1) if l == j two = getScalar(GAinner(s,B(j,:))) ^ ...
github
gerac83/clifford_toolbox-master
transform.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/Extra/transform.m
2,581
utf_8
208e24fb8200ce3f2f0275a9f36c5319
function out = transform(in) %TRANSFORM(IN) transforms IN from quaternion to Clifford algebra % representation % % Version: 1.0 (Nov, 2010) % Copyright (c) 2010, Aragon-Camarasa, G., Aragon-Gonzalez, G.; % Aragon J. L. & Rodriguez-Andrade, M. A. if ~ischar(in) error('Input must be a string!'); end i...
github
gerac83/clifford_toolbox-master
untransform.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/Extra/untransform.m
2,083
utf_8
49937baff82144c359750f81a2f036f4
function out = untransform(in) %UNTRANSFORM(IN) untransforms IN from Clifford algebra to quaternion % representation % % Version: 1.0 (Nov, 2010) % Copyright (c) 2010, Aragon-Camarasa, G., Aragon-Gonzalez, G.; % Aragon J. L. & Rodriguez-Andrade, M. A. if ischar(in) in = GAstring2mat(in); end tuples ...
github
gerac83/clifford_toolbox-master
GAstring2mat.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/Extra/GAstring2mat.m
4,915
utf_8
401c3e197e38aba1f697f87b1493cceb
function out = GAstring2mat(str) %GASTRING2MAT(STRING) transforms from a string to an array %representation % % Version: 1.0 (Nov, 2010) % Copyright (c) 2010, Aragon-Camarasa, G., Aragon-Gonzalez, G.; % Aragon J. L. & Rodriguez-Andrade, M. A. if ~ischar(str) error('Input must be a string!'); end % E...
github
gerac83/clifford_toolbox-master
ToVector.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/Core/ToVector.m
961
utf_8
3e8cc5e344e834607e21df0b4b05fe77
function out = ToVector(x,n) %TOVECTOR(X,N) transform the n-dimensional vector x from a*e[1]+b*e[2]+... to % the standard Mathematica form {a,b,...}. The defaul value of n is the % highest of all e[i]'s. % % Based on: Clifford Algebra with Mathematica (2008) http://arxiv.org/abs/0810.2412 % Version: 0.7 (Oct, 2...
github
gerac83/clifford_toolbox-master
GeometricProduct.m
.m
clifford_toolbox-master/MATLAB/cliffordv07/Core/GeometricProduct.m
3,851
utf_8
f580ae676a64a31271212d630f59d326
function [out, out1] = GeometricProduct(varargin) %GEOMETRICPRODUCT(A1,A2,...) calculates the geometric product of % multivectors m1,m2,..., mn % % INPUTS % Inputs may be a string or a matrix. They are explained below... % STRING: it should be expresed in terms of the geometric algrabra basis. % See example be...
github
feigl/gipht-master
fitvalley4.m
.m
gipht-master/obsolete/fitvalley4.m
4,308
utf_8
8a2712f13e83375d5cecf36765b87e3c
function [xvalley,yvalley] = fitvalley3(xvals,yvals) % given a set of values, find the valley function (bottom envelope) % 20200526 Kurt Feigl narginchk(2,2); nargoutchk(2,2); if numel(xvals) == numel(yvals) nvals = numel(xvals); %% find convex hull % dt = delaunayTriangulation(xvals,yvals); % k1 = convexHull(dt); ...
github
feigl/gipht-master
fitvalley2.m
.m
gipht-master/obsolete/fitvalley2.m
3,075
utf_8
973bc0241093410e79d8799ac3488cb4
function [xvalley,yedges] = fitvalley2(xvals,yvals) % given a set of values, find the valley function (bottom envelope) % 20200526 Kurt Feigl narginchk(2,2); nargoutchk(2,2); if numel(xvals) == numel(yvals) nvals = numel(xvals); % [N,edges,bin] = histcounts(___) also returns an index array, bin, using any of the pr...
github
feigl/gipht-master
funseparable27.m
.m
gipht-master/obsolete/funseparable27.m
42,622
utf_8
e5c3a18bbdc46b30963d0d6d4e7ed9c9
function varargout = funseparable27(varargin) %function varargout = funseparable27(varargin) % %% separable model for range change % p == parameter vector (1 column) % xyzm == easting, northing, up in m [3 rows] % tepochs == unique times in decimal years [1 row] % bpest == orbital separation w.r.t. vir...
github
feigl/gipht-master
fitvalley3.m
.m
gipht-master/obsolete/fitvalley3.m
3,248
utf_8
8670cb9c6485f559160677e309402c52
function [xvalley,yvalley] = fitvalley3(xvals,yvals) % given a set of values, find the valley function (bottom envelope) % 20200526 Kurt Feigl narginchk(2,2); nargoutchk(2,2); if numel(xvals) == numel(yvals) nvals = numel(xvals); % find convex hull dt = delaunayTriangulation(xvals,yvals); k1 = convexHull(dt); % %...
github
feigl/gipht-master
fitvalley.m
.m
gipht-master/obsolete/fitvalley.m
2,780
utf_8
5a54a978639194f2a049afc2529159ad
function [xvalley,yedges] = fitvalley(xvals,yvals) % given a set of values, find the valley function (bottom envelope) % 20200526 Kurt Feigl narginchk(2,2); nargoutchk(2,2); if numel(xvals) == numel(yvals) nvals = numel(xvals); % [N,edges,bin] = histcounts(___) also returns an index array, bin, using any of the pre...
github
feigl/gipht-master
start_mli0.m
.m
gipht-master/comfemat/start_mli0.m
3,519
utf_8
31ea7d4f9daa63f6efb4a711869197a8
function status1 = start_mli(verbose) % start matlab live link with comsol on Mac % 20200526 Kurt Feigl narginchk(0,1); nargoutchk(0,1); if nargin < 1 help(sprintf('%s',mfilename)); end if nargin < 1 verbose = 0; end %% Comsol server must be started switch computer case 'MACI64' [status0, output...
github
feigl/gipht-master
source.m
.m
gipht-master/comfemat/source.m
231
utf_8
30e294ead4c0b291a1df28d37e4e77d4
function q=source(x,y) % vector inputs and outputs for i=1:length(x) q(i) = calcsource(x(i), y(i)); end function q=calcsource(x,y) % scalar inputs and outputs r = sqrt(x^2+y^2); if r<0.5 q = 1000; else q = 500; end
github
feigl/gipht-master
grdinfo4.m
.m
gipht-master/extern/grdinfo4.m
7,599
utf_8
d69062da7d45d9594840cf8c041e7a25
function INFO = grdinfo4(file) %GRDINFO2 Print information about a GMT grdfile (netCDF format, GMT v3 or v4) % % Uses NetCDF libraries to display information about a GMT grid file. % Duplicates (some) functionality of the program grdinfo (which requires % compilation as a mexcdf function on each architecture) using % ...
github
feigl/gipht-master
anneal6.m
.m
gipht-master/extern/anneal6.m
13,300
utf_8
b7aca663cd67c3a38985a828425cba2f
%function [mhat,F,store,energy,count,msig]=anneal6(FUN,bounds,OPTIONS,varargin) function [mhat,F,store,energy,count,msig] = anneal6(objfun,OPTIONS,DST,PST,TST) %ANNEAL [mhat,F,store,energy,count]=anneal5(objfun,bounds,OPTIONS,x1,x2...,xn) %Simulated annealing algorithm that tries to find a minimum to the functio...
github
feigl/gipht-master
anneal5.m
.m
gipht-master/extern/anneal5.m
12,393
utf_8
1a19af1275cd415e2ff3e1910e4dde0a
function [mhat,F,store,energy,count,msig]=anneal5(FUN,bounds,OPTIONS,varargin) %ANNEAL [mhat,F,store,energy,count]=anneal5(FUN,bounds,OPTIONS,x1,x2...,xn) %Simulated annealing algorithm that tries to find a minimum to the function 'FUN'. % %INPUTS: % %'FUN' specifies the objective function. This function sho...
github
feigl/gipht-master
xml2struct.m
.m
gipht-master/extern/xml2struct.m
6,955
utf_8
58f0b998cc71b30b4a6a12b330cfe950
function [ s ] = xml2struct( file ) %Convert xml file into a MATLAB structure % [ s ] = xml2struct( file ) % % A file containing: % <XMLname attrib1="Some value"> % <Element>Some text</Element> % <DifferentElement attrib2="2">Some more text</Element> % <DifferentElement attrib3="2" attrib4="1">Even more t...
github
feigl/gipht-master
grdinfo3.m
.m
gipht-master/extern/grdinfo3.m
5,852
utf_8
6fd07a897fa81465b9bc4192009679ef
function INFO = grdinfo3(file) %GRDINFO2 Print information about a GMT grdfile (netCDF format, GMT v3 or v4) % % Uses NetCDF libraries to display information about a GMT grid file. % Duplicates (some) functionality of the program grdinfo (which requires % compilation as a mexcdf function on each architecture) using % ...
github
feigl/gipht-master
bookfonts.m
.m
gipht-master/extern/bookfonts.m
199
utf_8
848f2398e2f9199755c411de4cedec2e
% Parameter Estimation and Inverse Problems, 2nd edition, 2011 % by R. Aster, B. Borchers, C. Thurber % Set figure fontsizes for book size function bookfonts set(gca,'FontSize',18,'LineWidth',1.0);
github
feigl/gipht-master
derivest.m
.m
gipht-master/extern/derivest.m
22,656
utf_8
53b8b903ce69d613a113720690d9fe08
function [der,errest,finaldelta] = derivest(fun,x0,varargin) % DERIVEST: estimate the n'th derivative of fun at x0, provide an error estimate % usage: [der,errest] = DERIVEST(fun,x0) % first derivative % usage: [der,errest] = DERIVEST(fun,x0,prop1,val1,prop2,val2,...) % % Derivest will perform numerical differentiatio...
github
feigl/gipht-master
fmincon_test.m
.m
gipht-master/extern/fmincon_test.m
1,524
utf_8
5b84d8b3b6fc0beaac714381382a7b1a
function x = fmincon_test % To optimize for specific values of a1 and a2, first assign the values % to these two parameters. Then create two one-argument anonymous % functions that capture the values of a1 and a2, and call myfun and % mycon with two arguments. Finally, pass these anonymous functions to...
github
feigl/gipht-master
OkadaSol.m
.m
gipht-master/extern/OkadaSol.m
5,516
utf_8
2fe11d1c7d29e2becc8ad76be85a2999
% This file is distributed in the hope that it will be useful, but % WITHOUT ANY WARRANTY; without even the implied warranty of % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. % ----------------------------------------------------------------------- % Matlab program for the Okada solution computation % ...
github
feigl/gipht-master
okada85_checklist.m
.m
gipht-master/extern/okada85_checklist.m
3,768
utf_8
bb7b0783b2698a29e501f3e2c947bf85
function okada_checklist % Checks consistency of OKADA85 results using the "Checklist for numerical calculations" % from Table 2 [Okada, 1985] page 1149. % % References: % Okada Y., Surface deformation due to shear and tensile faults in a % half-space, Bull. Seismol. Soc. Am., 75:4, 1135-1154, 1985. % % Author...
github
feigl/gipht-master
grdinfo2.m
.m
gipht-master/extern/grdinfo2.m
5,272
utf_8
090b1dc21214900d6a3b016c7b77f1c4
function d = grdinfo2(file); %GRDINFO2 Print information about a GMT grdfile (netCDF format, GMT v3 or v4) % % Uses NetCDF libraries to display information about a GMT grid file. % Duplicates (some) functionality of the program grdinfo (which requires % compilation as a mexcdf function on each architecture) using % Ma...
github
feigl/gipht-master
unit.m
.m
gipht-master/extern/UnitConversion_rev2/unit.m
95,108
utf_8
23969e4e61d56d98b995ee6c37dda5fe
classdef unit % "unit" attaches physical units to a variable. % Examples: % unit(1,'mile') % % ans = % 1609.34 m % % y=unit('furlongs/fortnight') % % ans = % 0.00016631 m/s % % Any variable defined by "unit"...
github
feigl/gipht-master
convConstant.m
.m
gipht-master/extern/UnitConversion_rev2/convConstant.m
18,722
utf_8
89f6d3f9c828f7541790de15812982ee
classdef convConstant % Maintains the conversion constants used by the class "unit" % % An excellent reference, by Prof. Russ Rowlett, University of % North Carolina at Chapel Hill, is available on the Web at: % http://www.unc.edu/~rowlett/units % % AUTHOR: % John...
github
feigl/gipht-master
boxplot_custom.m
.m
gipht-master/extern/boxplot_custom/boxplot_custom.m
22,974
utf_8
b896db717cd8af9a6de538ada2958a49
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % Generate basic and special boxplots. Aside from the simple boxplots, you % can create horizontal boxplots, alternate y axis, multiple bars, and % ignore empty samples. You can also add the mean over the boxplot, and % select the method...
github
feigl/gipht-master
natsort.m
.m
gipht-master/extern/natsortfiles/natsort.m
12,982
utf_8
78209edfeb3527a783d5d0f246a00d17
function [Y,ndx,dbg] = natsort(X,rgx,varargin) % Natural-order / alphanumeric sort strings or character vectors or categorical. % % (c) 2012-2021 Stephen Cobeldick % % Sorts text by character code and by number value. By default matches % integer substrings and performs a case-insensitive ascending sort. % Optio...
github
feigl/gipht-master
natsortfiles.m
.m
gipht-master/extern/natsortfiles/natsortfiles.m
8,148
utf_8
0442391290855f74a8d3514aeb67d0ea
function [Y,ndx,dbg] = natsortfiles(X,rgx,varargin) % Natural-order / alphanumeric sort of filenames or foldernames. % % (c) 2014-2021 Stephen Cobeldick % % Sorts text by character code and by number value. File/folder names, file % extensions, and path directories (if supplied) are sorted separately to % ensure...
github
feigl/gipht-master
test_generalized_paretos.m
.m
gipht-master/src/test_generalized_paretos.m
4,713
utf_8
1af19d9e0dda290d5d7f62290ba6b7df
function crit69 = test_generalized_paretos(sample1,mean1) %function P = testGPmeans(gpmean1, n1, gpmean2, n2) % Return critical value of mean for sample2 drawn from % a Generalized Pareto (GP) distribution % such that sample2 is significantly different from sample1 % % Kurt Feigl 2011-OCT-11 % % INPUTS: % gpmean1, g...
github
feigl/gipht-master
estimate_uncertainty.m
.m
gipht-master/src/estimate_uncertainty.m
6,266
utf_8
bcc09eebd2cb1c979e9253a1519d3450
function msig = estimate_uncertainty(crit68,p0,p1,cost0,cost1,acosts1,atemps,atrials,lb,ub,pnames,objfun,fitfun,xdata,ydata,ysigma) %function msig = estimate_uncertainty(crit68,p0,p1,cost0,cost1,acosts1,atemps,atrials,lb,ub,pnames,objfun,fitfun,xdata,ydata,ysigma) % estimate uncertainties from width of cost valley % K...
github
feigl/gipht-master
testkappas3.m
.m
gipht-master/src/testkappas3.m
3,475
utf_8
f5ae08cc0db86f1b1b6fdc1ca030b69b
function P = testkappas3(Rbar1, n1, Rbar2, n2) %function P = testkappas3(Rbar1, n1, Rbar2, n2) %Test equality of concentration parameters % Mardia and Jupp, Directional Statistics, Wiley, 1999 % chap. 7.3.2 Tests of Equality of Concentration Parameters, pages 133-134 % Null hypothesis is that concentration parameters ...
github
feigl/gipht-master
read_geometry_from_h5_v1.m
.m
gipht-master/src/read_geometry_from_h5_v1.m
9,112
utf_8
324f3a81e3fc5c8339ad2329d79cd194
<<<<<<< HEAD function GEOM = read_geometry_from_h5(fname,doplots) ======= function GEOM = read_geometry_from_h5(fname,varargin) >>>>>>> c0a77c90e8512fa2eda6314b5513fb71fb565958 % read an H5 file from MINTPY and return structure with arrays containing geometry % sources of information % https://github.com/insarlab/MintP...
github
feigl/gipht-master
vonmisesness.m
.m
gipht-master/src/vonmisesness.m
4,858
utf_8
b753d116719ade42cc5d3ade25dc546f
function [S, teststring] = vonmisesness(theta1) %function [S, teststring] = vonmisesness(theta) % Test if directional data theta in radians follow Von Mises distribution % % Mardia and Jupp, Directional Statistics, Wiley, 1999 % chap. 7.5 Testing Von Misesness, pages 142-143 % (As printed in this textbook, the expressi...
github
feigl/gipht-master
funfit28.m
.m
gipht-master/src/funfit28.m
42,887
utf_8
2b646674590392035d6116e715d435e6
function varargout = funfit28(varargin) %function varargout = funfit28(varargin) % %% separable model for range change % p == parameter vector (1 column) % xyzm == easting, northing, up in m [3 rows] % tepochs == unique times in decimal years [1 row] % bpest == orbital separation w.r.t. virutal orbit i...
github
feigl/gipht-master
read_table.m
.m
gipht-master/src/read_table.m
3,750
utf_8
5fd8e52d6bc70997fb706e0557faefc5
function [values, name] = read_table(filename,nheaders,ncols,iname) %function [values,name]=read_table(filename,nheaders,ncols,iname) % read an ascii table of data % return parameters as column vectors % % ncols = number of columns in table, including name % nheader = number of header lines to skip % iname =...
github
ivanceras/balisong-master
bresenham.m
.m
balisong-master/src/bresenham.m
4,492
utf_8
96e60cdb87326c9ad3d893fdc1508d63
% Generate X Y Z coordinates of a 3D Bresenham's line between % two given points. % % A very useful application of this algorithm can be found in the % implementation of Fischer's Bresenham interpolation method in my % another program that can rotate three dimensional image volume % with an affine matrix: % http...
github
babrooks/SGSolve-master
sgmexbuild.m
.m
SGSolve-master/MATLAB/sgmexbuild.m
2,189
utf_8
f76d80357b374d642167a0c1a7730609
% This file is part of the SGSolve library for stochastic games % Copyright (C) 2016 Benjamin A. Brooks % % SGSolve free software: you can redistribute it and/or modify it % under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or % (at your ...
github
babrooks/SGSolve-master
sgmexbuild2.m
.m
SGSolve-master/MATLAB/sgmexbuild2.m
2,196
utf_8
226b1937902ff23afdb1d540a0c3fd75
% This file is part of the SGSolve library for stochastic games % Copyright (C) 2016 Benjamin A. Brooks % % SGSolve free software: you can redistribute it and/or modify it % under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or % (at your ...
github
babrooks/SGSolve-master
con2vert.m
.m
SGSolve-master/MATLAB/con2vert.m
5,476
utf_8
dac5963bef461b93fbcfb7878ce13300
function [V,nr] = con2vert(A,b) % CON2VERT - convert a convex set of constraint inequalities into the set % of vertices at the intersections of those inequalities;i.e., % solve the "vertex enumeration" problem. Additionally, % identify redundant entries in the list of inequalities. ...
github
babrooks/SGSolve-master
abstwist.m
.m
SGSolve-master/MATLAB/abstwist.m
41,637
utf_8
566150a604b65b728670780931165be3
% This file is part of the SGSolve library for stochastic games % Copyright (C) 2016 Benjamin A. Brooks % % SGSolve free software: you can redistribute it and/or modify it % under the terms of the GNU General Public License as published by % the Free Software Foundation, either version 3 of the License, or % (at your ...
github
babrooks/SGSolve-master
kocherlakota.m
.m
SGSolve-master/MATLAB/kocherlakota.m
4,797
utf_8
70a5a8eefc2d72405d3c9e95667df7e8
function [P,LR,ATK] = kocherlakota %% Ben's file for kocherlakota style simulations % 8-19-2015 numEndowments = 5; % Should be odd? consumptionToEndowments = 25; % P = linspace(0,10,numEndowments); % P=0:20; P=0:0.25:12.75; % P=[13 13.25 13.5 13.75 14]; LR = zeros(numel(P),2); ATK=LR; delta=0.9; numSimulations = 1e8;...
github
se4u/mvlsa-master
convnfft.m
.m
mvlsa-master/src/MRDS/convnfft.m
6,182
utf_8
b126295d4ec48b4308c041f512591036
function A = convnfft(A, B, shape, dims, options) % CONVNFFT FFT-BASED N-dimensional convolution. % C = CONVNFFT(A, B) performs the N-dimensional convolution of % matrices A and B. If nak = size(A,k) and nbk = size(B,k), then % size(C,k) = max([nak+nbk-1,nak,nbk]); % % C = CONVNFFT(A, B, SHAPE) controls the s...
github
se4u/mvlsa-master
tom_test_impl.m
.m
mvlsa-master/src/evaluate/tom_test_impl.m
3,042
utf_8
d5481d33645a4bccafd85423c2eec1b9
function [n_total, n_attempt, n_correct_cosadd, n_correct_cosmul]=tom_test_impl(... word, word_map, get_emb, dataset_fn, U) scws_file=getenv(dataset_fn); [w1, w2, w3, w4]=textread(scws_file, '%s %s %s %s'); n_total=0; n_attempt=0; n_correct_cosadd=0; n_correct_cosmul=0; nonlinear_transform=@(x) x; normalize_vec...
github
se4u/mvlsa-master
normalize_embedding.m
.m
mvlsa-master/src/evaluate/normalize_embedding.m
145
utf_8
a719669db504da0b2806a98480131cf6
% HELP 1 function embedding=normalize_embedding(embedding) for i=1:size(embedding, 1) embedding(i,:)=embedding(i,:)/norm(embedding(i,:)); end
github
se4u/mvlsa-master
batch_incremental_pca.m
.m
mvlsa-master/src/general_utility/batch_incremental_pca.m
613
utf_8
04342407df497ef2121687bf4bd13288
function [Ut_new, St_new]=batch_incremental_pca(x, U, S) r = size(U, 2); b = size(x, 2); xh = U'*x; H = x - U*xh; [J, W] = qr(H, 0); Q = [diag(S) xh ;... zeros(b,r) W]; [Ut_new, St_new, ~]=fastsvd(Q); St_new=St_new(1:r); Ut_new=[U J] * Ut_new(:, 1:r); end function [U, S, V]=fastsvd(M) %#ok<INUSD> % Ideally...