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 | skovnats/madmm-master | sympositivedefinitefactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/symfixedrank/sympositivedefinitefactory.m | 5,506 | utf_8 | 352c21fe40d0e4f75e7c0fa89ea4ab04 | function M = sympositivedefinitefactory(n)
% Manifold of n-by-n symmetric positive definite matrices with
% the bi-invariant geometry.
%
% function M = sympositivedefinitefactory(n)
%
% A point X on the manifold is represented as a symmetric positive definite
% matrix X (nxn).
%
% The following material is ref... |
github | skovnats/madmm-master | symfixedrankYYfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/symfixedrank/symfixedrankYYfactory.m | 3,628 | utf_8 | ed10332d6c3f8af67578d34eb7817b8c | function M = symfixedrankYYfactory(n, k)
% Manifold of n-by-n symmetric positive semidefinite matrices of rank k.
%
% function M = symfixedrankYYfactory(n, k)
%
% The geometry is based on the paper,
% M. Journee, P.-A. Absil, F. Bach and R. Sepulchre,
% "Low-Rank Optimization on the Cone of Positive Semidefinite... |
github | skovnats/madmm-master | complexcirclefactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/complexcircle/complexcirclefactory.m | 3,696 | utf_8 | f317f1fdbb76c8fb6cb2c39cee5c0db0 | function M = complexcirclefactory(n)
% Returns a manifold struct to optimize over unit-modulus complex numbers.
%
% function M = complexcirclefactory()
% function M = complexcirclefactory(n)
%
% Description of vectors z in C^n (complex) such that each component z(i)
% has unit modulus. The manifold structure is ... |
github | skovnats/madmm-master | fixedrankfactory_3factors_preconditioned.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankfactory_3factors_preconditioned.m | 11,730 | utf_8 | 25828327278d65ab2cb851ea6574833c | function M = fixedrankfactory_3factors_preconditioned(m, n, k)
% Manifold of m-by-n matrices of rank k with polar quotient geometry.
%
% function M = fixedrankLSRquotientfactory(m, n, k)
%
% A point X on the manifold is represented as a structure with three
% fields: L, S and R. The matrices L (mxk) and R (nxk) a... |
github | skovnats/madmm-master | fixedrankfactory_2factors_subspace_projection.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors_subspace_projection.m | 6,255 | utf_8 | 4232d28fbaabbc139761a8fbcca4ea4c | function M = fixedrankfactory_2factors_subspace_projection(m, n, k)
% Manifold of m-by-n matrices of rank k with quotient geometry.
%
% function M = fixedrankfactory_2factors_subspace_projection(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% B. Mishra, G. Meyer, S. Bonnabel an... |
github | skovnats/madmm-master | fixedrankfactory_2factors_preconditioned.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors_preconditioned.m | 5,832 | utf_8 | de03349c31333faef49955c31b7478b1 | function M = fixedrankfactory_2factors_preconditioned(m, n, k)
% Manifold of m-by-n matrices of rank k with new balanced quotient geometry
%
% function M = fixedrankfactory_2factors_preconditioned(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% B. Mishra, K. Adithya Apuroop and... |
github | skovnats/madmm-master | fixedrankembeddedfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankembeddedfactory.m | 10,833 | utf_8 | 1c1a04e099a39f2931eaf8763455c433 | function M = fixedrankembeddedfactory(m, n, k)
% Manifold struct to optimize fixed-rank matrices w/ an embedded geometry.
%
% function M = fixedrankembeddedfactory(m, n, k)
%
% Manifold of m-by-n real matrices of fixed rank k. This follows the
% geometry described in this paper (which for now is the documentation... |
github | skovnats/madmm-master | fixedrankfactory_3factors.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankfactory_3factors.m | 6,035 | utf_8 | a8c0a4812c73be5a82cf3918fe2d77c1 | function M = fixedrankfactory_3factors(m, n, k)
% Manifold of m-by-n matrices of rank k with polar quotient geometry.
%
% function M = fixedrankfactory_3factors(m, n, k)
%
% Follows the polar quotient geometry described in the following paper:
% G. Meyer, S. Bonnabel and R. Sepulchre,
% "Linear regression under ... |
github | skovnats/madmm-master | fixedrankMNquotientfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankMNquotientfactory.m | 4,472 | utf_8 | 12343fec86ae2648fcd915623ae645c5 | function M = fixedrankMNquotientfactory(m, n, k)
% Manifold of m-by-n matrices of rank k with quotient geometry.
%
% function M = fixedrankMNquotientfactory(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% P.-A. Absil, L. Amodei and G. Meyer,
% "Two Newton methods on the manifo... |
github | skovnats/madmm-master | fixedrankfactory_2factors.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors.m | 5,813 | utf_8 | 70044d83ff10591a75b81f415cb920c2 | function M = fixedrankfactory_2factors(m, n, k)
% Manifold of m-by-n matrices of rank k with balanced quotient geometry.
%
% function M = fixedrankfactory_2factors(m, n, k)
%
% This follows the balanced quotient geometry described in the following paper:
% G. Meyer, S. Bonnabel and R. Sepulchre,
% "Linear regres... |
github | skovnats/madmm-master | obliquefactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/oblique/obliquefactory.m | 6,609 | utf_8 | 1031640cf68e1bf9252af77d1002836a | function M = obliquefactory(n, m, transposed)
% Returns a manifold struct to optimize over matrices w/ unit-norm columns.
%
% function M = obliquefactory(n, m)
% function M = obliquefactory(n, m, transposed)
%
% Oblique manifold: deals with matrices of size n x m such that each column
% has unit 2-norm, i.e., is... |
github | skovnats/madmm-master | stiefelfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/stiefel/stiefelfactory.m | 4,989 | utf_8 | 5cc739262d8e75c600af8497647ee711 | function M = stiefelfactory(n, p, k)
% Returns a manifold structure to optimize over orthonormal matrices.
%
% function M = stiefelfactory(n, p)
% function M = stiefelfactory(n, p, k)
%
% The Stiefel manifold is the set of orthonormal nxp matrices. If k
% is larger than 1, this is the Cartesian product of the St... |
github | skovnats/madmm-master | rotationsfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/rotations/rotationsfactory.m | 4,857 | utf_8 | 421ccf6b88f519f989d6dd87fb0a1128 | function M = rotationsfactory(n, k)
% Returns a manifold structure to optimize over rotation matrices.
%
% function M = rotationsfactory(n)
% function M = rotationsfactory(n, k)
%
% Special orthogonal group (the manifold of rotations): deals with matrices
% R of size n x n x k (or n x n if k = 1, which is the d... |
github | skovnats/madmm-master | spherecomplexfactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/sphere/spherecomplexfactory.m | 3,285 | utf_8 | 28cbdaa05de778558800a89c16acad64 | function M = spherecomplexfactory(n, m)
% Returns a manifold struct to optimize over unit-norm complex matrices.
%
% function M = spherecomplexfactory(n)
% function M = spherecomplexfactory(n, m)
%
% Manifold of n-by-m complex matrices of unit Frobenius norm.
% By default, m = 1, which corresponds to the unit sp... |
github | skovnats/madmm-master | spherefactory.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/manifolds/sphere/spherefactory.m | 3,447 | utf_8 | 1b575cecaef843bcda1574bc09b4760c | function M = spherefactory(n, m)
% Returns a manifold struct to optimize over unit-norm vectors or matrices.
%
% function M = spherefactory(n)
% function M = spherefactory(n, m)
%
% Manifold of n-by-m real matrices of unit Frobenius norm.
% By default, m = 1, which corresponds to the unit sphere in R^n. The
% m... |
github | skovnats/madmm-master | trustregions.m | .m | madmm-master/functional_maps_L21norm/help_functions/manopt/manopt/solvers/trustregions/trustregions.m | 27,503 | utf_8 | 16c81a00a44c928fd6ca503399b04111 | function [x, cost, info, options] = trustregions(problem, x, options)
% Riemannian trust-regions solver for optimization on manifolds.
%
% function [x, cost, info, options] = trustregions(problem)
% function [x, cost, info, options] = trustregions(problem, x0)
% function [x, cost, info, options] = trustregions(pro... |
github | skovnats/madmm-master | MADMM_comptr.m | .m | madmm-master/compressed_modes/MADMM_comptr.m | 2,379 | utf_8 | 6b9420c94a0f051a1efd4b0488e967c4 | function [X,Xcost bm tm] = MADMM_comptr(L,N,lambda,rho,steps,it,X0)
% Manifold ADMM method
% Minimizes lambda*|X|_1+trace(X'LX)
% on the manifold of n x N- orthogonal matrices.
% INPUT:
% L: is the discretized Hamiltonian, a n x n- matrix
% N: number of colums of X (approximate eigenvectors)
% lambda: ... |
github | skovnats/madmm-master | dsh.m | .m | madmm-master/compressed_modes/dsh.m | 2,720 | utf_8 | 4280c07d43da54dee64aaed8d33fe7b8 | % script for dispalying shape
function [] = dsh( varargin )
% input:
%{
{1} - title
{2} - if save
%}
vector = false;
flag = true;
name = [];
switch nargin
case 1
shape = varargin{ 1 };
case 2
shape = varargin{ 1 };
tname = varargin{ 2 };
if isn... |
github | skovnats/madmm-master | MADMM_comp.m | .m | madmm-master/compressed_modes/MADMM_comp.m | 2,354 | utf_8 | 69c9f062e75434e34f506a3e9d02c53f | function [X,Xcost bm tm] = MADMM_comp(L,N,lambda,rho,steps,it,X0)
% Manifold ADMM method
% Minimizes lambda*|X|_1+trace(X'LX)
% on the manifold of n x N- orthogonal matrices.
% INPUT:
% L: is the discretized Hamiltonian, a n x n- matrix
% N: number of colums of X (approximate eigenvectors)
% lambda: ... |
github | skovnats/madmm-master | SL1_Manopt.m | .m | madmm-master/compressed_modes/SL1_Manopt.m | 2,109 | utf_8 | 3640ab4e879252685fd9afa563f8fa2c | function [X, Xcost b0 t0]=SL1_Manopt(H,N,mu,eps,it,X0)
% Minimizes |X|_eps/mu+trace(X'HX)
% on the Stiefel manifold X'*X=I
% Here |.|_eps is the smoothed L1- norm |x|=sqrt(x^2+eps), eps>0.
% INPUT:
% H: discrete Hamiltonian
% N: number of colums of X
% eps: smoothing parameter for L1 norm (eps = 10^(-6) )
% it: nu... |
github | skovnats/madmm-master | NEUMANN.m | .m | madmm-master/compressed_modes/NEUMANN.m | 1,914 | utf_8 | 3c56c114705af05e0b37e8334ed39359 | function [X,Xcost bo to] = NEUMANN(L,N,lambda,rho,it,X0);
% Neumann's ADMM method
% Minimizes lambda*|X|_1+trace(X'LX)
% on the manifold of n x N- orthogonal matrices.
% INPUT:
% L: is the discretized Hamiltonian, a n x n- matrix
% N: number of colums of X (approximate eigenvectors)
% lambda: paramet... |
github | skovnats/madmm-master | OSHER.m | .m | madmm-master/compressed_modes/OSHER.m | 1,885 | utf_8 | 51162b58ba309528a609bc58d3cfaa10 | function [X,Xcost bo, to] = OSHER(H,N,mu,lambda,rho,it,X0);
% Osher's ADMM method
% Minimizes |X|_1/mu+trace(X'HX)
% on the manifold of n x N- matrices.
% INPUT:
% H: is the discretized Hamiltonian, a n x n- matrix
% N: number of colums of X (approximate eigenvectors)
% mu: penalty parameter in co... |
github | skovnats/madmm-master | MADMM_compcg.m | .m | madmm-master/compressed_modes/MADMM_compcg.m | 2,524 | utf_8 | 958d53554d16a56d1712b9673ee29188 | function [X,Xcost bm tm] = MADMM_compcg(L,N,lambda,rho,steps,it,X0)
% Manifold ADMM method
% Minimizes lambda*|X|_1+trace(X'LX)
% on the manifold of n x N- orthogonal matrices.
% INPUT:
% L: is the discretized Hamiltonian, a n x n- matrix
% N: number of colums of X (approximate eigenvectors)
% lambda: ... |
github | skovnats/madmm-master | maxcut.m | .m | madmm-master/compressed_modes/manopt/examples/maxcut.m | 12,136 | utf_8 | 7f2745544840a7cd9263ab6e5e7fccf6 | function [x cutvalue cutvalue_upperbound Y] = maxcut(L, r)
% Algorithm to (try to) compute a maximum cut of a graph, via SDP approach.
%
% function x = maxcut(L)
% function [x cutvalue cutvalue_upperbound Y] = maxcut(L, r)
%
% L is the Laplacian matrix describing the graph to cut. The Laplacian of a
% graph is ... |
github | skovnats/madmm-master | maxcut_octave.m | .m | madmm-master/compressed_modes/manopt/examples/maxcut_octave.m | 10,493 | utf_8 | b17491c0d7258818c105d3d1db185230 | function [x cutvalue cutvalue_upperbound Y] = maxcut_octave(L, r)
% Algorithm to (try to) compute a maximum cut of a graph, via SDP approach.
%
% function x = maxcut_octave(L)
% function [x cutvalue cutvalue_upperbound Y] = maxcut_octave(L, r)
%
% See examples/maxcut.m for help about the math behind this example... |
github | skovnats/madmm-master | sparse_pca.m | .m | madmm-master/compressed_modes/manopt/examples/sparse_pca.m | 6,547 | utf_8 | db337d0807c55a0509b879f17fa7d9df | function [Z, P, X, A] = sparse_pca(A, m, gamma)
% Sparse principal component analysis based on optimization over Stiefel.
%
% [Z, P, X] = sparse_pca(A, m, gamma)
%
% We consider sparse PCA applied to a data matrix A of size pxn, where p is
% the number of samples (observations) and n is the number of variables
%... |
github | skovnats/madmm-master | grassmannfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/grassmann/grassmannfactory.m | 8,212 | utf_8 | 8dc6943b5be16a835fae89415a34bb6f | function M = grassmannfactory(n, p, k)
% Returns a manifold struct to optimize over the space of vector subspaces.
%
% function M = grassmannfactory(n, p)
% function M = grassmannfactory(n, p, k)
%
% Grassmann manifold: each point on this manifold is a collection of k
% vector subspaces of dimension p embedded i... |
github | skovnats/madmm-master | elliptopefactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/symfixedrank/elliptopefactory.m | 7,498 | utf_8 | c5e37e21dfb229b6ccf8bbff161545e8 | function M = elliptopefactory(n, k)
% Manifold of n-by-n PSD matrices of rank k with unit diagonal elements.
%
% function M = elliptopefactory(n, k)
%
% The geometry is based on the paper,
% M. Journee, P.-A. Absil, F. Bach and R. Sepulchre,
% "Low-Rank Optimization on the Cone of Positive Semidefinite Matrices"... |
github | skovnats/madmm-master | spectrahedronfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/symfixedrank/spectrahedronfactory.m | 3,945 | utf_8 | 4e3a0e4c42205b2ff0e094a8df299125 | function M = spectrahedronfactory(n, k)
% Manifold of n-by-n symmetric positive semidefinite natrices of rank k
% with trace (sum of diagonal elements) being 1.
%
% function M = spectrahedronfactory(n, k)
%
% The goemetry is based on the paper,
% M. Journee, P.-A. Absil, F. Bach and R. Sepulchre,
% "Low-Rank Op... |
github | skovnats/madmm-master | sympositivedefinitefactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/symfixedrank/sympositivedefinitefactory.m | 5,506 | utf_8 | 352c21fe40d0e4f75e7c0fa89ea4ab04 | function M = sympositivedefinitefactory(n)
% Manifold of n-by-n symmetric positive definite matrices with
% the bi-invariant geometry.
%
% function M = sympositivedefinitefactory(n)
%
% A point X on the manifold is represented as a symmetric positive definite
% matrix X (nxn).
%
% The following material is ref... |
github | skovnats/madmm-master | symfixedrankYYfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/symfixedrank/symfixedrankYYfactory.m | 3,628 | utf_8 | ed10332d6c3f8af67578d34eb7817b8c | function M = symfixedrankYYfactory(n, k)
% Manifold of n-by-n symmetric positive semidefinite matrices of rank k.
%
% function M = symfixedrankYYfactory(n, k)
%
% The geometry is based on the paper,
% M. Journee, P.-A. Absil, F. Bach and R. Sepulchre,
% "Low-Rank Optimization on the Cone of Positive Semidefinite... |
github | skovnats/madmm-master | complexcirclefactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/complexcircle/complexcirclefactory.m | 3,696 | utf_8 | f317f1fdbb76c8fb6cb2c39cee5c0db0 | function M = complexcirclefactory(n)
% Returns a manifold struct to optimize over unit-modulus complex numbers.
%
% function M = complexcirclefactory()
% function M = complexcirclefactory(n)
%
% Description of vectors z in C^n (complex) such that each component z(i)
% has unit modulus. The manifold structure is ... |
github | skovnats/madmm-master | fixedrankfactory_3factors_preconditioned.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankfactory_3factors_preconditioned.m | 11,730 | utf_8 | 25828327278d65ab2cb851ea6574833c | function M = fixedrankfactory_3factors_preconditioned(m, n, k)
% Manifold of m-by-n matrices of rank k with polar quotient geometry.
%
% function M = fixedrankLSRquotientfactory(m, n, k)
%
% A point X on the manifold is represented as a structure with three
% fields: L, S and R. The matrices L (mxk) and R (nxk) a... |
github | skovnats/madmm-master | fixedrankfactory_2factors_subspace_projection.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors_subspace_projection.m | 6,255 | utf_8 | 4232d28fbaabbc139761a8fbcca4ea4c | function M = fixedrankfactory_2factors_subspace_projection(m, n, k)
% Manifold of m-by-n matrices of rank k with quotient geometry.
%
% function M = fixedrankfactory_2factors_subspace_projection(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% B. Mishra, G. Meyer, S. Bonnabel an... |
github | skovnats/madmm-master | fixedrankfactory_2factors_preconditioned.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors_preconditioned.m | 5,832 | utf_8 | de03349c31333faef49955c31b7478b1 | function M = fixedrankfactory_2factors_preconditioned(m, n, k)
% Manifold of m-by-n matrices of rank k with new balanced quotient geometry
%
% function M = fixedrankfactory_2factors_preconditioned(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% B. Mishra, K. Adithya Apuroop and... |
github | skovnats/madmm-master | fixedrankembeddedfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankembeddedfactory.m | 10,833 | utf_8 | 1c1a04e099a39f2931eaf8763455c433 | function M = fixedrankembeddedfactory(m, n, k)
% Manifold struct to optimize fixed-rank matrices w/ an embedded geometry.
%
% function M = fixedrankembeddedfactory(m, n, k)
%
% Manifold of m-by-n real matrices of fixed rank k. This follows the
% geometry described in this paper (which for now is the documentation... |
github | skovnats/madmm-master | fixedrankfactory_3factors.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankfactory_3factors.m | 6,035 | utf_8 | a8c0a4812c73be5a82cf3918fe2d77c1 | function M = fixedrankfactory_3factors(m, n, k)
% Manifold of m-by-n matrices of rank k with polar quotient geometry.
%
% function M = fixedrankfactory_3factors(m, n, k)
%
% Follows the polar quotient geometry described in the following paper:
% G. Meyer, S. Bonnabel and R. Sepulchre,
% "Linear regression under ... |
github | skovnats/madmm-master | fixedrankMNquotientfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankMNquotientfactory.m | 4,472 | utf_8 | 12343fec86ae2648fcd915623ae645c5 | function M = fixedrankMNquotientfactory(m, n, k)
% Manifold of m-by-n matrices of rank k with quotient geometry.
%
% function M = fixedrankMNquotientfactory(m, n, k)
%
% This follows the quotient geometry described in the following paper:
% P.-A. Absil, L. Amodei and G. Meyer,
% "Two Newton methods on the manifo... |
github | skovnats/madmm-master | fixedrankfactory_2factors.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/fixedrank/fixedrankfactory_2factors.m | 5,813 | utf_8 | 70044d83ff10591a75b81f415cb920c2 | function M = fixedrankfactory_2factors(m, n, k)
% Manifold of m-by-n matrices of rank k with balanced quotient geometry.
%
% function M = fixedrankfactory_2factors(m, n, k)
%
% This follows the balanced quotient geometry described in the following paper:
% G. Meyer, S. Bonnabel and R. Sepulchre,
% "Linear regres... |
github | skovnats/madmm-master | obliquefactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/oblique/obliquefactory.m | 6,609 | utf_8 | 1031640cf68e1bf9252af77d1002836a | function M = obliquefactory(n, m, transposed)
% Returns a manifold struct to optimize over matrices w/ unit-norm columns.
%
% function M = obliquefactory(n, m)
% function M = obliquefactory(n, m, transposed)
%
% Oblique manifold: deals with matrices of size n x m such that each column
% has unit 2-norm, i.e., is... |
github | skovnats/madmm-master | stiefelfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/stiefel/stiefelfactory.m | 4,989 | utf_8 | 5cc739262d8e75c600af8497647ee711 | function M = stiefelfactory(n, p, k)
% Returns a manifold structure to optimize over orthonormal matrices.
%
% function M = stiefelfactory(n, p)
% function M = stiefelfactory(n, p, k)
%
% The Stiefel manifold is the set of orthonormal nxp matrices. If k
% is larger than 1, this is the Cartesian product of the St... |
github | skovnats/madmm-master | rotationsfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/rotations/rotationsfactory.m | 4,857 | utf_8 | 421ccf6b88f519f989d6dd87fb0a1128 | function M = rotationsfactory(n, k)
% Returns a manifold structure to optimize over rotation matrices.
%
% function M = rotationsfactory(n)
% function M = rotationsfactory(n, k)
%
% Special orthogonal group (the manifold of rotations): deals with matrices
% R of size n x n x k (or n x n if k = 1, which is the d... |
github | skovnats/madmm-master | spherecomplexfactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/sphere/spherecomplexfactory.m | 3,285 | utf_8 | 28cbdaa05de778558800a89c16acad64 | function M = spherecomplexfactory(n, m)
% Returns a manifold struct to optimize over unit-norm complex matrices.
%
% function M = spherecomplexfactory(n)
% function M = spherecomplexfactory(n, m)
%
% Manifold of n-by-m complex matrices of unit Frobenius norm.
% By default, m = 1, which corresponds to the unit sp... |
github | skovnats/madmm-master | spherefactory.m | .m | madmm-master/compressed_modes/manopt/manopt/manifolds/sphere/spherefactory.m | 3,447 | utf_8 | 1b575cecaef843bcda1574bc09b4760c | function M = spherefactory(n, m)
% Returns a manifold struct to optimize over unit-norm vectors or matrices.
%
% function M = spherefactory(n)
% function M = spherefactory(n, m)
%
% Manifold of n-by-m real matrices of unit Frobenius norm.
% By default, m = 1, which corresponds to the unit sphere in R^n. The
% m... |
github | skovnats/madmm-master | trustregions.m | .m | madmm-master/compressed_modes/manopt/manopt/solvers/trustregions/trustregions.m | 27,503 | utf_8 | 16c81a00a44c928fd6ca503399b04111 | function [x, cost, info, options] = trustregions(problem, x, options)
% Riemannian trust-regions solver for optimization on manifolds.
%
% function [x, cost, info, options] = trustregions(problem)
% function [x, cost, info, options] = trustregions(problem, x0)
% function [x, cost, info, options] = trustregions(pro... |
github | skovnats/madmm-master | calcVoronoiRegsCircCent.m | .m | madmm-master/compressed_modes/LB/calcVoronoiRegsCircCent.m | 2,497 | utf_8 | b33c6683c5fafa8ead79d9436c30477f | function [VorRegsVertices] = calcVoronoiRegsCircCent(Tri, Vertices)
%% Preps.:
A1 = Vertices(Tri(:,1), :);
A2 = Vertices(Tri(:,2), :);
A3 = Vertices(Tri(:,3), :);
a = A1 - A2; % Nx3
b = A3 - A2; % Nx3
c = A1 - A3; % Nx3
M1 = 1/2*(A2 + A3); % Nx3
M2 = 1/2*(A1 + A3); % Nx3
M3 = 1/2*(A2 + A1); ... |
github | skovnats/madmm-master | gencols.m | .m | madmm-master/compressed_modes/LB/gencols.m | 5,738 | utf_8 | 497e10b44a80cff59db8f7c18b5a9608 | function colors = gencols(n_colors,bg,func)
% DISTINGUISHABLE_COLORS: pick colors that are maximally perceptually distinct
%
% When plotting a set of lines, you may want to distinguish them by color.
% By default, Matlab chooses a small set of colors and cycles among them,
% and so if you have more than a few lines the... |
github | skovnats/madmm-master | calcLB.m | .m | madmm-master/compressed_modes/LB/calcLB.m | 4,269 | utf_8 | 5d1e4c81097a7b2a73eac18edb6af2d1 | function [M, DiagS] = calcLB(shape)
% The L-B operator matrix is computed by DiagS^-1*M.
% Calculate the weights matrix M
M = calcCotMatrixM1([shape.X, shape.Y, shape.Z], shape.TRIV);
M = -M;
% Calculate the diagonal of matrix S
DiagS = calcVoronoiRegsCircCent(shape.TRIV, [shape.X, shape.Y, shape.Z]);
%%
D... |
github | AndrewCWalker/rsm_tool_suite-master | gCovMat.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gCovMat.m | 2,683 | utf_8 | c21141d4e605a0a8905593b499eea2cb | % function Scov = gCovMat(dist,beta,lamz,lams)
% given n x p matrix x of spatial coords, and dependence parameters
% beta p x 1, this function returns a matrix built from the
% correlation function
% Scov_ij = exp{- sum_k=1:p beta(k)*(x(i,k)-x(j,k))^2 } ./lamz
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%... |
github | AndrewCWalker/rsm_tool_suite-master | qEst.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/qEst.m | 11,985 | utf_8 | b02a0efa556c1750551ac034a08a8883 | function th=qEst(pout,pvec,thProb, densFun, varargin)
% function th=subRegionSamp(pout,pvec,thProb, densFun, varargin)
% collect response MLpost, into sets H, M, L, based on the
% vl and vh estimates. Estimate response from M set, given integrated
% density from L and H.
% Operations are generally defined on... |
github | AndrewCWalker/rsm_tool_suite-master | gBoxPlot.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gBoxPlot.m | 3,489 | utf_8 | c6c0b1747e1e919db397f161884e099c | % function gBoxPlot(x,varargin)
% substitute for stats toolbox boxplot function, by Gatt
% shows a boxplot-like summary for each column of x
% lines of the box are at the lower quartile, median, and upper quartile
% whiskers extend to the most extreme values with 1.5 times the
% inter-quartile range,
% extreme values o... |
github | AndrewCWalker/rsm_tool_suite-master | gLogBetaPrior.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gLogBetaPrior.m | 1,867 | utf_8 | 78659b95a74e58bce6b3dc05d90f580a | %function model = gLogBetaPrior(x,parms)
%
% Computes unscaled log beta pdf,
% sum of 1D distributions for each (x,parms) in the input vectors
% for use in prior likelihood calculation
% parms = [a-parameter-vector b-parameter-vector]
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Au... |
github | AndrewCWalker/rsm_tool_suite-master | gPlotMatrix.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gPlotMatrix.m | 9,865 | utf_8 | 05634a43bd2c67952be44a7ae7aa6ea5 | function [h bigAx]=gPlotMatrix(data,varargin)
% function [h bigAx]=gPlotMatrix(data,varargin)
% data - contains vectors for scatterplots
% each row is an vector, as expected for plotmatrix
% varargs include
% 'Pcontours' are the percentile levels for the contour plot
% 'ngrid' is axis grid size (symmetric) ... |
github | AndrewCWalker/rsm_tool_suite-master | setupModel.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/setupModel.m | 14,699 | utf_8 | 91a9639a208d5021b3a83b639c968ea8 | % function params=setupModel(obsData,simData,optParms)
% Sets up a gpmsa runnable struct from raw data.
% Please refer to associated documentation
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as par... |
github | AndrewCWalker/rsm_tool_suite-master | diagInds.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/diagInds.m | 1,688 | utf_8 | f59b568d366c4b91f80524bae479d267 | % function inds=createDiagInds(n)
%
% Return the 1-D indices of the diagonal of an nxn matrix
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software package
% Los Alam... |
github | AndrewCWalker/rsm_tool_suite-master | gPredict.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gPredict.m | 12,969 | utf_8 | 0faae2364a770f2bd0a51297aae3cb08 | %function pred=gPredict(xpred,pvals,model,data,varargs)
% Predict using a gpmsa constructed model.
% result is a 3-dimensional prediction matrix:
% #pvals by model-dims by length-xpred
% model-dims is the simulation basis size for a w-prediction (a model
% with no observation data) or the v (discrepancy bas... |
github | AndrewCWalker/rsm_tool_suite-master | computeLogPrior.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/computeLogPrior.m | 2,422 | utf_8 | df71fa1621e6def310ce84163c42cc8d | %function model = computeLogPrior(priors,mcmc,model)
%
% Builds the prior likelihood
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software package
% Los Alamos Computer Code ... |
github | AndrewCWalker/rsm_tool_suite-master | showPvals.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/showPvals.m | 2,687 | utf_8 | 7afb8f157187182f1163280278447048 | % function showPvals(pvals, skip)
% skip = the beginning index to display; optional
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software package
% Los Alamos Computer... |
github | AndrewCWalker/rsm_tool_suite-master | counter.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/counter.m | 3,295 | utf_8 | c028bb3c870f6796e476f67360b9a36c | % function counter('start',first_value,last_value,skip_counts,feed)
% function counter('stime',first_value,last_value,skip_seconds,feed)
% Setup mode
% first_value=first value in counter
% last_value=last value in counter (for time computation)
% feed = count of display events for computing tim... |
github | AndrewCWalker/rsm_tool_suite-master | genDist2.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/genDist2.m | 2,533 | utf_8 | 82783b882e1fc9d1b4096cb0d3db2da6 | % function d = gendist2(data1,data2,dataDesc);
% generates the nxmxp distance array values and supporting
% information, given the nxp matrix data1 and mxp data2
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This f... |
github | AndrewCWalker/rsm_tool_suite-master | gLogGammaPrior.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gLogGammaPrior.m | 1,859 | utf_8 | d710e649ff2ed42a891da063011c5753 | %function model = gLogGammaPrior(x,parms)
%
% Computes unscaled log normal pdf,
% sum of 1D distributions for each (x,parms) in the input vectors
% for use in prior likelihood calculation
% parms = [a-parameter-vector b-parameter-vector]
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%... |
github | AndrewCWalker/rsm_tool_suite-master | parseAssignVarargs.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/parseAssignVarargs.m | 2,382 | utf_8 | 41948e793af8c4b330571f7498b71208 | % function parseAssignVarargs(validVars)
% assigns specified caller varargs to the corresponding variable name
% in the calling workspace. vars not specified are not assigned.
% validVars is a cell array of strings that represents possible
% arg names, and the variable name in the workspace (identical)
% varargs i... |
github | AndrewCWalker/rsm_tool_suite-master | gAnalyzePCA.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gAnalyzePCA.m | 2,848 | utf_8 | b90e5f67f23f598aa3fbb2d3c866aa60 | %function a=gAnalyzePCA(y,y1)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software package
% Los Alamos Computer Code release LA-CC-06-079, C-06,114
%
% Copyright 2008. Los A... |
github | AndrewCWalker/rsm_tool_suite-master | gLogNormalPrior.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gLogNormalPrior.m | 1,868 | utf_8 | 34a389d335f9f51af952c938fcfcde8a | %function model = gLogNormalPrior(x,parms)
%
% Computes unscaled log normal pdf,
% sum of 1D distributions for each (x,parms) in the input vectors
% for use in prior likelihood calculation
% parms = [mean-vector standard-deviation-vector]
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
... |
github | AndrewCWalker/rsm_tool_suite-master | axisNorm.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/axisNorm.m | 3,170 | utf_8 | 0db8d59bce06058f104cfb06a9cafea6 | % function axisNorm(handles, mode, axisVals)
% Tool to set 2S plot axes to the same values.
% handles is a list of handles to the plots in question
% mode is combinations of 'x', 'y', and 'z', optionally followed by 'max'
% indicating which axes are to be set, and whether they are to be
% autoscaled to the ... |
github | AndrewCWalker/rsm_tool_suite-master | gGMICDF.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gGMICDF.m | 1,058 | utf_8 | a8ecc3f457ad1127cf36f1cc5da6f0f5 | function icVals = gGMICDF(means,vars,cVals)
% function icVals = gGMICDF(means,vars,Cvals)
% compute inverse CDF of a gaussian mixture(s)
% each row of means and vars defines a mixture
% output icVals is (rows of means&vars) by (length of cVals)
icVals=zeros(size(means,1),length(cVals));
sds=sqrt(vars);
for ii=1... |
github | AndrewCWalker/rsm_tool_suite-master | computeLogLik.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/computeLogLik.m | 7,999 | utf_8 | cab080bb792a424e4b553052e849bdc1 | % function model = computeLogLik(model,data,C)
%
% Builds the log likelihood of the data given the model parameters.
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software p... |
github | AndrewCWalker/rsm_tool_suite-master | gpmmcmc.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gpmmcmc.m | 21,190 | utf_8 | 0c98b80fe8dff8fc32c33dc786814458 | % function [params hierParams] = gpmmcmc(params,nmcmc,varargin)
% params - a parameters struct or array of structs
% nmcmc - number of full draws to perform (overridden for stepInit mode)
% varargs are in string/value pairs
% 'noCounter' - default 0, 1 ==> do not output a counter of iterations
% 'step' - ... |
github | AndrewCWalker/rsm_tool_suite-master | gPred.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/gPred.m | 2,011 | utf_8 | c55122a8c3a1f97dc4ace2271cd35a75 | %function pred=gPred(xpred,pvals,model,data,mode,theta)
% Predict using a gpmsa constructed model.
% this is an interface to the new gPredict for backward compatibility
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This fi... |
github | AndrewCWalker/rsm_tool_suite-master | setupDefaultHierParams.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/setupDefaultHierParams.m | 3,063 | utf_8 | 69fff5dc392d1cc5a1bc4f30f9d4a835 | % This defines a hierarchical model parameter structure as an example.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
%
% This file was distributed as part of the GPM/SA software package
% Los Alamos Computer Code release LA-CC-0... |
github | AndrewCWalker/rsm_tool_suite-master | genDist.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/genDist.m | 2,605 | utf_8 | fc3644a58bfe56b543e25af38b5d6bbd | % function d = gendist(data,dataDesc);
% generates the nxnxp distance array values and supporting
% information, given the nxp location matrix x
% or if a d is passed in, just update the distances
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los A... |
github | AndrewCWalker/rsm_tool_suite-master | diagPlots.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/diagPlots.m | 8,497 | utf_8 | 808d30c93261db1c54070040fc633472 | % function ret=diagPlots(pout,pvec,plotNum,varargin)
% Some generic plots for GPS/SA diagnostics. Note that most plots of
% response surfaces and predictions are application specific because of
% the unknown structure of the data. (see basicExPlots for examples)
% pout - the structure output from a gaspMCMC function ... |
github | AndrewCWalker/rsm_tool_suite-master | stepsize.m | .m | rsm_tool_suite-master/Automated_RSM/MCMC/gpmsa/matlab/stepsize.m | 7,516 | utf_8 | cd004244c3bf737b639f5c735e93d34a | % function [params hierParams] = stepsize(params,nBurn,nLev,varargin)
% compute step sizes from step size data collect run in gpmmcmc
% please see associated documentation
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Author: James R. Gattiker, Los Alamos National Laboratory
% B... |
github | mbuckler/ReversiblePipeline-master | ImgPipe_Matlab.m | .m | ReversiblePipeline-master/src/Matlab/ImgPipe_Matlab.m | 18,556 | utf_8 | 3cb3d09d6499bf586ac0162d62fbe26d | %==============================================================
% Image Processing Pipeline
%
% This is a Matlab implementation of a pre-learned image
% processing model. A description of the model can be found in
% "A New In-Camera Imaging Model for Color Computer Vision
% and its Application" by Seon Joo Kim, Hai ... |
github | zhangliliang/caffe-master | classification_demo.m | .m | caffe-master/matlab/demo/classification_demo.m | 5,412 | utf_8 | 8f46deabe6cde287c4759f3bc8b7f819 | function [scores, maxlabel] = classification_demo(im, use_gpu)
% [scores, maxlabel] = classification_demo(im, use_gpu)
%
% Image classification demo using BVLC CaffeNet.
%
% IMPORTANT: before you run this demo, you should download BVLC CaffeNet
% from Model Zoo (http://caffe.berkeleyvision.org/model_zoo.html)
%
% *****... |
github | EnricoGiordano1992/LMI-Matlab-master | yalmiptest.m | .m | LMI-Matlab-master/yalmip/yalmiptest.m | 17,035 | utf_8 | 4a8ad7d56c1153743ca991381cc2f3a6 | function out = yalmiptest(prefered_solver,auto)
%YALMIPTEST Runs a number of test problems.
%
% YALMIPTEST is recommended when a new solver or a new version
% of YALMIP installed.
%
% EXAMPLES
% YALMIPTEST % Without argument, default solver used
% YALMIPTEST('solver tag') % Test with specified... |
github | EnricoGiordano1992/LMI-Matlab-master | solvesdp.m | .m | LMI-Matlab-master/yalmip/solvesdp.m | 15,551 | utf_8 | 8aa9cfafe34ac3e4c7a88041a3fd9d2d | function diagnostic = solvesdp(varargin)
%SOLVESDP Obsolete command, please use OPTIMIZE
yalmiptime = clock; % Let us see how much time we spend
% *********************************
% CHECK INPUT
% *********************************
nargin = length(varargin);
% First check of objective for early transfer to multiple s... |
github | EnricoGiordano1992/LMI-Matlab-master | deriveBasis.m | .m | LMI-Matlab-master/yalmip/modules/sos/deriveBasis.m | 323 | utf_8 | 0401f866c43215ad1c43d68dd8499dd3 | function H = deriveBasis(A_equ)
[L,U,P] = lu(A_equ);
[L,U,P] = lu(A_equ');
r = colspaces(L');
AA = L';
H1 = AA(:,r);
H2 = AA(:,setdiff(1:size(AA,2),r));
H = P'*[-H1\H2;speye(size(H2,2))];
function [indx]=colspaces(A)
indx = [];
for i = 1:size(A,2)
s = max(find(A(:,i)));
indx = [indx s];
end
indx = unique(indx)... |
github | EnricoGiordano1992/LMI-Matlab-master | postprocesssos.m | .m | LMI-Matlab-master/yalmip/modules/sos/postprocesssos.m | 3,702 | utf_8 | 6716cb77d4d92dcbb793f478d7c47993 | function [BlockedQ,residuals] = postprocesssos(BlockedA,Blockedb,BlockedQ,sparsityPattern,options);
BlockedQ=applysparsity(BlockedQ,sparsityPattern);
for passes = 1:1:options.sos.postprocess
for constraint = 1:length(BlockedQ)
mismatch = computeresiduals(BlockedA,Blockedb,BlockedQ,constraint);
[ii... |
github | EnricoGiordano1992/LMI-Matlab-master | generate_kernel_representation_data.m | .m | LMI-Matlab-master/yalmip/modules/sos/generate_kernel_representation_data.m | 9,746 | utf_8 | 408c65ea2806342ae7e7998a85c98ba7 | function [A,b] = generate_kernel_representation_data(N,N_unique,exponent_m2,exponent_p,p,options,p_base_parametric,ParametricIndicies,MonomIndicies,FirstRun)
persistent saveData
exponent_p_parametric = exponent_p(:,ParametricIndicies);
exponent_p_monoms = exponent_p(:,MonomIndicies);
pcoeffs = getbase(p);
if any(expo... |
github | EnricoGiordano1992/LMI-Matlab-master | solvebilevel.m | .m | LMI-Matlab-master/yalmip/modules/bilevel/solvebilevel.m | 28,584 | utf_8 | ca5553a39360503959e1ef8141c91ee0 | function [sol,info] = solvebilevel(OuterConstraints,OuterObjective,InnerConstraints,InnerObjective,InnerVariables,options)
%SOLVEBILEVEL Simple global bilevel solver
%
% min CO(x,y)
% subject to OO(x,y)>0
% y = arg min OI(x,y)
% subject to CI(x,y)>0
%
% [DIAGNOSTIC,INFO] = SOLVEBI... |
github | EnricoGiordano1992/LMI-Matlab-master | robust_classify_variables_newest.m | .m | LMI-Matlab-master/yalmip/modules/robust/robust_classify_variables_newest.m | 5,032 | utf_8 | 71ff61f98a9e321589e7b9db9f902871 | function [VariableType,F_x,F_w,F_xw,h] = robust_classify_variables_newest(F,h,ops,w);
Dependency = iterateDependance( yalmip('monomtable') | yalmip('getdependence') | yalmip('getdependenceUser'));
DependsOnw = find(any((Dependency(:,getvariables(w))),2));
h_variables = getvariables(h);
h_w = find(ismember(h_variable... |
github | EnricoGiordano1992/LMI-Matlab-master | filter_polya.m | .m | LMI-Matlab-master/yalmip/modules/robust/filter_polya.m | 5,003 | utf_8 | 55fbd1c40e70d698b82c42d8aee3287f | function [F_xw,F_polya] = filter_polya(F_xw,w,N)
F_polya = [];
Fvars = getvariables(F_xw);
wvars = getvariables(w);
[mt,vt] = yalmip('monomtable');
if ~(N==ceil(N)) & (N>=0)
error('The power in robust.polya must be a non-negative integer');
end
F_new = [];
if any(sum(mt(Fvars,wvars),2)>1)
removeF = zeros(lengt... |
github | EnricoGiordano1992/LMI-Matlab-master | dualtososrobustness.m | .m | LMI-Matlab-master/yalmip/modules/robust/dualtososrobustness.m | 3,252 | utf_8 | 499ac2bd7b66be04e843f1a3edb0611c | function SOSModel = dualtososrobustness(UncertainConstraint,UncertaintySet,UncertainVariables,DecisionVariables,p_tau_degree,localizer_tau_degree,Z_degree)
[E,F] = getEFfromSET(UncertaintySet);
[F0,Fz,Fx,Fxz] = getFzxfromSET(UncertainConstraint,UncertainVariables,DecisionVariables);
if is(UncertainConstraint,'sdp')... |
github | EnricoGiordano1992/LMI-Matlab-master | filter_duality.m | .m | LMI-Matlab-master/yalmip/modules/robust/filter_duality.m | 8,603 | utf_8 | 91b1d25b80045a73fe70a694f9784e1a | function [F,feasible] = filter_duality(F_xw,Zmodel,x,w,ops)
% Creates robustified version of the uncertain set of linear inequalities
% s.t A(w)*x <= b(w) for all F(w) >= 0 where F(w) is a conic set, here
% given in YALMIP numerical format.
%
% Based on Robust Optimization - Methodology and Applications. A. Ben-Tal
% ... |
github | EnricoGiordano1992/LMI-Matlab-master | filter_enumeration.m | .m | LMI-Matlab-master/yalmip/modules/robust/filter_enumeration.m | 7,383 | utf_8 | fd994fa46ec75e11eb5b4480d7d81510 | function [F,mptmissing] = filter_enumeration(F_xw,Zmodel,x,w,ops,uncertaintyTypes,separatedZmodel,VariableType)
mptmissing = 0;
if length(F_xw) == 0
F = [];
return;
else
if any(Zmodel.K.q) | any(Zmodel.K.s)
error('Only polytope uncertainty supported in duality based robustification');
else... |
github | EnricoGiordano1992/LMI-Matlab-master | decomposeUncertain.m | .m | LMI-Matlab-master/yalmip/modules/robust/decomposeUncertain.m | 25,501 | utf_8 | de52048b978e055a2e273ab28fa80d85 | function [UncertainModel,Uncertainty,VariableType,ops,failure] = decomposeUncertain(F,h,w,ops)
failure = 0;
% Do we have any uncertainty declarations variables?
[F,w] = extractUncertain(F,w);
if isempty(w)
error('There is no uncertainty in the model.');
end
% Partition the model into
% F_x : Constraints in de... |
github | EnricoGiordano1992/LMI-Matlab-master | root_node_tighten.m | .m | LMI-Matlab-master/yalmip/modules/global/root_node_tighten.m | 4,114 | utf_8 | 337752e11e3b4918818b979f123b0ae4 | % *************************************************************************
% Tighten bounds at root
% *************************************************************************
function p = root_node_tighten(p,upper);
p.feasible = all(p.lb<=p.ub) & p.feasible;
if p.options.bmibnb.roottight & p.feasible
pin = p;
... |
github | EnricoGiordano1992/LMI-Matlab-master | update_sumsepquad_bounds.m | .m | LMI-Matlab-master/yalmip/modules/global/update_sumsepquad_bounds.m | 2,079 | utf_8 | 88e62143dd9ee6975b8f13423f79f346 | function p = update_sumsepquad_bounds(p);
% Looking for case z = b+ q1(x1) + q2(x2) + ... where q quadratic
if p.boundpropagation.sepquad
found = 0;
for j = 1:p.K.f
a = p.F_struc(j,2:end);
b = p.F_struc(j,1);
used = find(a);
data = [];
if nnz(a) > 2 && all(p.variabletype... |
github | EnricoGiordano1992/LMI-Matlab-master | updateonenonlinearbound.m | .m | LMI-Matlab-master/yalmip/modules/global/updateonenonlinearbound.m | 805 | utf_8 | 97d5341706cf3ef397ec3383332f38ee | % *************************************************************************
% Code for setting the numerical values of nonlinear terms
% *************************************************************************
function p = updateonenonlinearbound(p,changed_var)
if ~isempty(p.bilinears)
impactedVariables = find((p.... |
github | EnricoGiordano1992/LMI-Matlab-master | dmpermblockeig.m | .m | LMI-Matlab-master/yalmip/modules/global/dmpermblockeig.m | 3,417 | utf_8 | 7b1470816ba1634bcc2b8457f9a98036 | function [V,D,permutation,failure] = dmpermblockeig(X,switchtosparse)
[permutation,aux1,aux2,blocks] = dmperm(X+speye(length(X)));
Xpermuted = X(permutation,permutation);
V = [];
D = [];
V = zeros(size(X,1),1);
top = 1;
left = 1;
anycholfail = 0;
failure = 0;
for i = 1:length(blocks)-1
Xi = Xpermuted(blocks(... |
github | EnricoGiordano1992/LMI-Matlab-master | evaluate_nonlinear.m | .m | LMI-Matlab-master/yalmip/modules/global/evaluate_nonlinear.m | 1,184 | utf_8 | 6cee29d0c8963567fd541ab3ee434dcf | function x = evaluate_nonlinear(p,x,qq)
% FIX: We have to apply computations to make sure we are evaluating
% expressions such as log(1+sin(x.^2).^2) correctly
if ~isempty(p.bilinears) & all(p.variabletype <= 2) & length(p.evalMap)==0
x(p.bilinears(:,1)) = x(p.bilinears(:,2)).*x(p.bilinears(:,3));
else
oldx =... |
github | EnricoGiordano1992/LMI-Matlab-master | cutsdp.m | .m | LMI-Matlab-master/yalmip/modules/global/cutsdp.m | 26,156 | utf_8 | b0da964912e005a872def387efd1ee2c | function output = cutsdp(p)
% CUTSDP
%
% See also OPTIMIZE, BNB, BINVAR, INTVAR, BINARY, INTEGER
% *************************************************************************
%% INITIALIZE DIAGNOSTICS IN YALMIP
% *************************************************************************
bnbsolvertime = clock;
showprogres... |
github | EnricoGiordano1992/LMI-Matlab-master | bnb_solvelower.m | .m | LMI-Matlab-master/yalmip/modules/global/bnb_solvelower.m | 6,280 | utf_8 | 2876e0b094d4dbbf73fc45f1454c259e | function output = bnb_solvelower(lowersolver,relaxed_p,upper,lower)
if all(relaxed_p.lb==relaxed_p.ub)
x = relaxed_p.lb;
if checkfeasiblefast(relaxed_p,relaxed_p.lb,relaxed_p.options.bnb.feastol)
output.problem = 0;
else
output.problem = 1;
end
output.Primal = x;
return
end
p ... |
github | EnricoGiordano1992/LMI-Matlab-master | addEvalVariableCuts.m | .m | LMI-Matlab-master/yalmip/modules/global/addEvalVariableCuts.m | 4,555 | utf_8 | ab6e9b7499b292402a9904e71b95ce68 | function pcut = addEvalVariableCuts(p)
pcut = p;
if ~isempty(p.evalMap)
pcut = emptyNumericalModel;
for i = 1:length(p.evalMap)
y = p.evalVariables(i);
x = p.evalMap{i}.variableIndex;
xL = p.lb(x);
xU = p.ub(x);
% Generate a convex hull polytope
if xL<x... |
github | EnricoGiordano1992/LMI-Matlab-master | branch_and_bound.m | .m | LMI-Matlab-master/yalmip/modules/global/branch_and_bound.m | 27,802 | utf_8 | c2c7870f7780fbb463c2844fe548b6b5 | function [x_min,solved_nodes,lower,upper,lower_hist,upper_hist,timing,counter] = branch_and_bound(p,x_min,upper,timing)
% *************************************************************************
% Create handles to solvers
% *************************************************************************
lowersolver = p.sol... |
github | EnricoGiordano1992/LMI-Matlab-master | propagate_bounds_from_equalities.m | .m | LMI-Matlab-master/yalmip/modules/global/propagate_bounds_from_equalities.m | 10,554 | utf_8 | 9d6b2fdfcaad8b64e3dc2691481565a7 | function p = propagate_bounds_from_equalities(p)
LU = [p.lb p.ub];
p_F_struc = p.F_struc;
n_p_F_struc_cols = size(p_F_struc,2);
fixedVars = find(p.lb == p.ub & p.variabletype(:) == 0);
if ~isempty(fixedVars)
p_F_struc_forbilin = p_F_struc;
p_F_struc_forbilin(:,1) = p_F_struc(:,1) + p_F_struc(:,1+fixedVars)*p... |
github | EnricoGiordano1992/LMI-Matlab-master | bnb.m | .m | LMI-Matlab-master/yalmip/modules/global/bnb.m | 43,995 | utf_8 | 03312500b49d6a12f8d2d4a75db4c1cc | function output = bnb(p)
%BNB General branch-and-bound scheme for conic programs
%
% BNB applies a branch-and-bound scheme to solve mixed integer
% conic programs (LP, QP, SOCP, SDP) and mixed integer geometric programs.
%
% BNB is never called by the user directly, but is called by
% YALMIP from SOLVESDP, by ... |
github | EnricoGiordano1992/LMI-Matlab-master | update_monomial_bounds.m | .m | LMI-Matlab-master/yalmip/modules/global/update_monomial_bounds.m | 2,544 | utf_8 | d5ad776f01d587f1e7c5b70478d633e6 | function model = update_monomial_bounds(model,these)
if nargin == 1 & all(model.variabletype<=2) & any(model.variabletype)
% Fast code for purely quadratic case
x = model.bilinears(:,2);
y = model.bilinears(:,3);
z = model.bilinears(:,1);
corners = [model.lb(x).*model.lb(y) model.ub(x).*model.lb(y)... |
github | EnricoGiordano1992/LMI-Matlab-master | updatebounds_recursive_evaluation.m | .m | LMI-Matlab-master/yalmip/modules/global/updatebounds_recursive_evaluation.m | 1,128 | utf_8 | ea7474325c03f63f6c8e286a9ab08de8 | function p = updatebounds_recursive_evaluation(p)
if p.changedbounds
if isempty(p.evalMap) & all(p.variabletype <= 2)
% Bilinear/quadratic case can be done much faster
p = updatemonomialbounds(p);
else
for i = 1:length(p.evaluation_scheme)
switch p.evaluation_scheme{i}.group... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.