-
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
-
yellow
是基于的Robot Soccer v1.5a控制源码(Is based on the control of the Robot Soccer v1.5a source)
- 2008-05-19 08:40:41下载
- 积分:1
-
sinPolyfit
说明: Matlab 实现多项式曲线拟合(正弦曲线),交叉验证(十折交叉验证)(poly fit ,cross validation)
- 2010-03-27 22:57:39下载
- 积分:1
-
Jacobi-and-Gauss-Seidel
Jacobi迭代法和Gauss-Seidel迭代法求解线性方程组,matlab语言编程。(Jacobi iteration method and Gauss-Seidel iteration method for solving linear equations, using the Matlab programming language.)
- 2012-04-13 15:43:08下载
- 积分:1
-
matlab
精度颇高的转子临界转速及不平和响应算法,主要采用了传递矩阵法(High precision of the rotor critical speed and the uneven and response algorithms, mainly in the transfer matrix method)
- 2011-05-17 22:30:45下载
- 积分:1
-
Mimotools
mimo tools with matlab cod
- 2017-12-23 06:08:03下载
- 积分:1
-
相空间
说明: 这是一组matlab程序,时间序列分解,相空间重构(This is a set of MATLAB programs, time series decomposition, phase space reconstruction)
- 2020-12-14 16:19:15下载
- 积分:1
-
Solutions_manual_for_modern_signal_processing-2nd
This the solution manual for modern signal processing.
- 2008-03-22 01:47:57下载
- 积分:1
-
consensus
本程序时使用小世界模型对多个智能体寻优结果的仿真(This procedure used in small-world model of multiple-agent simulation optimization results)
- 2008-07-02 20:23:28下载
- 积分:1
-
LDPCcodes
移动通信原理中LDPC码的编码仿真程序,是通信原理中LDPC码仿真的好例子!(LDPC code)
- 2010-05-21 20:49:41下载
- 积分:1