Frage


Contour plot with function triplot
Hi all, I have a script which plots a structure: clear; clc; clf; % nodal coordinates. coord = [0 0; 1 0; 2 0; 3...

fast 7 Jahre vor | 0 Antworten | 0

0

Antworten

Frage


Efficient way of storing a triangular matrix
Hi all, I have some pretty large upper triangular matrices to store and to be used like this: <</matlabcentral/answers/upl...

fast 7 Jahre vor | 2 Antworten | 1

2

Antworten

Frage


Dynamic comments on variables?
Hi all, Is there a way to add comments to variables dynamically? For example, in my code, if I type this variable in command ...

fast 7 Jahre vor | 5 Antworten | 5

5

Antworten

Frage


Sort cell elements according to one column
Hi all, I have a cell array like this: K>> err err = 3×6 cell array [1] [ 1] [] [] [31×31 do...

fast 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Good method to store pyramid shaped cell array?
Hi all, I need to store some matrices in a cell, say I have 4 matrices: e1, e2, e3, e4, I need to compute the product of the ...

fast 7 Jahre vor | 2 Antworten | 0

2

Antworten

Frage


Cellfun not working for cells contain cells?
Hi all, I have a cell like this K>> respCol respCol = 1×24 cell array Columns 1 through 5 {3×1 cell}...

fast 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Sum over cell array of sparse matrices error: Dimension for sparse matrix concatenation must be <= 2.
Hi all, I have a cell contains sparse matrices, K>> a a = 2×1 cell array [12×12 double] [12×12 do...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


A function with 2 inputs, how to make it accept a 2-by-1 array as an input?
Hi all, There are some functions which accepts 2 inputs, such as inpolygon. For example: K>> xv xv = 1 ...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Function poly2cw not working?
Hi all, Matlab says: [x2, y2] = poly2cw(x1, y1) arranges the vertices in the polygonal contour (x1, y1) in clockwise or...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


A function smart enough to sort coordinates of block into sub-blocks?
Hi all, Imagine there is a 2D shape made of randomly distributed square blocks, with Cartesian coordinates like this: <</m...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Group 3 * 3 (2d) or 3 * 3 * 3 (3d) coordinates into square blocks?
Hi all, This question might be quite complex. Imagine there is a 3D block like this with the Cartesian coordinates: <</mat...

etwa 7 Jahre vor | 1 Antwort | 1

1

Antwort

Frage


How to combine multiple output from a function into 1?
Hi all, There are some functions in Matlab which gives multiple outputs, such as: K>> [x, y, z] = ndgrid(-1:0, -1:0, -1:...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Generate n-dimensional array: problem with 1D
Hi all, Imagine I'd like to generate random dimensional zeros matrix, I can do: K>> zeros(2, 2) ans = 0 ...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Dimensional problem in for loop.
Hi all, Imagine there is function which takes a matrix as input, perform some operations to each element, and gives an output...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to index a matrix with existing array?
Hi all, Imagine there is a m by m matrix, I'd like to extract the [p, q] element, while [p, q] is the output of some calculat...

etwa 7 Jahre vor | 2 Antworten | 1

2

Antworten

Frage


Sum over cell array of sparse matrices error: Dimension for sparse matrix concatenation must be <= 2.
Hi all, I have a cell contains sparse matrices, K>> a a = 2×1 cell array [12×12 double] [12×12 do...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to find combination of random number of vectors?
Hi all, Function combvec gives the combination of n vectors. Imagine I have a cell C contains m vectors, how can I find combi...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to change the double percent code section color?
Hi all, As we all know, %% indicates a code section in Matlab. When I put cursor on the section, the section background turns...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Is there a way to change default editor font and background color?
Hi all, My current Matlab editor is like this: <</matlabcentral/answers/uploaded_files/92454/Screenshot%20from%202017-10-2...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to remove axis from a sparsity plot with spy function?
Hello, I plot the sparsity of a matrix with spy, like this: a = rand(5, 2); spy(a) So it comes with x and y axis, ...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Beantwortet
Is it possible to find connectivity of part of a FE mesh with only nodal information?
I solved it. Create an zero array where the indices represent the nodal numbers, set the nodal numbers of inclusions to 1. ...

etwa 7 Jahre vor | 0

| akzeptiert

Frage


Is it possible to find connectivity of part of a FE mesh with only nodal information?
Hi all, Imagine there is a FE mesh with 2 inclusions: <</matlabcentral/answers/uploaded_files/89672/mesh.png>> I know th...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Structure mesh: plot different regions with different colors
Hi all, I have a 2D mesh with different regions, like this: <</matlabcentral/answers/uploaded_files/89152/CantileverBeam....

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to create readable files from Matlab to Paraview to display structural deformation?
Hello, I'm really new to Paraview, I'd like to create a plot in Paraview showing the displacement of a rectangular mesh. I u...

etwa 7 Jahre vor | 1 Antwort | 1

1

Antwort

Frage


What's the truncation error in SVD?
Hi all, I'm trying to prove one thing: perform SVD on matrix a, the truncation error of singular values equals to truncation...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


How to ensure text on plot always in front?
Hi all, I plot some surfaces and label some points on the surface with it's value of z-axis, as shown on the figure. You can ...

etwa 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Multidimensional array: how to extract several dimensions at same time?
Hi all, Imagine there is a 4d array like this: arrayA = rand(5, 4, 3, 2); Now I need a new arrayB which contains all ...

mehr als 7 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Make Lagrange interpolation function faster?
Hi all, I coded a Lagrange interpolation function for matrices, and calls it in my main program. only 4 points linear interpo...

mehr als 8 Jahre vor | 0 Antworten | 0

0

Antworten

Frage


How to determine blocks in mesh grid?
Hello guys, I have a matrix representing a grid, say A = [-1 -1; -1 1; 1 -1; 1 1; -1 0; 0 -1; 0 0; 0 1; 1 0]; Every ...

mehr als 8 Jahre vor | 1 Antwort | 0

1

Antwort

Frage


Is there a rectangular domain decomposition function in MATLAB?
Hello guys, Is there a rectangular domain decomposition function in MATLAB? For example, decompose a rectangular domain into ...

mehr als 8 Jahre vor | 0 Antworten | 0

0

Antworten

Mehr laden