Feeds
回答済み
How does the mod function compensate for floating point round off?
Answering my own question. I wrapped the mod function and generated c code. if the quotient is within eps * quotient of bieing...
How does the mod function compensate for floating point round off?
Answering my own question. I wrapped the mod function and generated c code. if the quotient is within eps * quotient of bieing...
2年弱 前 | 0
| 採用済み
質問
How does the mod function compensate for floating point round off?
The documentation for the mod function states, "mod attempts to compensate for floating-point round-off effects to produce exact...
2年弱 前 | 4 件の回答 | 2
4
回答質問
Simulink Protected Model and coder.cevel()
I'm trying to create a protected model from a Simulink model contained embedded matlab functions using coder.ceval() to pull in ...
2年以上 前 | 1 件の回答 | 0
1
回答回答済み
how to plot all the results of for loop in one figure on same axis?
Just move the figure(); command to before the for loop.
how to plot all the results of for loop in one figure on same axis?
Just move the figure(); command to before the for loop.
5年弱 前 | 0
回答済み
How to flip my image
The are a few problems with your code. First, if you want the image, you dont want to transpose. That will flip and rotate, As...
How to flip my image
The are a few problems with your code. First, if you want the image, you dont want to transpose. That will flip and rotate, As...
約5年 前 | 1
| 採用済み
回答済み
How to split an array into smaller unequal-sized arrays dependend on array-column values
Histcounts can be used to pin the data the way you want. [~,~,BIN] = histcounts(mainArray(:,1), 0:10:500) subArray1 = mainArr...
How to split an array into smaller unequal-sized arrays dependend on array-column values
Histcounts can be used to pin the data the way you want. [~,~,BIN] = histcounts(mainArray(:,1), 0:10:500) subArray1 = mainArr...
約5年 前 | 0
| 採用済み
回答済み
if statement inside for loop location issues
This is exactly the situation where you want to use logical indexing. https://blogs.mathworks.com/loren/2013/02/20/logical-inde...
if statement inside for loop location issues
This is exactly the situation where you want to use logical indexing. https://blogs.mathworks.com/loren/2013/02/20/logical-inde...
約5年 前 | 0
| 採用済み
回答済み
Plotting orientation in 3-D plot using quaternion
Check out this link which explains the quaternion mah required. https://gamedev.stackexchange.com/questions/28395/rotating-vect...
Plotting orientation in 3-D plot using quaternion
Check out this link which explains the quaternion mah required. https://gamedev.stackexchange.com/questions/28395/rotating-vect...
約5年 前 | 0
回答済み
How can i read multiple values in a string?
I believe a regular expression along these lines is what you are looking for. data = regexp('1º:" H:2T:16799C:7| H:2T:16803C:15...
How can i read multiple values in a string?
I believe a regular expression along these lines is what you are looking for. data = regexp('1º:" H:2T:16799C:7| H:2T:16803C:15...
約5年 前 | 0
| 採用済み
回答済み
Surface fitting for 3D point cloud acquired by photogrammetry
Take a look at griddata and scatteredInterpolant griddata Interpolates scattered data - generally to produce gridded data Vq =...
Surface fitting for 3D point cloud acquired by photogrammetry
Take a look at griddata and scatteredInterpolant griddata Interpolates scattered data - generally to produce gridded data Vq =...
約5年 前 | 2
回答済み
Can this be written in a much better way for fast computations?
The code below will do what you are asking without needing a loop. coast=magic(14400); di_max=100; mx=14400; my=14400; [i...
Can this be written in a much better way for fast computations?
The code below will do what you are asking without needing a loop. coast=magic(14400); di_max=100; mx=14400; my=14400; [i...
約5年 前 | 1
| 採用済み
回答済み
How to assign numbers
Something like this? table = randi([0 10],10,10); tableMax = max(max(table)); table(table==0) = tableMax+1; % Or Just table...
How to assign numbers
Something like this? table = randi([0 10],10,10); tableMax = max(max(table)); table(table==0) = tableMax+1; % Or Just table...
約5年 前 | 0
回答済み
How can i do object oriented programming in Simulink?
It sounds like a simple masked subsystem may suit your needs. Its not object oriented programming but you can use it to define ...
How can i do object oriented programming in Simulink?
It sounds like a simple masked subsystem may suit your needs. Its not object oriented programming but you can use it to define ...
約5年 前 | 0
回答済み
How could I extract the first two columns, and leave the next two and then so on from a matrix
% Set up example data set A = eye(100); A(1,:) = 1:100; numCols = size(A,2); % Answer B = A(:,sort([1:4:numCols 2:4:numCo...
How could I extract the first two columns, and leave the next two and then so on from a matrix
% Set up example data set A = eye(100); A(1,:) = 1:100; numCols = size(A,2); % Answer B = A(:,sort([1:4:numCols 2:4:numCo...
約5年 前 | 0
| 採用済み
回答済み
A simple matrix question
A = [1 2 3 4 5]; B = fliplr(A) % Flip matrix in left/right direction A = [1; 2; 3; 4; 5]; B = flipud(A) ...
A simple matrix question
A = [1 2 3 4 5]; B = fliplr(A) % Flip matrix in left/right direction A = [1; 2; 3; 4; 5]; B = flipud(A) ...
約5年 前 | 0
| 採用済み
回答済み
how can i convert the ip address into decimal
ipFields = uint8(str2double(split('192.192.192.2', '.')))'; typecast(fliplr(ipFields), 'uint32') % Explanation dec2hex(192)...
how can i convert the ip address into decimal
ipFields = uint8(str2double(split('192.192.192.2', '.')))'; typecast(fliplr(ipFields), 'uint32') % Explanation dec2hex(192)...
約5年 前 | 1
回答済み
unique set from file
c = {'!' 'a:' 'l' 't' '@' [] [] '?' 'a:' 'l' 't' '@' 's' 't' '/' 'a' 'b' 'a' 'n' 'd' 'A~'}; for rowIdx = 1:size(c,1) ...
unique set from file
c = {'!' 'a:' 'l' 't' '@' [] [] '?' 'a:' 'l' 't' '@' 's' 't' '/' 'a' 'b' 'a' 'n' 'd' 'A~'}; for rowIdx = 1:size(c,1) ...
約5年 前 | 0
回答済み
How to divide a structure into sub-structures based on a condition
I think this is what you are looking for. You will end up with two struture arrays both smaller than the original structure arr...
How to divide a structure into sub-structures based on a condition
I think this is what you are looking for. You will end up with two struture arrays both smaller than the original structure arr...
約5年 前 | 0
回答済み
What are the toolboxes on my license
Just type "ver" to find out what toolboxes you have ver This question has a pretty thorough description of product activation ...
What are the toolboxes on my license
Just type "ver" to find out what toolboxes you have ver This question has a pretty thorough description of product activation ...
約5年 前 | 0
回答済み
Issue with loading datetime from table
There appears to be two issues with your code. The first is that datetime doesn't take a cell array of numbers so you need to c...
Issue with loading datetime from table
There appears to be two issues with your code. The first is that datetime doesn't take a cell array of numbers so you need to c...
約5年 前 | 0
回答済み
How do I apply unique names to structs created in a for loop?
Does this help at all? I'm not completely sure I understand the nuances of your question, but If I had a folder structure like ...
How do I apply unique names to structs created in a for loop?
Does this help at all? I'm not completely sure I understand the nuances of your question, but If I had a folder structure like ...
約5年 前 | 0
回答済み
Finding a max in a column and making all other elements equal to zero
a= [ 1 3 3; 3 1 2; 2 1 1 ] numRows = size(a,1); maxvals = max(a) a(a~=repmat(max(a),numRows,1)) = 0 numNonZeroInCol = sum(...
Finding a max in a column and making all other elements equal to zero
a= [ 1 3 3; 3 1 2; 2 1 1 ] numRows = size(a,1); maxvals = max(a) a(a~=repmat(max(a),numRows,1)) = 0 numNonZeroInCol = sum(...
約5年 前 | 0
| 採用済み
回答済み
Undefined function or variable 'gurobi_write'. in MATLAB R2019a?
I don't know anything about Gurobi, but I do know that in the past, some programs that tie into Matlab need to be installed afte...
Undefined function or variable 'gurobi_write'. in MATLAB R2019a?
I don't know anything about Gurobi, but I do know that in the past, some programs that tie into Matlab need to be installed afte...
約5年 前 | 2
| 採用済み
回答済み
How to select images from nested folder?
Something like this should work. You will possibly need to add code to appropriately sort your list of images. I've marked whe...
How to select images from nested folder?
Something like this should work. You will possibly need to add code to appropriately sort your list of images. I've marked whe...
約5年 前 | 2
| 採用済み
回答済み
How do I add an additional column to a cell array based on existing values in another column?
Obviously replace myCellArray with whatever your array is called. isTwo = cellfun(@(x) x == 2, myCellArray(:,2)); myCellArray(...
How do I add an additional column to a cell array based on existing values in another column?
Obviously replace myCellArray with whatever your array is called. isTwo = cellfun(@(x) x == 2, myCellArray(:,2)); myCellArray(...
約5年 前 | 0
回答済み
Remove rows based on length of column value
I think this code will do what you want. It will make a vector with the same number of rows as A, with each element being the nu...
Remove rows based on length of column value
I think this code will do what you want. It will make a vector with the same number of rows as A, with each element being the nu...
約5年 前 | 1
回答済み
How to plot IMU data (XYZ_AER)?
A quiver plot might help you. it essentially lets you draw vectors in 3D space. https://www.mathworks.com/help/matlab/ref/quiv...
How to plot IMU data (XYZ_AER)?
A quiver plot might help you. it essentially lets you draw vectors in 3D space. https://www.mathworks.com/help/matlab/ref/quiv...
約5年 前 | 0
質問
path(pathdef) does not reset the matlab path
I know the question, "How do I restore the Matlab path to it's state at program start up," has been asked a million times and fo...
約5年 前 | 0 件の回答 | 0
0
回答回答済み
Translating points and finding correct normal vector
Sounds like what you really want to do is "shrink" your perimiter. Is that accurate? If so, projecting points back along these...
Translating points and finding correct normal vector
Sounds like what you really want to do is "shrink" your perimiter. Is that accurate? If so, projecting points back along these...
5年以上 前 | 0
| 採用済み