Answered
How to change mathematical symbols of division (/ to ./) and multiplication(* to .*) in a very long formula obtained by symbolic tool.
to do this you can do something like this. textEquation=char(symsEquation); division = [0 strfind(textEquation,'/')]; ...

12 years ago | 0

Answered
why this program showing error like undefined variable.?..one day before same program was giving results but now it os showing error.please help
My answer to why it worked one day and not another would be pasted code is a script. The issue with scripts is that if you do n...

12 years ago | 0

| accepted

Answered
why "if loop" contents not getting computed?
if statements do not work this way. how it is written is if all of s1 is <2. I would suggest read the document on if stateme...

12 years ago | 0

| accepted

Answered
How can I change the text color within a multi-line cell array
If you look at the documentation for text() you can see an example, i pasted it below. text(.1,.5,['\fontsize{16}black ...

12 years ago | 0

| accepted

Answered
Matlab GUIDE - Change color while loop is running?
So.... you can use <http://www.mathworks.com/help/matlab/matlab_prog/use-a-matlab-timer-object.html timer> which if used prope...

12 years ago | 0

| accepted

Answered
How to copy contents of one text file to other text or .c file ?
This link <http://www.mathworks.com/matlabcentral/answers/98758 How can I prepend text to a file using MATLAB?> should be what y...

12 years ago | 0

| accepted

Answered
Get code from a GUI created using GUIDE
The only way I can think of getting the positions and parameters from the GUI items would be to insert a section within the star...

12 years ago | 0

Answered
How to change the value of a double variable in a .mat file
From the documentation '-append' adds a new variable to the mat file, so I do not think it will append to an existing struct. ...

12 years ago | 0

Answered
how to plot a graph of the equation (x^5)+(x^4)+(x^3)+(9*x^2)+8*x+3
You'll need to include the element-wise power in your y equation. instead of just ^ you will need to use .^ y=(x.^5)+(x.^...

12 years ago | 0

Answered
How can I find the first row of a specific number in a matrix?
you can use the find() function and search for when the first column in A contains "6".

12 years ago | 0

Answered
pls i need a code that can be used to convolute a signal ??
matlab has a built in convolution function called conv().

12 years ago | 0

Answered
How to delete leading zeros in a row vector in MATLAB?
So I take it is a string array? If it is I would use something like this. result='000000000123450101010' mask = ones(si...

12 years ago | 1

Answered
Populating a spreadsheet - dlmwrite, '-append' and specifying rows and columns
The error is that you are missing 'roffset' and 'coffset' designators for the row and column. However that will still not do ...

12 years ago | 0

| accepted

Answered
how to use cells arrays and loops
You'll want to look up the documentation for input and while. Those should get you started.

12 years ago | 0

Answered
ginput with right mouse button
I do not know if ginput will let you use the right mouse button the way you want. But you can go with something like this. whi...

12 years ago | 0

Answered
Hello all, I am trying to build a MATLAB level 2 s function which has the following equations.
See example of writing a level-2 matlab s-function <http://www.mathworks.com/help/simulink/sfg/writing-level-2-matlab-s-funct...

12 years ago | 1

Answered
Progress bar music, update in real time
I do not have the time just at this moment to try it out but this link <http://www.mathworks.com/matlabcentral/answers/95933> do...

12 years ago | 0

Answered
Creating a Function file with multiple user inputs
What is the error? The only error i get are that xl and xu are not defined but that is an issue in the falseposition.m file. Y...

12 years ago | 0

Answered
calculate the distance between two successive dots
you'll have to do something like this T = zeros; x=0;z=0; a=length(points);%79points for i = 1:2:a ...

12 years ago | 0

| accepted

Answered
Changing duplicates in an array to zero?
here is a simple thing i just threw together. Hopefully it helps. As you can see what i'm doing below is finding the differen...

12 years ago | 0

| accepted

Answered
Use a root finding method to find a root of the derivative of the function
It sounds like you do not understand the problem at all. As you said the specified function doesn't have a zero value and you ar...

12 years ago | 0

| accepted

Answered
In an assignment A(I) = B, the number of elements in B and I must be the same.
each of your "Comfort(count)= something" is trying to stuff the string that has 3+ elements into a single array index. Perhaps...

12 years ago | 0

Answered
grabbing values from .txt to create stacked bar graph
your fgetl(fileID) will get each line of data but you'll have to extract the data from the line. you can use the strfind(line,'...

12 years ago | 0

| accepted

Answered
plot data dynamically in the figure
The example for drawnow should be easy to adapt for your purposes. You can then insert the function pause(.5) into the for loop...

12 years ago | 0

Answered
Distinguishing between two surfaces
I would first call the two z something different that way you don't override the other z. Yes a simple subtraction would be som...

12 years ago | 0

Answered
Using Print command to save pdf of figure to a different directory
can you use ... h=gcf; set(h,'Position',[0 0 1200 800]); set(h,'PaperOrientation','landscape'); set(h,'PaperPos...

12 years ago | 0

Answered
Counting bounding boxes inside ROI
There are many ways to do this but it depends on how you are defining or receiving the ROI. Is the ROI defined by its corners s...

12 years ago | 0

Answered
What's wrong with this code?
yes thats because you are including information that is not here and in your other posting that was flagged. but looks like you...

12 years ago | 1

Answered
I need to print a string of text to a file. Then I need to put something in a for loop that will print values from a matrix
Does the fprintf work enough to get you your header? If you can get that and the rest of the output is just numbers i would s...

12 years ago | 0

Answered
What's wrong with this code?
Were you attempting to do this? r=[2.0 3.1 3.5 3.65 3.84 3.95]; x=[]; x(1,:)=0.35*ones(size(r)); f=@(x) r*x*(1-x);...

12 years ago | 0

Load more