Display Posts Shortcode

The Display Posts Shortcode allows you to fine-tune the posts you wish to display on a page.

Add the shortcode 

 in a post or page, and use the arguments to query based on tag, category, post type, and many other possibilities.

New posts will be displayed within one hour of publishing.

Examples

This will list the 20 most recent posts with the tag ‘Advanced’.

This will list the 10 most recent posts tagged ‘Advanced’ and display a post image using the ‘Thumbnail’ size.

This will list every post in the Must Read category, in alphabetical order, with the date appended to the end.

  1. ODE:could not open stdin/stderr
  2. Linearizing Systems of First Order Nonlinear Differential Equations
  3. Matlab: file name and path
  4. config4cpp Invalid escape sequence %
  5. Matlab Function handle
  6. Matlab GPU Computing
  7. Matlab: arrayfun
  8. Reshape to vertically tile blocks of columns below previous ones
  9. beyond compare show line numbers
  10. Matlab eject dvd1 and insert DVD 2 to continue

This will display posts as an ordered list. Options are ul for unordered lists (default), ol for ordered lists, or div for divs.

This will display only the posts with an ID of 14 and 3.

↑ Table of Contents ↑

↑ Table of Contents ↑

Arguments

author
Specify the post author
Default: empty
Example:

category
Specify the category slug (or comma separated list of category slugs)
Default: empty
Example:

date_format
Specify the date format used when include_date is true. See Formatting Date and Time on the Codex for more information.
Default: ‘(n/j/Y)’
Example:

id
Specify a specific post ID (or multiple post IDs) to display.
Default: empty
Example:

image_size
Specify an image size for displaying the featured image, if the post has one. The image_size can be set to thumbnail, medium, large (all controlled from Settings > Media).
Default: empty
Example:

