Answered

solve the following system of 3 linear equation in unknowns x, y and z? How do I accomplish this?

A = [2 3 4; 5 6 7; 1 1 0]; B = [43; 65; 11]; V = A\B;

solve the following system of 3 linear equation in unknowns x, y and z? How do I accomplish this?

A = [2 3 4; 5 6 7; 1 1 0]; B = [43; 65; 11]; V = A\B;

bijna 11 jaar ago | 0

| accepted

Answered

how to move the plots when slider is dragged.

Heres a basic example, changing xlim via slider callback. function slider_example x = 0:pi/32:8*pi; y = cos(x).^5; ...

how to move the plots when slider is dragged.

Heres a basic example, changing xlim via slider callback. function slider_example x = 0:pi/32:8*pi; y = cos(x).^5; ...

bijna 11 jaar ago | 0

Answered

Need help with plotyy formatting

First legend input can be a vector of plot handles. figure x = 0:0.01:20; y1 = 200*exp(-0.05*x).*sin(x); y2 = 0.8*...

Need help with plotyy formatting

First legend input can be a vector of plot handles. figure x = 0:0.01:20; y1 = 200*exp(-0.05*x).*sin(x); y2 = 0.8*...

bijna 11 jaar ago | 0

| accepted

Answered

Polynomial fitting of each pixel in an image without looping

