Answered
Creating a control window
You are right about the idea of a GUI to implement the interface you want. Developing a GUI application in MATLAB is not that ha...

15 years ago | 0

| accepted

Answered
??? Subscripted assignment dimension mismatch.
I am copying my answer to another question here. The error is due to, well, "Subscripted assignment dimension mismatch". T...

15 years ago | 0

Answered
BLOCKS
You need to have or purchase the software kit from National Instrument. <http://sine.ni.com/nips/cds/view/p/lang/en/nid/209048 L...

15 years ago | 0

Answered
transferring simulink model from matlab to NI LABVIEW
You probably don't have the proper software installed yet. <http://sine.ni.com/nips/cds/view/p/lang/en/nid/209048 LabVIEW Sim...

15 years ago | 0

Answered
cell matching
Not sure why do you need to have the b{10}=[] and c{10} = [] statement. If it's allowed, you can set those elements to be empt...

15 years ago | 1

Answered
Continuous-time model -> Discrete-time model
SYS = ss(A,B,C,D) and SYSd = ss(A,B,C,D,0.1) are not the same. To discretize your continuous model, you need to use c2d(). Also,...

15 years ago | 0

Answered
Matlab: array of strings
Use cell array of strings: var{1} = 'First string'; var{2} = 'Second string';

15 years ago | 2

Answered
Scaling pcolor graphics on subplots
If you comment out the following two lines in the "Third block plot". The figure is about right. xlim([1 length(B)]); y...

15 years ago | 0

| accepted

Answered
Please help! "Error: Function definitions are not permitted in this context. "
In MATLAB, there are two types of code files, scripts and functions. If the first executable line of your code file is a functi...

15 years ago | 20

| accepted

Answered
Getting 3 zeros from a function using fzero
Are there three zeros? I only get one. Use exp(x), instead of e^x >> my_function = @(x) (-x^2 - 5*x - 3 + exp(x)); a = f...

15 years ago | 0

Answered
SimPowerSystems Model parameter change dynamically
You can't convert .mdl file to .m file You can control the simulation of your .mdl file using .m file. The key function is si...

15 years ago | 1

| accepted

Answered
Extract multiple matrix from a vector
%% v = [0 1 12 3 5 55 0 0 0 0 1 4 22 0 0 5 8 0 0 1 5 85 5 0 0 0 12 0]; s=num2str(v); c=regexp(s,'0\s|\s0','split'); ...

15 years ago | 0

Answered
Running a .m file in a computer which doesn't have Matlab installed!!!
No. You can't. .m and .p files require MATLAB to run. If you have the MATLAB Compiler Toolbox, you could compile a .m file in...

15 years ago | 0

| accepted

Answered
get a 3d image
surf() scatter3() plot3()

15 years ago | 1

| accepted

Answered
problem on uitable
Find the right topic and tutorial from this site. <http://blogs.mathworks.com/videos/category/gui-or-guide/>

15 years ago | 0

Answered
Create Custom ColourBar
colormap() caxis() See this post. I think it might help you! <http://www.mathworks.com/matlabcentral/answers/17594-create-a...

15 years ago | 1

Answered
append string to each element in string cell array
x_label = {'8' '16' '24' '32' '40'}; strcat(x_label,'GHz')

15 years ago | 16

| accepted

Answered
array of ints to cell array of strings?
a=magic(5) b=mat2cell(a,ones(size(a,1),1),ones(size(a,2),1)) c=cellfun(@num2str,b,'uni',false)

15 years ago | 0

| accepted

Answered
How to import data to Excel through Matlab
Or use the Excel COM server. <http://www.mathworks.com/help/techdoc/matlab_external/bqdwu3j.html#bqd_o32>

15 years ago | 0

Answered
Integration
If your u(t) is a symbolic equation, use quad() If your u(t) is numeric data, use cumsum()

15 years ago | 0

Answered
code for getting square waveform
Use textscan() to read the text file, the value will be 1 or 0. Data=[1 0 1]; Volt=Data*10-5; % or Volt=Data*5;

15 years ago | 0

Answered
execution a program step by step
Open you .m file in M-editor, move your cursor to a line and press F12. You will see a red dot in that line just left of the lin...

15 years ago | 0

Answered
unary operator
I think it is like this: x=3>5 is binary as it is the same as x=gt(3,5) 3>5 is unary when exposed to ~ y=~x, or y=~(3>5...

15 years ago | 0

| accepted

Answered
Relatively simple problem with matrix and loops
If you run the following, you have the same problem. The error usually tells you which line of the code did the error happen. So...

15 years ago | 0

| accepted

Answered
how to put in data in a table in a GUIDE user interface
Typically, you set the data of the table. set(handles.Tabel,'Data',x}

15 years ago | 0

| accepted

Answered
Interaction between two list box problem
When you eliminate one item in the string of listbox1 and update the string of listbox1, you didn't update the 'value' of listbo...

15 years ago | 0

| accepted

Answered
How to implement this c-code: if(Flag == 1) {Flag = 0;} ?
This is one of the difference between C and Simulink. In C, you can re-use the variable name. In Simulink, the signal name repre...

15 years ago | 0

Answered
Dialogs do not close
I had the same problem. My experience is that the dialog won't close if there is intense calculation/operation right after the u...

15 years ago | 0

| accepted

Answered
Need basic help w/ GUI Programming
Going through some of the examples here <http://www.mathworks.com/help/techdoc/creating_guis/f6-6010.html> or watching Doug's vi...

15 years ago | 0

| accepted

Load more