include_content
Include the full post content after the title.
Default: empty
Example:

  • ODE:could not open stdin/stderr
     I noticed somebody had posted a problem about receiving the error 
    > message "could not open stdin" when using ode with cygwin.  The 
    > solution that worked for me was to edit the file 
    > drawStuff/src/windows.cpp.  The line that produces the error message 
    > is in that file, and enclosed in a block surrounded by an #ifndef 
    > cygwin.  I just manually commented out the lines in this block, and it 
    > now works fine.

    // redirect standard I/O to a new console (except on cygwin and mingw)
    #if !defined(__CYGWIN__) && !defined(__MINGW32__)
    //FreeConsole();
    //if (AllocConsole()==0) dsError (“AllocConsole() failed”);
    //if (freopen (“CONIN$”,”rt”,stdin)==0) dsError (“could not open stdin”);
    //if (freopen (“CONOUT$”,”wt”,stdout)==0) dsError (“could not open stdout”);
    //if (freopen (“CONOUT$”,”wt”,stderr)==0) dsError (“could not open stderr”);
    //BringWindowToTop (GetConsoleHwnd());
    //SetConsoleTitle (“DrawStuff Messages”);
    #endif

     


    http://www.ode.org/old_list_archives/2006-September/020469.html

  • Linearizing Systems of First Order Nonlinear Differential Equations

     

    math.harvard.edu/~elkie

    cds.caltech.edu/~murray

    一维函数 y = f(x)x=a 处的一阶近似为:

    f(x) \approx \frac{df}{dx}\arrowvert_{x=x_0}(x-a)

    我们说这是函数 f(x) 在点 x=x_0 附近的线性化。

    二元函数比如 y=f(x_1,x_2) ,有多元函数在点 (a,b) 附近的线性化:

    f(x_1,x_2)\approx f(a,b)+\frac{\partial f}{\partial x}\arrowvert_{x_1=a,x_2=b}(x_1-a) + \frac{\partial f}{\partial y}\arrowvert_{x_1=a,x_2=b}(x_2-b)

    二阶非线性系统由两个二元函数构成:

    \begin{cases}\dot{x}_1=f_1(x_1,x_2)\\\dot{x}_2=f_2(x_1,x_2)\end{cases}

    如果要在 (a,b) 处线性化当然只能分别线性化

    \begin{cases}\dot{x}_1\approx f_1(a,b)+\frac{\partial f_1}{\partial x}\arrowvert_{x_1=a,x_2=b}(x_1-a) + \frac{\partial f_1}{\partial y}\arrowvert_{x_1=a,x_2=b}(x_2-b)\\\dot{x}_2\approx f_2(a,b)+\frac{\partial f_2}{\partial x}\arrowvert_{x_1=a,x_2=b}(x_1-a) + \frac{\partial f_2}{\partial y}\arrowvert_{x_1=a,x_2=b}(x_2-b)\end{cases}

    然后一般来说 (a,b) 都取工作点(平衡点),即 f_1(a,b)=f_2(a,b)=0

    那么写成矩阵形式

    \left[\begin{matrix}\dot{x}_1\\\dot{x}_2\end{matrix}\right]\approx\left[\begin{matrix}\frac{\partial f_1}{\partial x_1}&\frac{\partial f_1}{\partial x_2}\\\frac{\partial f_2}{\partial x_1}&\frac{\partial f_2}{\partial x_2}\end{matrix}\right]_{\arrowvert x_1=a,x_2=b}\left[\begin{matrix}x_1-a\\x_2-b\end{matrix}\right]

    中间那货2*2的就叫雅克比矩阵,嗯


    作者:肖畅
    链接:https://www.zhihu.com/question/62144735/answer/195145638
    来源:知乎

  • Matlab: file name and path

    [pathstr,name,ext] = fileparts(filename)

    [pathstr,name,ext] = fileparts(‘D:/igl/gptoolbox/wrappers/test.node’)

    pathstr =

    ‘D:/igl/gptoolbox/wrappers’

     

    name =

    ‘test’

     

    ext =

    ‘.node’

  • config4cpp Invalid escape sequence %

    deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%06d.obj”;

    Solution:

    use doulbe %%

    deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%%06d.obj”;

  • Matlab Function handle

    新建M文件f1.m

    function y=f1(X)

    x1=X(1);x2=X(2);
    y=x1^2+x1*x2;

    新建M文件ftest.m

    function Y=ftest(f,X)

    syms x1 x2;
    F=f([x1,x2]);
    v=[x1,x2];
    grad=jacobian(F,v);
    Y=subs(grad,v,X);

    在MATLAB命令窗口输入Y=ftest(@f1,[2,1]),得到结果:

    Y =

         5     2

    此处@f1即为函数f1的句柄,可以用class(@f1)判断变量的类型,得到ans = function_handle即函数句柄。函数ftest是求一个二维函数在指定点的梯度值。我们可以替换目标函数为f2或其他函数同样可以求得梯度。这样函数ftest就可以适用于任何二维函数而不必做改动了。

    ==================================

    帮助文档中指出有四种方法用于构建函数句柄

    ——对已命名函数构建句柄

    1)fh = @functionName;
    2)fh = str2func(‘functionName’);

    ——对匿名函数构建句柄

    3)fh = @(x)functionDef(x);
    4)fh = str2func(‘@(x)functionDef(x)’);

     

    定义匿名函数的标准格式如下:

    fhandle=@(arglist)express
    (1)express是一个matlab变量表达式,比如:x+x.^2,sin(x)等
    (2)argilst是参数列表;
    (3)符号@是matlab创建函数句柄的操作符,表示创建有输入参数列表arglist和表达式express确定的函数句柄,并把这个函数句柄返回给变量fhandle,这样,以后就可以通过fhandle来调用定义好的函数了。

    小例子:

    sum_square = @(x)(x^2+3);

    a = sum_square(8);

     

    sum_square2 = @(x,y)(x^2+y^3+3);

    a2 = sum_square2(2,3);

    运行后:a=67; a2=34

    fh=@sin;

    a3=feval_r(fh,pi/2);

    运行后:a3=1

    使用函数句柄的好处:

    1、提高运行速度。因为matlab对函数的调用每次都是要搜索所有的路径,从set path中我们可以看到,路径是非常的多的,所以如果一个函数在你的程序中需要经常用到的话,使用函数句柄,对你的速度会有提高的。
    2、使用可以与变量一样方便。比如说,在这个目录运行后,创建了本目录的一个函数句柄,当转到其他的目录下的时候,创建的函数句柄还是可以直接调用的,而不需要把那个函数文件拷贝过来。因为你创建的function handles中,已经包含了路径,用functions来查看这个function,已经包括了路径。

    >> functions(sum_square)
    ans = 
        function: ‘@(x)(x^2+3)’
            type: ‘anonymous’
            file: ”
       workspace: {[1×1 struct]}


    http://blog.sina.com.cn/s/blog_531bb763010196q2.html

  • Matlab GPU Computing

    gpuArray Example

  • Matlab: arrayfun

    利用arrayfun函数可以避免无谓的循环,从而大大提高代码的简介性。
    1、A=ARRAYFUN(FUN, B)
    FUN是函数句柄,对B中的每一个元素调用FUN函数(计算顺序随意),结果存放于A中,size(A)==size(B)
    FUN函数可接受numeric, logical, char, struct, cell的自变量类型。
    2、[A, B, …] = ARRAYFUN(FUN, C, …)
    FUN函数的返回值是一个向量,对B中的每一个元素调用FUN函数,计算结果放在A,B…中。
    3、 A = ARRAYFUN(FUN, B, C,  …)
    FUN函数接受参数不唯一,分别调用B, C,  …中的元素,A(i,j…)=Fun(B(i,j…),C(i,j,…)…),
    B,C…大小必须相等。
    例1、Fun调用B中的一个数值
    >> s=[1 2;3 4];
    >> f=@(x) x^2;
    >> arrayfun(f,s)
    ans =
    1     4
    9    16

    例2、Fun的接受参数是一个向量
    >> ss=num2cell(s,2);
    >> f=@(x) sum(x{:}.^2);
    >> arrayfun(f,ss)
    ans =
    5
    25

    例3、Fun函数返回值是向量
    >> F=@(x) x{:}.^2;
    >> cell2mat(arrayfun(F,ss,’UniformOutput’,false))
    ans =
    1     4
    9    16

    例4、Fun函数参数不唯一
    >> f=@(x,y) x^2+y^2;
    >> [X,Y]=meshgrid(-2:2,-1:5);
    >> Z=arrayfun(f,X,Y);
    >> mesh(X,Y,Z)

    例5、Fun函数的参数不唯一,而且都是向量
    >> F=@(f,h)sum(diff(f{:}).^2)+sum(diff(h{:}).^2);
    >> f=[1,2,3;3,4,5;1,2,5];
    >> h=[2,4;4,5;];
    >> ff=num2cell(f,2);
    >> hh=num2cell(h,2);
    >> fff=repmat(ff’,length(hh),1);
    >> hhh=repmat(hh,1,length(ff));
    >> arrayfun(F,fff,hhh)
    ans =
    6     6    14
    3     3    11

    C2=num2cell(A)是把A中的每一个元素作为cell的元素,这样每个元素是一个数;C2=num2cell(A,1)是把矩阵A的每一列作为cell的元素,这样cell的每个元素是一个列向量。同样的还有C2=num2cell(A,2)表示把A中的每一行作为一个cell元素


    http://blog.sina.com.cn/s/blog_7cf4f4460101bnhh.html

  • Reshape to vertically tile blocks of columns below previous ones

    This will become clearer with this example:

    A = reshape(1:12, 3, []) % A is the matrix I start with, this reshape is OK
    A =
    
        1    4    7   10
        2    5    8   11
        3    6    9   12
    
    reshape(A, [], 2) % this reshape is not OK
    ans =
    
        1    7
        2    8
        3    9
        4   10
        5   11
        6   12

    However, I would like the answer to be:

    ans =
    
        1    4
        2    5
        3    6
        7   10
        8   11
        9   12

     

    Assuming M to be the input matrix, see if this works for you –

    ncols = 2; %// number of columns (needs to be edited)
    [m,n] = size(M) %// get size of input matrix for later usage
    r = numel(M)/(m*ncols);
    out = reshape(permute(reshape(M,m,ncols,[]),[1 3 2]),m*r,[])

    Sample runs –

    M =
         1     4     7    10
         2     5     8    11
         3     6     9    12
    ncols =
         2
    out =
         1     4
         2     5
         3     6
         7    10
         8    11
         9    12

    and

    M =
         1     4     7    10    13    16
         2     5     8    11    14    17
         3     6     9    12    15    18
    ncols =
         3
    out =
         1     4     7
         2     5     8
         3     6     9
        10    13    16
        11    14    17
        12    15    18

     


    https://stackoverflow.com/a/26917451/4862158

  • beyond compare show line numbers

    Checked a default install of BC 3.3.4, View > Line Numbers is available by default.

    To make it visible on your install of Beyond Compare, select “Tools > Customize Commands”. Select “Line Numbers” and check “Show command in menu”.


    https://www.scootersoftware.com/vbulletin/showthread.php?8566-Show-Line-Numbers-Missing

  • Matlab eject dvd1 and insert DVD 2 to continue

    Solution 1

    When you see that info, you should eject the DVD1 and load the DVD2.what’s more, you should make sure that the letter you load is same as the last time.

    Solution 2

    Mount DVD1 and copy contents to a folder. Notice the .dvd1 at the root of the extracted contents. Mount DVD2 and copy contents to the same locations in in the newly created folder. Notice the .dvd2. You’ll need that .dvd2 to be at the same location (root) as .dvd1. Now you’re ready to deploy. – Configure installer_input.txt – create a .bat script: “%~dp0bin\win64\setup.exe” -inputFile “%~dp0installer_input.txt” The reason I did not call the first setup.exe at the root of the extracted contents is because that setup.exe will call .\bin\win64\setup.exe and exit.


    https://fr.mathworks.com/matlabcentral/answers/305627-2016b-how-to-install-both-dvds-silently#comment_398232

     

     