Referring to your 256 sec calulation time: Got it to 1 sec and 0.8 with parfor. (on my cpu) dim = 256; C = mat2cell(r...

Polynomial fitting of each pixel in an image without looping

Referring to your 256 sec calulation time: Got it to 1 sec and 0.8 with parfor. (on my cpu) dim = 256; C = mat2cell(r...

bijna 11 jaar ago | 0

| accepted

Answered

How to read a text file and create a structure array?

Try to skip the second comma. C = textscan(fid, '%s%d8%*s%f32');

How to read a text file and create a structure array?

Try to skip the second comma. C = textscan(fid, '%s%d8%*s%f32');

bijna 11 jaar ago | 0

| accepted

Answered

Get max value and index of multidimensional array

Use 1D-Indexing: M = randn(10,10,10,10); [C,I] = max(M(:)); C M(I) This might be useful too: [I1,I2,I3,I4]...

Get max value and index of multidimensional array

Use 1D-Indexing: M = randn(10,10,10,10); [C,I] = max(M(:)); C M(I) This might be useful too: [I1,I2,I3,I4]...

bijna 11 jaar ago | 11

Answered

how to evaluate a symbolic function in matlab

* doc subs * doc subexpr

how to evaluate a symbolic function in matlab

* doc subs * doc subexpr

bijna 11 jaar ago | 1

Answered

Exporting data to excel every time a program is run

x = 1:100; a = x.^2; xlswrite('xls_test',a)

Exporting data to excel every time a program is run

x = 1:100; a = x.^2; xlswrite('xls_test',a)

bijna 11 jaar ago | 0

| accepted

Answered

Polynomial fitting of each pixel in an image without looping

Is the overall result just 5 scalar k values? X = cat(1,C{1,:}); Y = cat(1,C{2,:}); Z = cat(1,C{3,:}); M = [X(...

Polynomial fitting of each pixel in an image without looping

Is the overall result just 5 scalar k values? X = cat(1,C{1,:}); Y = cat(1,C{2,:}); Z = cat(1,C{3,:}); M = [X(...

bijna 11 jaar ago | 0

Answered

centroid of image and value of pixel

Do you have Image Processing Toolbox? If yes, here you go: BW = imread('text.png'); s = regionprops(BW, 'centroid'); ...

centroid of image and value of pixel

Do you have Image Processing Toolbox? If yes, here you go: BW = imread('text.png'); s = regionprops(BW, 'centroid'); ...

bijna 11 jaar ago | 0

Answered

Can I set explicit plot colors for specific values or value ranges

Yes its possible, only for contour3 its a bit fumbling. Surface function has an input for the colormatrix C. C is referring t...

Can I set explicit plot colors for specific values or value ranges

Yes its possible, only for contour3 its a bit fumbling. Surface function has an input for the colormatrix C. C is referring t...

bijna 11 jaar ago | 0

| accepted

Answered

How to change a specific line in a text file?

# Loading txt into a cell. # Then do whatever you want with the cell. In this example, line 69 will be 99. # Then write the c...

How to change a specific line in a text file?

# Loading txt into a cell. # Then do whatever you want with the cell. In this example, line 69 will be 99. # Then write the c...

bijna 11 jaar ago | 14

| accepted

Answered

How do I get my string from a handle.text GUI HELP

Get String from text handle: get(handles.text,'String') Checking and breaking a loop: if strcmp(get(handles.text,'S...

How do I get my string from a handle.text GUI HELP

Get String from text handle: get(handles.text,'String') Checking and breaking a loop: if strcmp(get(handles.text,'S...

bijna 11 jaar ago | 0

Answered

can i use more than 1 function in same m. file ? because i want to use multiple function for adapting frequency

# The attempt having myeqd1, myeqd2, myeqd3, ... and then solve them with ode45(myeqd1,...); ode45(myeqd2,...); ... etc is bad i...

can i use more than 1 function in same m. file ? because i want to use multiple function for adapting frequency

# The attempt having myeqd1, myeqd2, myeqd3, ... and then solve them with ode45(myeqd1,...); ode45(myeqd2,...); ... etc is bad i...

bijna 11 jaar ago | 0

| accepted

Answered

Ubuntu - german umlaute in plots

I dont have Ubuntu but you can try this: title('Example \"a \"o \"u') title('Example ä ö ü','Interpreter','none')

Ubuntu - german umlaute in plots

I dont have Ubuntu but you can try this: title('Example \"a \"o \"u') title('Example ä ö ü','Interpreter','none')

bijna 11 jaar ago | 0

| accepted

Answered

Running area under the curve at each time step.

Your input to trapz is a single point, you want to input a line. And for n = length(x) acceleration points you can only get n-1 ...

Running area under the curve at each time step.

Your input to trapz is a single point, you want to input a line. And for n = length(x) acceleration points you can only get n-1 ...

bijna 11 jaar ago | 0

Answered

Fillm function paints all map instead of area inside polygon on map. How to solve this issue?

Your polygon is self-intersecting. You can see it, if you zoom in to the bottom corner. To fix it, define better points, eg: ...

Fillm function paints all map instead of area inside polygon on map. How to solve this issue?

Your polygon is self-intersecting. You can see it, if you zoom in to the bottom corner. To fix it, define better points, eg: ...

bijna 11 jaar ago | 0

Answered

How to pass values from one ode to another ode?

Write all equations in 1 function and make your state vector like this: 'x = [w;q]'. Tell me, if you need more details.

How to pass values from one ode to another ode?

Write all equations in 1 function and make your state vector like this: 'x = [w;q]'. Tell me, if you need more details.

bijna 11 jaar ago | 0

Answered

How to rotate the symblo only in the 3D map

Here is a simple basic part. n = 100; X = randi(n,30,1); Y = randi(n,30,1); Z = randi(n,30,1); r = 4; % factor for ...

How to rotate the symblo only in the 3D map

Here is a simple basic part. n = 100; X = randi(n,30,1); Y = randi(n,30,1); Z = randi(n,30,1); r = 4; % factor for ...

bijna 11 jaar ago | 0

Answered

imaqmontage(data); question about this code

data = getdata(obj,samples) samples - The number of samples to extract. If samples is not specified, the number of samples ...

imaqmontage(data); question about this code

data = getdata(obj,samples) samples - The number of samples to extract. If samples is not specified, the number of samples ...

bijna 11 jaar ago | 0

| accepted

Answered

4D dicom matrix? Why not 3D?

"Is this the gray level intensity?" - Yes, color reserved dimensions. It's mostly not about the gray scale. These values just...

4D dicom matrix? Why not 3D?

"Is this the gray level intensity?" - Yes, color reserved dimensions. It's mostly not about the gray scale. These values just...

bijna 11 jaar ago | 1

Answered

how to write a code for checkbox

Code for the checkboxes uicontrol: hax = [h1;h2;h3]; % axes handles hcb = [0;0;0]; % checkbox handle (preallocate) cb...

how to write a code for checkbox

Code for the checkboxes uicontrol: hax = [h1;h2;h3]; % axes handles hcb = [0;0;0]; % checkbox handle (preallocate) cb...

bijna 11 jaar ago | 1

| accepted

Answered

am able to zoom only last plot ,how to zoom other plots.please help

The function |setAllowAxesZoom| will do the job. If you add this example to your code, you are zooming in axes h1. hz = zoo...

am able to zoom only last plot ,how to zoom other plots.please help

The function |setAllowAxesZoom| will do the job. If you add this example to your code, you are zooming in axes h1. hz = zoo...

bijna 11 jaar ago | 1

| accepted

Answered

x-labels do not show in bar3 graph

Try |hold on| befor the loop: X={1;2;3;4;5;6;7;8;9;10;11;12;13;14;15}; Y={2;3;2;3;4;2;3;4;2;3;4;2;3;4;5}; hold on ...

x-labels do not show in bar3 graph

Try |hold on| befor the loop: X={1;2;3;4;5;6;7;8;9;10;11;12;13;14;15}; Y={2;3;2;3;4;2;3;4;2;3;4;2;3;4;5}; hold on ...

bijna 11 jaar ago | 0

| accepted

Answered

How to identify contiguous regions between two thresholds?

[C,h] = contour(...) The ContourMatrix C contains directly the infomation you are looking for. Just look up ContourMatrix i...

How to identify contiguous regions between two thresholds?

[C,h] = contour(...) The ContourMatrix C contains directly the infomation you are looking for. Just look up ContourMatrix i...

bijna 11 jaar ago | 0

| accepted

Answered

How to detect equal rows of a matrix compare with another matrix with a 10 per cent of margin?

m = 0.1; % margin A = [1 2 3; 4 5 6; 7 8 9]; B = [7 8 10; 4 5 12; 1.1 2.2 2.9; 1.101 2 3; 6.3 7.2 9.9]; k = 0; ...

How to detect equal rows of a matrix compare with another matrix with a 10 per cent of margin?

m = 0.1; % margin A = [1 2 3; 4 5 6; 7 8 9]; B = [7 8 10; 4 5 12; 1.1 2.2 2.9; 1.101 2 3; 6.3 7.2 9.9]; k = 0; ...

bijna 11 jaar ago | 0

| accepted

Answered

How can I adjust the position of a 'scattergroup' (scatter3) figure?

scrsz = get(0,'ScreenSize'); set(gcf,'OuterPosition',[scrsz(3)/2 scrsz(2) scrsz(3)/2 scrsz(4)]) n = 20; scatter3(rand...

How can I adjust the position of a 'scattergroup' (scatter3) figure?

scrsz = get(0,'ScreenSize'); set(gcf,'OuterPosition',[scrsz(3)/2 scrsz(2) scrsz(3)/2 scrsz(4)]) n = 20; scatter3(rand...

bijna 11 jaar ago | 0

| accepted

Answered

How can I adjust the position of a 'scattergroup' (scatter3) figure?

n = 20; scatter3(rand(n,1),rand(n,1),rand(n,1),[],randi(3,n,1),'filled') axp = get(gca,'Position'); set(gca,'Position...

How can I adjust the position of a 'scattergroup' (scatter3) figure?

n = 20; scatter3(rand(n,1),rand(n,1),rand(n,1),[],randi(3,n,1),'filled') axp = get(gca,'Position'); set(gca,'Position...

bijna 11 jaar ago | 0

Answered

doubt with check boxes

uicontrol('Style','checkbox') % doc uicontrol

doubt with check boxes

uicontrol('Style','checkbox') % doc uicontrol

bijna 11 jaar ago | 0

| accepted