-
DateConvert
DateConvert:简单而快速的日期转换
DateConvert转换DATESTR(0)格式的日期向量或序列号和日期向后。
Matlab的DATENUM,DATEVEC和DATESTR接受各种不同意见,但结果他们是缓慢的。如果输入格式正是众所周知,转换可以更快:
DATENUM( 17 - 10 - 2009 11时08分23秒 ):2.97秒
DateConvert( 17 - 10 - 2009 11时08分23秒 , 号码 ):0.039秒
=>“1.3%(1000环,1.5GHz的奔腾- M的,利用Matlab 7.7)
DateConvert不*不*验证作为Matlab的日期函数输入日期:
DATEVEC( 32 - 2 - 2008 25:62:63 )的答复[2008 3 4 2 2 7]
DateConvert( 32 - 2 - 2008 25:61:67 , 载体 )的答复[2008 2 32 25 61 67]!
因此DateConvert几乎微不足道,但对速度进行了优化。我需要时间排序200 000邮票,并从217个减少到11秒的时间。
请运行单元测试TestDateVec检查的有效性和速度。
测试:利用Matlab 6.5,7.7,7.8,winxp的,32位。
纯Matlab代码,所以兼容性的MacOS,Linux操作系统,64位预期。
英语月份名称是必要的。(DateConvert: Simple but fast date conversion
DateConvert converts the DATESTR(0) format to a date vector or serial date number and backwards.
Matlab s DATENUM, DATEVEC and DATESTR accept a variety of inputs, but in consequence they are slow. If the input format is exactly known, the conversion can be much faster:
DATENUM( 17-Oct-2009 11:08:23 ): 2.97 sec
DateConvert( 17-Oct-2009 11:08:23 , number ): 0.039 sec
=> 1.3 (1000 loops, 1.5GHz Pentium-M, Matlab 7.7)
DateConvert does*not* validate the input date as Matlab s date functions:
DATEVEC( 32-Feb-2008 25:62:63 ) replies [2008 3 4 2 2 7],
DateConvert( 32-Feb-2008 25:61:67 , vector ) replies [2008 2 32 25 61 67] !
So DateConvert is nearly trivial, but optimized for speed. I needed it for sorting 200 000 time stamps and reduced the time from 217 to 11 sec.
Please run the unit-test TestDateVec to check validity and speed.
Tested: Matlab 6.5, 7.7, 7.8, WinXP, 32bit.
Pure Matlab code, so compat)
- 2010-07-05 11:59:46下载
- 积分:1
-
IFMT
能够非常清楚的看出幅值和时间的变化规律,不用再画时、频图(Can very clear indication of the amplitude and the change of time rule,Don t draw, frequency chart)
- 2012-03-22 16:38:35下载
- 积分:1
-
1
说明: 用于优化的模拟退火算法,在传统的基础上有所改进的C源代码(Simulated annealing algorithm for optimization, based on the traditional improvement of the C source code)
- 2011-08-22 16:11:59下载
- 积分:1
-
pso
系统参数优化算法,可以用于系统的pid参数寻优,在matlab可以直接寻优(System parameter optimization algorithm can be used for the pid of the system parameter optimization, optimization in matlab can)
- 2011-11-10 16:29:04下载
- 积分:1
-
fft_matlab
fft算法在matlab上的实现,东南大学研究生项目所用(fft algorithm realization in matlab, used by the seu postgraduate)
- 2012-09-16 14:13:02下载
- 积分:1
-
cofactor
this function used to calculate COFACTOR
- 2012-10-03 22:29:56下载
- 积分:1
-
9927421droop_control
说明: droop control in micro grid
- 2020-03-31 01:58:47下载
- 积分:1
-
信号处理工具箱
说明: 做时频分析需要用到的工具箱,可以安装到matlab的toolbox里面,非常好用。(ime frequency analysis needs to use the toolbox, can be installed in the toolbox of MATLAB, very easy to use.)
- 2020-08-19 11:00:19下载
- 积分:1
-
lvbo
一个带通滤波器,模拟Gelileo卫星中频滤波,显示频谱。(A band-pass filter, an analog IF filter Gelileo satellite.)
- 2013-12-15 12:33:37下载
- 积分:1
-
control
This file contains different algorithms of control in simulink matlab.
- 2014-01-07 17:10:34下载
- 积分:1