-
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
-
08041107
基于随机共振的弱信号检测,sr为龙格库塔方法解方程,rs为检测的主程序(Based on stochastic resonance in weak signal detection, sr for the Runge-Kutta method to solve the equation, rs for the detection of the main program)
- 2010-02-07 01:37:24下载
- 积分:1
-
Knn
MATLAB 聚类和近邻搜索模块代码如下(MATLAB clustering and nearest neighbor search module code is as follows)
- 2011-04-28 22:48:22下载
- 积分:1
-
1.6-last
programs in matlab designing
- 2014-12-13 13:25:58下载
- 积分:1
-
DBSCAN
说明: DBSCAN聚类算法matlab算法部分代码,包含主程序及画图程序(DBSCAN clustering algorithm matlab algorithm part of the code)
- 2019-02-12 17:52:50下载
- 积分:1
-
spread
Watermarking algorithms built using matlab
- 2009-03-28 19:44:18下载
- 积分:1
-
NonSin_Beamforming3
说明: 非正弦信号的波束形成程序,和利用相位的常规波束形成不同,非正弦信号的波束形成首先匹配滤波,提取包络,然后延时相加,(Non-sinusoidal signal beamforming process, and the use of conventional beam-forming phase is different from non-sinusoidal signals in the first match beamforming filtering, envelope extraction, and then add delay,)
- 2009-08-17 19:32:11下载
- 积分:1
-
M2M4-SNR-estimination
经典的二阶矩四阶矩信噪比估计,有不经过上采样、成型滤波和经过上采样、成型滤波的两种版本。加噪方式也分别用了matlab自带函数和自写两种版本。望大家参考。(Second Moment classic SNR estimation fourth moment, there is not through the sampling, the shaping filter and sampled, two versions of shaping filter. Plus noise mode were also comes with a matlab function and self-written versions. Hope you reference.)
- 2021-03-30 20:59:09下载
- 积分:1
-
biomaterialscasestudy
Several case studies for biomaterials.Included heart valves, wound dressing, dental biomaterials and joint replacement.
- 2010-11-11 14:25:20下载
- 积分:1
-
quadprog
数值计算,求解函数最优化的一个工具,是一个库函数,(Numerical calculation, to solve the function optimization of a tool, a library function,)
- 2010-01-30 10:20:25下载
- 积分:1