Login
Password
Sources on this Page

> Headlines by Category

 Home / Science / Mathematics

You are using the plain HTML view, switch to advanced view for a more complete experience.

Simple Matlab Program to calculate Euler Buckling Load using Finite Element Method

EI d^2 y/ dx^2 +Py =0, y(0)=0, y(L)=0.
A weak form using weighing function w(x) such that w(0)=0, w(L)=0. w(x) is piece wise linear interpolation function.
Writing the weak form, we get
-int 0 to L dw/dx dy/dx dx + lamda int 0 to L w(x) y(x) dx =0
Using the linear shape functions as shown below:
w(x) = N1(x) w1+ N2(x) w2,
y(x)= N1(x) y1_+ N2(x) y2.
we get
 kdet= k0*P/(E*I)-k1;
We find the values of P such that the det(kdet) goes to zero.

Probabilistic analysis of IEEE 802.11 (802.11e)

Several Matlab files intended to compute:
1/ the probability that a specified wireless station wins the contention,
2/ the probability that collision occurs,
according to Enhanced Distributed Coordination Access (EDCA) established in the IEEE 802.11 standard.
The algorithms used are described in the paper:
Rajmic, P., Hošek, J., Fusek, M., Andreev, S. and Stecík, J.:
Simplified Probabilistic Modelling and Analysis of Enhanced Distributed Coordination Access in IEEE 802.11. The Computer Journal (2015) 58 (6): 1456-1468. doi: 10.1093/comjnl/bxu081
(free for download here: http://www.utko.feec.vutbr.cz/~rajmic/papers/The%20Computer%20Journal-2014-Rajmic-comjnl_bxu081.pdf)

Contact: rajmic@feec.vutbr.cz

le diagramme de bode

description de diagramme de bode

Multidimensional Archimedean copula density

Computes the density of some multidimensional Archimedean copulas (Gumbel, Frank, and Clayton). Based on:
  Hofert, M., Mächler, M., & McNeil, A. J. (2012). doi:10.1016/j.jmva.2012.02.019.
Employed in:
  Díaz, G. (2013). A note on the multivariate Archimedean dependence structure in small wind generation sites.
  Wind Energy, 18(8), 1287–1295. doi:10.1002/we.1633

Transform velocity field into wall coordinates

[xw,yw,uw,vw,xgr,ygr,ugr,vgr] = VELOCITYPROFILE(xwall,ywall,x,y,u,v,height,varargin)
Interpolates the velocity field provided by [x,y,u,v] on a grid generated
as an offset of a 2D curve [xwall,ywall] and transforms the interpolated
field into wall coordinates, rotating each vector according to the wall
angle.
Typical example: plot of the boundary layer of an airfoil, provided the
velocity field and the airfoil points.

[xwall,ywall] are the coordinates of the wall

[x,y,u,v] are the points and the components of the velocity field (can be
both structured or unstructured)

[height] is the extent of the profile in the direction normal to the
wall

 Additional input arguments are:
VELOCITYPROFILE(xwall,ywall,x,y,u,v,height,Nh,Nw,interp_type,graphic_mode)

[Nh] is number of points in which the grid is discretised vertically.
Default value is 20

[Nw] is number of points in which the grid is discretised horizontally.
By default, the points provided for the wall are used to generate the
grid. If Nw is specified, wall points are interpolated in Nw new
locations

[interp_type]: type of interpolant ('nearest', 'linear' or 'natural'), see
scatteredInterpolant for additional info on the interpolation method.
Values outside the velocity field will always be linarly extrapolated

[graphic_mode]: true or false, create two figures with the velocity data
to show the result of the conversion

 Output arguments
[xw,yw,uw,vw]: are the points and the components of the velocity data
rotated into wall coordinates. The first elements of uw and vw are the
velocities for the first point of the provided wall. Elements for the
successive columns are the velocities on the successive elements of the
wall.

[xgr,ygr,ugr,vgr]: are the points and the components of the velocity data
interpolated on the wall generated grid, before the coordinate
transformation

 Additional info
The direction in which the mesh is extended can be changed flipping the
wall points direction. See fliplr

The interpolation is performed using the scatteredInterpolant function,
which uses a Delaunay triangulation. If no vectors are provided on the
wall, those values will be interpolated (or extrapolated) using a
Delaunay triangulation of the entire flow field. See help
scatteredInterpolant for more information.

Run the code without any input argument to see an example

Author: Alessandro Masullo 2016

Export figures in high quality PNG using Inkscape

Matlab function for exporting figures in PNG is terrible. There is no anti-alias (although something better has been tried with the new graphic engine) and even increasing the exported file resolution, images still look horrible.
The best solution that I've found for exporting images in a nice way is saving them in SVG and exporting them to PNG using Inkscape, but this requires a lot of time. For this reason, I coded this very basic routine that takes care of everything: first, the image is saved in a vectorial format (SVG) using "print", then Inkscape is invoked through command line to export the SVG file in a PNG with the desired resolution.
This function uses Matlab internal SVG printer, which has been introduced since R2014a. If you have a previous Matlab version you may want to use the following script from the File exchange to export images to SVG:
http://www.mathworks.com/matlabcentral/fileexchange/7401-scalable-vector-graphics--svg--export-of-figures

Sunset

Year, month, day, lambda (Geographic east longitude of the observer in [rad]), phi (Geographic latitude of the observer in [rad]), zone (Difference local time - universal time in [h]) and twilight (Indicates civil, nautical or astronomical twilight) are received, then rising and setting times of Sun and Moon and twilight times are computed

Optometrika

Optometrika library implements ray tracing approximation to optical image formation using Snell’s and Fresnel’s laws of refraction and reflection.
    Currently, the library implements refractive and reflective general surfaces, aspheric (conic) surfaces, Fresnel surfaces, cones, cylinders, planes, circular and ring-shaped apertures, rectangular flat screens, spheroidal screens, and a realistic model of the human eye with accommodating lens and spheroidal retina. See example*.m files for examples of ray tracing in general (user-defined shape) lenses, aspheric lenses, Fresnel lenses, prisms, mirrors, and human eye.
    The library traces refracted rays, including intensity loss at the refractive surface. Reflected rays are currently traced for mirrors and also for a single total internal reflexion, if it happens. Note that the Bench class object is not a real physical bench, it is only an ordered array of optical elements, and it is your responsibility to arrange optical objects in the right order. In particular, if you need to trace rays passing through the same object multiple times, you have to add the object multiple times to the bench array in the order the object is encountered by the rays. For example, double refraction/reflection for cylindrical and conical surfaces can be calculated by adding the surface twice to the bench.
    The library is very compact and fast. It was written using Matlab classes and is fully vectorized. It takes about 2 seconds to trace 100,000 rays through an external lens and the human eye (8 optical surfaces) on a 3 GHz Intel Core i7 desktop. Fresnel lens tracing is somewhat slower due to looping through the Fresnel cones describing the lens surface. Tracing through user-defined (general) surfaces is significantly slower due to iterative search of ray intersections with the surface.
Thank you for downloading Optometrika, enjoy it!

Arbitrary Crest Factor / Kurtosis Noise Generation with Matlab Implementation

The present codes are a set of Matlab functions that provides a generation of noise signal with arbitrary crest factor or kurtosis.
Two examples are given in order to clarify the usage of the function. The input and output arguments are given in the beginning of the codes. The generated signal has a crest factor within +/- 0.1 dB (+/- 1,16 %) of desired one and +/- 1 % of desired kurtosis, unity standard deviation and zero mean value.

The code is based on the theory described in:

[1] D. Smallwood. Generating non-Gaussian vibration for testing purposes. Sound and Vibration, Vol. 39, No. 10, 2005, pp. 18-23.

[2] D. Smallwood. Generation of Stationary Non-Gaussian Time Histories with a Specified Cross-spectral Density. Shock and Vibration, Vol. 4, No. 5-6, 1997, pp. 361-377.

Monte Carlo Estimation Examples with Matlab Implementation

The codes presented here are a set of examples of Monte Carlo estimation methods, a class of computational algorithms that rely on repeated random sampling or simulation of random variables to obtain numerical results.
Six examples are given:
MonteCarloCoin.m – estimation of the probability to obtain 8 or more heads, if a coin is tossed 10 times;
MonteCarloInt.m – estimation of the integral of abs(sin(x)) for x = 0 .. 2*pi;
MonteCarloPi.m – estimation of the Pi value;
MonteCarloSqrt2.m – estimation of the sqrt(2) value;
MonteCarloVol.m – estimation of the unit sphere volume;
MonteCarloVol_visualization.m – a visualization of the MonteCarloVol example.
The codes are based on the theory described in:

[1] I. Sobol. A primer for the Monte Carlo method. Boca Raton, CRC Press, 1994.

Post Selected Items to:

Showing 10 items of 584

home  •   advertising  •   terms of service  •   privacy  •   about us  •   contact us  •   press release design by Popshop •   Official PR partner PRNews.io •   © 1999-2016 NewsKnowledge