| JunFeng's profile人在旅途PhotosBlogLists | Help |
|
|
April 20 latex一些必读文档的下载连接LaTeX2e 使用手册 (LaTeX Manual,LaTeX 科技文献排版指南电子版): ftp://ftp.ctex.org/pub/tex/documents/bible/latex_manual.zip lshort-cn: ftp://ftp.ctex.org/pub/tex/CTDP/lshort-cn/ lshort-en: ftp://ftp.ctex.org/mirrors/CTAN/info/lshort/english/ CteX-FAQ: ftp://ftp.ctex.org/pub/tex/CTDP/ctex-faq/ LaTeX 插图指南 (epslatex) 中文版: ftp://ftp.ctex.org/pub/tex/documents/bible/latex_graphics.zip LaTeX 插图指南 (using imported graphics in latex2e) 英文版: ftp://ftp.ctex.org/mirrors/CTAN/info/epslatex.pdf TeXbook: ftp://ftp.ctex.org/pub/tex/documents/bible/texbook/ LaTeX Companion ch8 (经典书籍latex companion的第八章,详细讲解数学输入): ftp://ftp.ctex.org/pub/tex/documents/bible/LaTeX_Companion_ch8.zip short math guide: http://www.ams.org/tex/short-math-guide.html math mode: http://www.tug.org/tex-archive/info/math/voss/Voss-Mathmode.pdf latex-help-book: ftp://ftp.ctex.org/mirrors/CTAN/info/latexhelpbook/ Gnuplot: ftp://ftp.ctex.org/mirrors/CTAN/graphics/gnuplot/ 其他另外的文档或宏包,请到 http://www.ctan.org搜索,而后到对应的 ftp://ftp.ctex.org/mirror/ctan下下载即可。 April 19 创建PDF我用Adobe Acrobat 7.0专业版里创建PDF里面的一个选项:
从网页创建,然后设定了三层联结,它就自动的把所有的资源全部下载下来变成PDF格式的。 不过要注意,不能设置联结层太多了,不然的话,超级拖内存的。 February 04 矩阵函数matlab使用方法F = funm(A,fun) for a square matrix argument A, evaluates the matrix version of the function fun. For matrix exponentials, logarithms and square roots, use expm(A), logm(A) and sqrtm(A) instead. [F,esterr] = funm(A,fun) does not print any message, but returns a very rough estimate of the relative error in the computed result. If A is symmetric or Hermitian, then its Schur form is diagonal and funm is able to produce an accurate result. L = logm(A) uses funm to do its computations, but it can get more reliable error estimates by comparing expm(L) with A. S = sqrtm(A) and E = expm(A) use completely different algorithms. ExamplesExample 1. fun can be specified using @: F = funm(magic(3),@sin) is the matrix sine of the 3-by-3 magic matrix. Example 2. The statements S = funm(X,@sin); C = funm(X,@cos); produce the same results to within roundoff error as E = expm(i*X); C = real(E); S = imag(E); In either case, the results satisfy S*S+C*C = I, where I = eye(size(X)). Algorithmfunm uses a potentially unstable algorithm. If A is close to a matrix with multiple eigenvalues and poorly conditioned eigenvectors, funm may produce inaccurate results. An attempt is made to detect this situation and print a warning message. The error detector is sometimes too sensitive and a message is printed even though the the computed result is accurate. The matrix functions are evaluated using Parlett's algorithm, which is described in [1]. See Alsoexpm, logm, sqrtm, function_handle (@) References[1] Golub, G. H. and C. F. Van Loan, Matrix Computation, Johns Hopkins University Press, 1983, p. 384. [2] Moler, C. B. and C. F. Van Loan, "Nineteen Dubious Ways to Compute the Exponential of a Matrix," SIAM Review January 16 matlab在64位linux系统下出错的问题matlab7.04sp2在64位linux系统(Redhat,Federa, SuSE 9.3(64bit),Mandriva 2005 x86_64)下
安装后不能运行,会出错如下:
> *** glibc detected *** malloc(): memory corruption: 0x0000000000598840 ***
> Aborted 解决的办法有两个:
1,修改$matlab/bin/matlab文件
2,修改$matlab/bin/.matlab7rc.sh文件
其中$matlab为安装目录,通常是/usr/local/matlab。
修改的办法是在文件开始加入下面一行:
export LD_ASSUME_KERNEL=2.4.1
注意:
1,等号左右不能有空格;
2,有人建议以下两行,效果一样。
LD_ASSUME_KERNEL=2.4.1
export LD_ASSUME_KERNEL 具体原因是因为matlab和调用的TLS版本的glibc不匹配。
出错的函数为:
mmap(NULL,2101248,PROT_READ|PROT_WRITE|PROT_EXEC,
MAP_PRIVATE|MAP_ANONYMOUS|0x40,-1,0)=0x40000000
可以用以下命令看错误来源:
$strace matlab -nojvm 2>&1 | tail #
或者
$strace matlab -nojvm 2>&1 | less 可以通过以下命令察看修改前后的变化。
$lsof -n |grep [PID of matlab] | grep glibc
May 16 htaccess的密码保护1,介绍
尽管有各种各样的.htaccess用法,
但至今最流行的也可能是最有用的做法是将其用于网站目录可靠的密码保护。 尽管JavaScrip等也能做到,但只有.htaccess具有完美的安全性 (即访问者必须知晓密码才可以访问目录,并且绝无“后门”可走)。 2,密码保护的.htaccess文件
利用.htaccess将一个目录加上密码保护分两个步骤。
第一步是在你的.htaccess文档里加上适当的几行代码, 再将.htaccess文档放进你要保护的目录下: AuthName "Section Name"
AuthType Basic AuthUserFile /full/path/to/.htpasswd Require valid-user 你可能需要根据你的网站情况修改一下上述内容中的一些部分,
如用被保护部分的名字"Members Area",替换掉“Section Name”。 /full/parth/to/.htpasswd则应该替换为指向.htpasswd文件的完整服务器路径。 如果你不知道你网站空间的完整路径,请询问一下你的系统管理员。 3,密码保护的.htpasswd文件
目录的密码保护比.htaccess的其他功能要麻烦些, 因为你必须同时创建一个包含用户名和密码的文档, 用于访问你的网站,相关信息(默认)位于一个名为.htpasswd的文档里 。像.htaccess一样,.htpasswd也是一个没有文件名且具有8位扩展名的文档, 可以放置在你网站里的任何地方(此时密码应加密), 但建议你将其保存在网站Web根目录外,这样通过网络就无法访问到它了。 4,输入用户名和密码
创建好.htpasswd文档后(可以通过文字编辑器创建),
下一步是输入用于访问网站的用户名和密码,应为: username:passwordwhere
“password”的位置应该是加密过的密码。你可以通过几种方法来得到加密过的密码:
一是使用一个网上提供的permade脚本或自己写一个; 另一个很不错的username/password加密服务是通过KxS网站, 这里允许你输入用户名及密码,然后生成正确格式的密码。 对于多用户,你只需要在.htpasswd文档中新增同样格式的一行即可。 另外还有一些免费的脚本程序可以方便地管理.htpasswd文档,可以自动新增/移除用户等。 5,访问网站
当你试图访问被.htaccess密码保护的目录时, 你的浏览器会弹出标准的username/password对话窗口。 如果你不喜欢这种方式, 有些脚本程序可以允许你在页面内嵌入username/password输入框来进行认证, 你也可以在浏览器的URL框内以以下方式输入用户名和密码(未加密的): 6,小结
.htaccess是一个站点管理员可以应用的强大工具,有更多的变化以适应不同的用途,可以节约时间及提高网站的安全性。 使用htaccess的办法1, 首先要确认你的服务器或空间的服务器解译引擎为Apache2。
I, ps -aux | grep httpd
2, 打开httpd的AllowOverride服务。 I, 在目录/etc/httpd/conf/下找到文件httpd.conf;
II, 找到:#LoadModule rewrite_module modules/mod_rewrite.so 把前面的 # 给去掉; III, 找到第一个 AllowOverride None 改为 AllowOverride All。 这部分修改后的文件应该如下: # # Each directory to which Apache has access can be configured with respect # to which services and features are allowed and/or disabled in that # directory (and its subdirectories). # # First, we configure the "default" to be a very restrictive set of # features. # <Directory /> Options FollowSymLinks # AllowOverride None AllowOverride all </Directory> 3, 重新启动网页服务器httpd。
I, /etc/rc.d/init.d/httpd restart
4, 拷贝文件.htaccess和.htpasswd到需要加密的目录下面即可。
|
|
|