include_date
Include the post’s date after the post title. The default format is (7/30/12), but this can be customized using the ‘date_format’ parameter.
Default: empty
Example

include_excerpt
Include the post’s excerpt after the title (and date if provided).
Default: empty
Example:

  • ODE:could not open stdin/stderr - I noticed somebody had posted a problem about receiving the error > message "could not open stdin" when using ode with cygwin. The > solution that worked for me was to edit the file > drawStuff/src/windows.cpp. The line that produces the error message > is in that file, and enclosed in a block surrounded by […]
  • Linearizing Systems of First Order Nonlinear Differential Equations -   http://www.math.harvard.edu/~elkies/M21b.06/notes1.pdf http://www.cds.caltech.edu/~murray/courses/cds101/fa02/caltech/pph02-ch19-23.pdf 一维函数 在 处的一阶近似为: 我们说这是函数 在点 附近的线性化。 二元函数比如 ,有多元函数在点 附近的线性化: 二阶非线性系统由两个二元函数构成: 如果要在 处线性化当然只能分别线性化 然后一般来说 都取工作点(平衡点),即 那么写成矩阵形式 中间那货2*2的就叫雅克比矩阵,嗯 作者:肖畅 链接:https://www.zhihu.com/question/62144735/answer/195145638 来源:知乎
  • Matlab: file name and path - [pathstr,name,ext] = fileparts(filename) [pathstr,name,ext] = fileparts(‘D:/igl/gptoolbox/wrappers/test.node’) pathstr = ‘D:/igl/gptoolbox/wrappers’   name = ‘test’   ext = ‘.node’
  • config4cpp Invalid escape sequence % - deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%06d.obj”; Solution: use doulbe %% deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%%06d.obj”;
  • Matlab Function handle - 新建M文件f1.m function y=f1(X) x1=X(1);x2=X(2); y=x1^2+x1*x2; 新建M文件ftest.m function Y=ftest(f,X) syms x1 x2; F=f([x1,x2]); v=[x1,x2]; grad=jacobian(F,v); Y=subs(grad,v,X); 在MATLAB命令窗口输入Y=ftest(@f1,[2,1]),得到结果: Y =      5     2 此处@f1即为函数f1的句柄,可以用class(@f1)判断变量的类型,得到ans = function_handle即函数句柄。函数ftest是求一个二维函数在指定点的梯度值。我们可以替换目标函数为f2或其他函数同样可以求得梯度。这样函数ftest就可以适用于任何二维函数而不必做改动了。 ================================== 帮助文档中指出有四种方法用于构建函数句柄 ——对已命名函数构建句柄 1)fh = @functionName; 2)fh = str2func(‘functionName’); ——对匿名函数构建句柄 3)fh = @(x)functionDef(x); 4)fh = str2func(‘@(x)functionDef(x)’);   定义匿名函数的标准格式如下: fhandle=@(arglist)express (1)express是一个matlab变量表达式,比如:x+x.^2,sin(x)等 (2)argilst是参数列表; (3)符号@是matlab创建函数句柄的操作符,表示创建有输入参数列表arglist和表达式express确定的函数句柄,并把这个函数句柄返回给变量fhandle,这样,以后就可以通过fhandle来调用定义好的函数了。 小例子: sum_square = @(x)(x^2+3); a = sum_square(8);   sum_square2 = @(x,y)(x^2+y^3+3); a2 […]
  • Matlab GPU Computing - gpuArray Example
  • Matlab: arrayfun - 利用arrayfun函数可以避免无谓的循环,从而大大提高代码的简介性。 1、A=ARRAYFUN(FUN, B) FUN是函数句柄,对B中的每一个元素调用FUN函数(计算顺序随意),结果存放于A中,size(A)==size(B) FUN函数可接受numeric, logical, char, struct, cell的自变量类型。 2、[A, B, …] = ARRAYFUN(FUN, C, …) FUN函数的返回值是一个向量,对B中的每一个元素调用FUN函数,计算结果放在A,B…中。 3、 A = ARRAYFUN(FUN, B, C,  …) FUN函数接受参数不唯一,分别调用B, C,  …中的元素,A(i,j…)=Fun(B(i,j…),C(i,j,…)…), B,C…大小必须相等。 例1、Fun调用B中的一个数值 >> s=[1 2;3 4]; >> f=@(x) x^2; >> arrayfun(f,s) ans = 1     4 9    16 例2、Fun的接受参数是一个向量 >> ss=num2cell(s,2); >> f=@(x) sum(x{:}.^2); >> arrayfun(f,ss) ans = 5 25 例3、Fun函数返回值是向量 >> F=@(x) […]
  • Reshape to vertically tile blocks of columns below previous ones - This will become clearer with this example: A = reshape(1:12, 3, []) % A is the matrix I start with, this reshape is OK A = 1 4 7 10 2 5 8 11 3 6 9 12 reshape(A, [], 2) % this reshape is not OK ans = 1 7 2 8 3 9 […]
  • beyond compare show line numbers - Checked a default install of BC 3.3.4, View > Line Numbers is available by default. To make it visible on your install of Beyond Compare, select “Tools > Customize Commands”. Select “Line Numbers” and check “Show command in menu”. https://www.scootersoftware.com/vbulletin/showthread.php?8566-Show-Line-Numbers-Missing
  • Matlab eject dvd1 and insert DVD 2 to continue - Solution 1 When you see that info, you should eject the DVD1 and load the DVD2.what’s more, you should make sure that the letter you load is same as the last time. Solution 2 Mount DVD1 and copy contents to a folder. Notice the .dvd1 at the root of the extracted contents. Mount DVD2 and […]

