tag:www.mathworks.com,2005:/matlabcentral/fileexchange/feedMATLAB Central File Exchangeicon.pnglogo.pngMATLAB Central - File ExchangeUser-contributed code library2015-03-31T17:01:15-04:00235201100tag:www.mathworks.com,2005:FileInfo/503552015-03-31T20:21:22Z2015-03-31T20:56:06ZA rational approximation of the Voigt functionRapid and accurate computation of the Voigt function<p>This function file is a subroutine for rapid and accurate computation of the Voigt function. It covers the domain of practical interest 0 &lt; x &lt; 40,000 and 10^-4 &lt; y &lt; 10^2 required for applications using the HITRAN molecular spectroscopic database. The average accuracy in this domain is 10^-14. Use opt = 1 for more accurate and opt = 2 for more rapid computation. By default opt = 1.</p>Sanjar Abrarovhttp://www.mathworks.com/matlabcentral/profile/authors/5597508-sanjar-abrarovMATLAB 7.9 (R2009b)falsetag:www.mathworks.com,2005:FileInfo/503562015-03-31T20:41:45Z2015-03-31T20:44:40ZInduction Motor with arbitrary reference frameThe reference frame speed (w) can be chosen as the user needs<p>Induction Motor with arbitrary reference frame,The reference frame speed (w) can be chosen as the user needs ,it can be zero ,synchronous speed ,rotor speed ,...etc.,The model was taken from "Paul C.Krause, Analysis of electric machinery and drive system, Second Edition",Chapter 4</p>Mohammad AWawdehhttp://www.mathworks.com/matlabcentral/profile/authors/6253004-mohammad-awawdehMATLAB 8.2 (R2013b)SimulinkMATLABfalsetag:www.mathworks.com,2005:FileInfo/503542015-03-31T18:32:58Z2015-03-31T18:32:58ZChebyshev to monomial basisChebyshev to monomial basis conversion<p>B = CHEB2MON(A) converts polynomial A given in Chebyshev basis to
<br />monomial basis B. The polynomial must be given with its coefficients in
<br />descending order, i.e. A = A_N*T_N(x) + ... + A_1*T_1(x) + A_0*T_0(x)
<br />Example:
<br />&nbsp;&nbsp;&nbsp;&nbsp;Suppose we have a polynomial in Chebyshev basis:
<br />&nbsp;&nbsp;&nbsp;&nbsp;a2*T_2(x) + a1*T_1(x) + a0*T_0(x), where T_0=1, T_1=x, T_2=2x^2-1
<br />&nbsp;&nbsp;&nbsp;&nbsp;and for example a2=1, a1=0, a0=-1.
<br />&nbsp;&nbsp;&nbsp;&nbsp;We want to express the polynomial in the monomial base {1,x,x^2), i.e.
<br />&nbsp;&nbsp;&nbsp;&nbsp;a2*T_2(x) + a1*T_1(x) + a0*T_0(x) = b2*x^2 + b1*x + b0,
<br />&nbsp;&nbsp;&nbsp;&nbsp;where b = [b2 b1 b0] is sought.
<br />&nbsp;&nbsp;&nbsp;&nbsp;Solution:
<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a = [1 0 -1];
<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;b = cheb2mon(a);</p>Zoltán Csátihttp://www.mathworks.com/matlabcentral/profile/authors/2924415-zoltan-csatiMATLAB 7.12 (R2011a)MATLABfalsetag:www.mathworks.com,2005:FileInfo/503532015-03-31T18:27:49Z2015-03-31T18:28:56ZMonomial to Chebyshev basisMonomial to Chebyshev basis conversion<p>A = MON2CHEB(B) converts polynomial B given in monomial basis to
<br />Chebyshev basis A. The polynomial must be given with its coefficients
<br />in descending order, i.e. B = B_N*x^N + ... + B_1*x + B_0
<br />Example:
<br />&nbsp;&nbsp;&nbsp;&nbsp;Suppose we have a polynomial in the monomial basis:
<br />&nbsp;&nbsp;&nbsp;&nbsp;b2*x^2 + b1*x + b0,
<br />&nbsp;&nbsp;&nbsp;&nbsp;with b2=2, b1=0, b0=-2 for example.
<br />&nbsp;&nbsp;&nbsp;&nbsp;We want to express the polynomial in the Chebyshev base
<br />&nbsp;&nbsp;&nbsp;&nbsp;{T_0(x),T_1(x),T_2(x)}, where T_0=1, T_1=x, T_2=2x^2-1, i.e.
<br />&nbsp;&nbsp;&nbsp;&nbsp;a2*T_2(x) + a1*T_1(x) + a0*T_0(x) = b2*x^2 + b1*x + b0,
<br />&nbsp;&nbsp;&nbsp;&nbsp;where a = [a2 a1 a0] is sought.
<br />&nbsp;&nbsp;&nbsp;&nbsp;Solution:
<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;b = [2 0 -2];
<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;a = mon2cheb(b);</p>Zoltán Csátihttp://www.mathworks.com/matlabcentral/profile/authors/2924415-zoltan-csatiMATLAB 7.12 (R2011a)MATLABfalsetag:www.mathworks.com,2005:FileInfo/394462012-12-12T18:11:47Z2015-03-31T18:14:20ZBallistic Interplanetary Trajectory Design and Optimization A MATLAB Script for Ballistic Interplanetary Trajectory Design and Optimization <p>PDF document and a MATLAB script called ipto_matlab that can be used to design and optimize “patched conic” ballistic interplanetary trajectories between any two planets of our solar system. It can also be used to find two-body trajectories between a planet and an asteroid or comet. A patched-conic trajectory ignores the gravitational effect of both the launch and arrivals planets on the heliocentric transfer trajectory. This technique involves the solution of Lambert's problem relative to the Sun. Patched-conic trajectories are suitable for preliminary mission design. This script uses the SNOPT nonlinear programming (NLP) algorithm to solve this classic astrodynamics problem.
<br />The ipto_matlab MATLAB script also performs a graphical primer vector analysis of the solution. This program feature displays the behavior of the primer vector magnitude and primer derivative magnitude as a function of mission elapsed time in days from departure.
</p>David Eaglehttp://www.mathworks.com/matlabcentral/profile/authors/1362330-david-eagleMATLAB 8.0 (R2012b)Requires platform-specific version of SNOPT available at scicomp.ucsd.edu/~peg/ and the DE424 binary ephemeris file available at celestialandorbitalmechanicswebsite.yolasite.com. MICE version requires mex and binary ephemeris files available from NAIF.falsetag:www.mathworks.com,2005:FileInfo/503522015-03-31T17:05:29Z2015-03-31T17:16:45ZComparison OF LEACH Vs DEEC Protocols.<p>Wireless Sensor Network is the network of power-limited sensing devices called sensors. Wireless sensor network is differ from other networks in terms of optimization of amount of energy because when these sensors sense and transmit data to other sensors present in the network, considerable amount of energy is dissipated. Various routing algorithms are proposed to limit the powers used by the wireless sensors. Hierarchical routing protocols with the concept of clustering like LEACH and and DEEC are already best known for maintaining energy efficiency. In this submission, we will compare these two protocols.</p>Akshay Gorehttp://www.mathworks.com/matlabcentral/profile/authors/4476653-akshay-goreMATLAB 8.3 (R2014a)Communications System Toolboxfalsetag:www.mathworks.com,2005:FileInfo/503512015-03-31T16:57:02Z2015-03-31T16:57:02ZFractional Order Extremum Seeking ControlFO-ESC improves the performance of IO-ESC using fractional order operators<p>In this simulation a new extremum seeking approach called "Fractional Order Extremum Seeking Control (FO-ESC)" is simulated and the ability of this algorithm in finding the peak power point of a PV panel is demonstrated. According to various researchers, a well tuned FO-ESC has a better efficiency compared to other ESC algorithms like Integer Order ESC, P&O or IC. This simulation needs c-compiler (to setup a c-compiler in your matlab use mex -setup). For more information please check:
<br />1- Hadi Malek, YangQuan Chen, "Fractional Order Power Point Tracking"
<br />2- Hadi Malek, Sara Dadras, YangQuan Chen, "A fractional order maximum power point tracker: Stability analysis and experiments".
<br />3- Hadi Malek, YangQuen Chen, A single-stage three-phase grid-connected photovoltaic system with fractional order MPPT</p>Hadi Malekhttp://www.mathworks.com/matlabcentral/profile/authors/2783698-hadi-malekMATLAB 8.1 (R2013a)Simulinkc-compiler48459falsetag:www.mathworks.com,2005:FileInfo/503502015-03-31T15:50:50Z2015-03-31T15:50:50Zzoom_wheel(hfig,options)Zoom in and out using the wheel in a rather practical manner<p>% ZOOM IN AND OUT USING THE MOUSE WHEEL
<br />This codes implements the zoom in figures using the wheel.
<br />This is done by modifying the WindowScrollWheelFcn callback function.</p>
<p>% SYNTAX:</p>
<p>*) zoom_wheel: will add the zoom functionality in the current figure.
<br />*) zoom_wheel(hfig): will add the zoom functionality in the figure
<br />identified with the figure handle hfig.
<br />*) zoom_wheel(options): will add the zoom functionality in the current
<br />figure with customization given by options.
<br />*) zoom_wheel(hfig, options): will add the zoom functionality in the figure
<br />identified with the figure handle hfig with customization given by options.</p>
<p>% INPUT ARGUMENTS</p>
<p>*) hfig: Figure handle. If none is provided, current figure will be
<br />employed.
<br />*) options: Structure with the following fields for customizing the behaviour of the zoom functionality
<br />&nbsp;&nbsp;&nbsp;*) Magnify: General magnitication factor. Unity or greater (by default 1.1).
<br />&nbsp;&nbsp;&nbsp;*) XMagnify: Magnification factor of X axis (unity by default).
<br />&nbsp;&nbsp;&nbsp;*) YMagnify: Magnification factor of Y axis (unity by default).
<br />&nbsp;&nbsp;&nbsp;*) ChangeMagnify: Relative increase of the magnification factor. Unity or greater (by default 1.1).
<br />&nbsp;&nbsp;&nbsp;*) IncreaseChange: Relative increase in the ChangeMagnify factor. Unity or greater (by default 1.1).
<br />&nbsp;&nbsp;&nbsp;*) MinValue: Sets the minimum value that Magnify, ChangeMagnify and
<br />&nbsp;&nbsp;&nbsp;IncreaseChange can take.
<br />&nbsp;&nbsp;&nbsp;*) Pause: Number of seconds that information about the value of
<br />&nbsp;&nbsp;&nbsp;Magnify and ChangeMagnify will be displayed everytime their value if
<br />&nbsp;&nbsp;&nbsp;changed.</p>
<p>% BEHAVIOUR:</p>
<p>The magnification along the X axis is given by the formula</p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;options.Magnify * options.XMagnify</p>
<p>and analogously for the Y axis. Whether zooming in (incrementing the
<br />distance between data points) or zooming out (decrementing the distance
<br />between data points) depends on the direction of rotation of the mouse wheel.</p>
<p>When *shift* is pressed, the rotation of the mouse wheel changes the
<br />value of options.Magnify according to the following:</p>
<p>&nbsp;&nbsp;&nbsp;options.Magnify &lt;- options.Magnify * options.ChangeMagnify</p>
<p>and if *Ctrl* is pressed, the rotation of the mouse wheel changes the
<br />value of options.ChangeMagnify according to the following:</p>
<p>&nbsp;&nbsp;&nbsp;options.ChangeMagnify &lt;- options.ChangeMagnify * options.IncreaseChange</p>
<p>When pressing *Alt* while moving the wheel, the zoom returns to the
<br />original state, but not the values of options.</p>
<p>Notice that, in order to add this functionality, zoom_wheel modifies
<br />the WindowScrollWheelFcn callback function in your figure, loosing
<br />nay previous functionality this callback function may have provided
<br />for the particular figure zoom_wheel is applied on.</p>
<p>% EXAMPLES:</p>
<p>h=figure(1);
<br />plot(rand(100,1),rand(100,1));</p>
<p>options.Magnify = 1.05;
<br />options.ChangeMagnify = 1.2;
<br />zoom_wheel(h,options);</p>
<p>% Please, report any bugs to <a href="mailto:Hugo.Eyherabide@cs.helsinki.fi">Hugo.Eyherabide@cs.helsinki.fi</a></p>
<p>% Copyright (c) 2015, Hugo Gabriel Eyherabide, University of Helsinki, Finland.
<br />All rights reserved.</p>
<p>Redistribution and use in source and binary forms, with or without
<br />modification, are permitted provided that the following conditions
<br />are met:</p>
<p>1. Redistributions of source code must retain the above copyright
<br />notice, this list of conditions and the following disclaimer.</p>
<p>2. Redistributions in binary form must reproduce the above copyright
<br />notice, this list of conditions and the following disclaimer in the
<br />documentation and/or other materials provided with the distribution.</p>
<p>THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
<br />"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
<br />LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
<br />FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
<br />HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
<br />SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
<br />TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
<br />OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
<br />OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
<br />(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
<br />OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</p>Hugohttp://www.mathworks.com/matlabcentral/profile/authors/3606063-hugoMATLAB 8.5 (R2015a)falsetag:www.mathworks.com,2005:FileInfo/344282012-01-03T07:53:58Z2015-03-31T15:20:23ZVoronoiLimitConstrain the vertices of a Voronoi decomposition to the domain of the input data. <p>The routine performs a Voronoi decomposition of an input dataset and constrains the vertices to the domain of the data themselves, such that even unbounded Voronoi cells become useful polygons (See attached figure).
<br />UPDATES:
<br />[25th March 2015]: The routine has been updated to allow for the description of both an external boundary and multiple internal boundaries. See help for info.
<br />[29th March 2015]: Bugfixes
<br />[31th March 2015]: Bugfixes</p>Jakob Sievershttp://www.mathworks.com/matlabcentral/profile/authors/2982198-jakob-sieversMATLAB 7.13 (R2011b)Mapping Toolboxfalsetag:www.mathworks.com,2005:FileInfo/499742015-03-10T21:48:20Z2015-03-31T15:00:42ZBEADS: Baseline Estimation And Denoising w/ Sparsity (chromatogram signals)Remove baseline, background or drift and random noise from positive and sparse chromatographic peaks<p>The BEADS toolbox jointly addresses the problem of simulateous baseline correction and noise reduction, for positive and sparse signals arising in analytical chemistry (Raman, infrared, XRD, etc.), here applied to gas chromatography signals. The baseline is similar to slow-varying trends, intrumental drifts or background offset. The proposed baseline filtering algorithm is based on modeling the series of chromatogram peaks as mostly positive, sparse with sparse derivatives, and on modeling the baseline as a low-pass signal. A convex optimization problemis formulated so as to encapsulate these non-parametric models. To account for the positivity of chromatogram peaks, an asymmetric penalty function, similar to a regularized l1 norm is utilized. A robust, computationally efficient, iterative algorithm is developed that is guaranteed to converge to the unique optimal solution. It implements the method published in the paper "Chromatogram baseline estimation and denoising using sparsity (BEADS)", by Xiaoran Ning, Ivan W. Selesnick, Laurent Duval, in Chemometrics and Intelligent Laboratory Systems, December 2014, <a href="http://dx.doi.org/10.1016/j.chemolab.2014.09.014">http://dx.doi.org/10.1016/j.chemolab.2014.09.014</a>
<br />The ZIP file contains two Matlab functions:
<br />&nbsp;&nbsp;&nbsp;&nbsp;* a demonstration script (example.m);
<br />&nbsp;&nbsp;&nbsp;&nbsp;* the main function (beads.m),
<br />and an html readme help.</p>Laurent Duvalhttp://www.mathworks.com/matlabcentral/profile/authors/11936-laurent-duvalMATLAB 7.13 (R2011b)MATLAB2491627429false