offset
The number of posts to pass over
Default: 0
Example:

order
Specify whether posts are ordered in descending order (DESC) or ascending order (ASC).
Default: DESC
Example:

orderby
Specify what the posts are ordered by. See the available parameters here.
Default: date
Example:

portfolio_type
If you are using the Portfolio post type, use this to get items from a specific portfolio type.

post_parent
Display the pages that are a child of a certain page. You can either specify an ID or ‘current’, which displays the children of the current page.
Default: empty
Example:

post_status
Show posts associated with a certain post status
Default: publish
Example:

post_type
Specify which post type to use. You can use a default one (post or page). For Portfolios use “jetpack-portfolio”.  Similarly, for Testimonials use “jetpack-testimonial”.
Default: post
Example:

posts_per_page
How many posts to display.
Default: 10
Example:

tag
Specify the tag slug (or comma separated list of tag slugs)
Default: empty
Example:

taxonomy, tax_term, and tax_operator
Use these parameters to do advanced taxonomy queries. Use ‘taxonomy’ for the taxonomy you’d like to query, ‘tax_term’ for the term slug (or terms) you’d like to include, and ‘operator’ to change how the query uses those terms (most likely this field will not be needed).
Default: ‘taxonomy’ = empty , ‘tax_term’ = empty , ‘tax_operator’ = ‘IN’
Example:

wrapper
What type of HTML should be used to display the listings. It can be an unordered list (ul), ordered list (ol), or divs (div) which you can then style yourself.
Default: ul
Example:

  1. ODE:could not open stdin/stderr
  2. Linearizing Systems of First Order Nonlinear Differential Equations
  3. Matlab: file name and path
  4. config4cpp Invalid escape sequence %
  5. Matlab Function handle
  6. Matlab GPU Computing
  7. Matlab: arrayfun
  8. Reshape to vertically tile blocks of columns below previous ones
  9. beyond compare show line numbers
  10. Matlab eject dvd1 and insert DVD 2 to continue

↑ Table of Contents ↑

Multiple Taxonomy Queries

While most people will only ever need a single taxonomy query, this shortcode supports an infinite number of taxonomy queries. Let’s say you wanted to get all posts in category “featured” and also tagged “homepage”. We’ll use a shortcode that looks like this:

You can string as many of those as you like, just start the count at 2. In the field listing below, replace (count) with an actual number.

Here’s the available fields:

taxonomy_(count)
Which taxonomy to query
Default: empty

tax_(count)_term
Which terms to include (if more than one, separate with commas)
Default: empty

tax_(count)_operator
How to query the terms (IN, NOT IN, or AND)
Default: IN

tax_relation
Describe the relationship between the multiple taxonomy queries (should the results match all the queries or just one of them). Available options: AND and OR
Default: AND

↑ Table of Contents ↑

Image Alignment

A common request is display a list of posts with title, excerpt, and the thumbnail aligned to the right. Here’s the shortcode you might use:

ODE:could not open stdin/stderr - I noticed somebody had posted a problem about receiving the error > message "could not open stdin" when using ode with cygwin. The > solution that worked for me was to edit the file > drawStuff/src/windows.cpp. The line that produces the error message > is in that file, and enclosed in a block surrounded by […]
Linearizing Systems of First Order Nonlinear Differential Equations -   http://www.math.harvard.edu/~elkies/M21b.06/notes1.pdf http://www.cds.caltech.edu/~murray/courses/cds101/fa02/caltech/pph02-ch19-23.pdf 一维函数 在 处的一阶近似为: 我们说这是函数 在点 附近的线性化。 二元函数比如 ,有多元函数在点 附近的线性化: 二阶非线性系统由两个二元函数构成: 如果要在 处线性化当然只能分别线性化 然后一般来说 都取工作点(平衡点),即 那么写成矩阵形式 中间那货2*2的就叫雅克比矩阵,嗯 作者:肖畅 链接:https://www.zhihu.com/question/62144735/answer/195145638 来源:知乎
Matlab: file name and path - [pathstr,name,ext] = fileparts(filename) [pathstr,name,ext] = fileparts(‘D:/igl/gptoolbox/wrappers/test.node’) pathstr = ‘D:/igl/gptoolbox/wrappers’   name = ‘test’   ext = ‘.node’
config4cpp Invalid escape sequence % - deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%06d.obj”; Solution: use doulbe %% deformed_src_mesh = “cmu/02-05-bvh-obj/obj/asian_man_%%06d.obj”;
Matlab Function handle - 新建M文件f1.m function y=f1(X) x1=X(1);x2=X(2); y=x1^2+x1*x2; 新建M文件ftest.m function Y=ftest(f,X) syms x1 x2; F=f([x1,x2]); v=[x1,x2]; grad=jacobian(F,v); Y=subs(grad,v,X); 在MATLAB命令窗口输入Y=ftest(@f1,[2,1]),得到结果: Y =      5     2 此处@f1即为函数f1的句柄,可以用class(@f1)判断变量的类型,得到ans = function_handle即函数句柄。函数ftest是求一个二维函数在指定点的梯度值。我们可以替换目标函数为f2或其他函数同样可以求得梯度。这样函数ftest就可以适用于任何二维函数而不必做改动了。 ================================== 帮助文档中指出有四种方法用于构建函数句柄 ——对已命名函数构建句柄 1)fh = @functionName; 2)fh = str2func(‘functionName’); ——对匿名函数构建句柄 3)fh = @(x)functionDef(x); 4)fh = str2func(‘@(x)functionDef(x)’);   定义匿名函数的标准格式如下: fhandle=@(arglist)express (1)express是一个matlab变量表达式,比如:x+x.^2,sin(x)等 (2)argilst是参数列表; (3)符号@是matlab创建函数句柄的操作符,表示创建有输入参数列表arglist和表达式express确定的函数句柄,并把这个函数句柄返回给变量fhandle,这样,以后就可以通过fhandle来调用定义好的函数了。 小例子: sum_square = @(x)(x^2+3); a = sum_square(8);   sum_square2 = @(x,y)(x^2+y^3+3); a2 […]
Matlab GPU Computing - gpuArray Example
Matlab: arrayfun - 利用arrayfun函数可以避免无谓的循环,从而大大提高代码的简介性。 1、A=ARRAYFUN(FUN, B) FUN是函数句柄,对B中的每一个元素调用FUN函数(计算顺序随意),结果存放于A中,size(A)==size(B) FUN函数可接受numeric, logical, char, struct, cell的自变量类型。 2、[A, B, …] = ARRAYFUN(FUN, C, …) FUN函数的返回值是一个向量,对B中的每一个元素调用FUN函数,计算结果放在A,B…中。 3、 A = ARRAYFUN(FUN, B, C,  …) FUN函数接受参数不唯一,分别调用B, C,  …中的元素,A(i,j…)=Fun(B(i,j…),C(i,j,…)…), B,C…大小必须相等。 例1、Fun调用B中的一个数值 >> s=[1 2;3 4]; >> f=@(x) x^2; >> arrayfun(f,s) ans = 1     4 9    16 例2、Fun的接受参数是一个向量 >> ss=num2cell(s,2); >> f=@(x) sum(x{:}.^2); >> arrayfun(f,ss) ans = 5 25 例3、Fun函数返回值是向量 >> F=@(x) […]
Reshape to vertically tile blocks of columns below previous ones - This will become clearer with this example: A = reshape(1:12, 3, []) % A is the matrix I start with, this reshape is OK A = 1 4 7 10 2 5 8 11 3 6 9 12 reshape(A, [], 2) % this reshape is not OK ans = 1 7 2 8 3 9 […]
beyond compare show line numbers - Checked a default install of BC 3.3.4, View > Line Numbers is available by default. To make it visible on your install of Beyond Compare, select “Tools > Customize Commands”. Select “Line Numbers” and check “Show command in menu”. https://www.scootersoftware.com/vbulletin/showthread.php?8566-Show-Line-Numbers-Missing
Matlab eject dvd1 and insert DVD 2 to continue - Solution 1 When you see that info, you should eject the DVD1 and load the DVD2.what’s more, you should make sure that the letter you load is same as the last time. Solution 2 Mount DVD1 and copy contents to a folder. Notice the .dvd1 at the root of the extracted contents. Mount DVD2 and […]

This includes the excerpt, adds an image of the “thumbnail” size (you can customize the image sizes in Settings > Media), and tells it to present the list without bullets.

In order to get the image floating to the right, add this to your custom CSS file (requires theWordPress.com Premium or WordPress.com Business upgrade):

.display-posts-listing .alignleft {
    float: right;
    margin: 0 0 5px 5px;
}

↑ Table of Contents ↑

Limits

The Display Posts Shortcode has a limit of 100 posts displayed.


https://en.support.wordpress.com/display-posts-shortcode/

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s