Réponse apportée
Questions Regarding Matlab & Txt Files
To read the text file into a variable: txt = fileread('/path/to/text/file.txt') To get the number of 'b''s in a file. ...

plus de 13 ans il y a | 0

Réponse apportée
hi guys, i am having a problem with coupled differential equation i dont know where i am going wrong. pls have a look at my code and post some suggestions..
So what exactly is wrong with the function? What is the problem?

plus de 13 ans il y a | 0

Réponse apportée
How to perfrorm this task using for loop and find function?
Since this is homework, we won't provide the code, but have you looked at the help for these two functions? At the Matlab prompt...

plus de 13 ans il y a | 0

Réponse apportée
what is PAR on MATLAB?
First, par and Y here appear to be previously-defined Matlab variables, not built-in functions. It looks like the outputs fro...

plus de 13 ans il y a | 0

Réponse apportée
Putting random values in for loop
Hi Sazzad, First of all, you don't need the loop: you can just do it like this: vv = floor(+1*120*sin(2*pi*(t-1)/40)); ...

plus de 13 ans il y a | 1

Réponse apportée
Help with looping problem
I'm not entirely clear what you want, but I think this will do the trick: x = (0:0.1:pi)'; rx = [x, x]; ry = [ repmat...

plus de 13 ans il y a | 0

Réponse apportée
Outputing a high and low value based on a negative or positive signal
Hi Joseph, You could use a switch block ( <http://www.mathworks.com/help/simulink/slref/switch.html>) where the second input...

plus de 13 ans il y a | 0

Réponse apportée
How to load numeric & string data from .txt file
This should do it, for your specific case: fid = fopen('data.txt', 'rt'); C = textscan(fid, '%d %s %f,%f,%f', 'HeaderLin...

plus de 13 ans il y a | 3

| A accepté

Réponse apportée
How can I limit the maxmimum number of files to be loaded from a database?
You could use dir() to get the names of all *.mat files, and then use randperm() to randomly choose 15000 of them. Something lik...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
Ignore elements in an array.
Are Value and Time the same size? If so, you can just do this, using logical indexing (no loops): deleteThese = (Value <= 0...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
Need Conditional ElseIf statement
Matlab won't correctly parse the 0<w(5)<255 statement as you intend. (Instead, it will evaluate (0 < w(5)) first (which returns ...

plus de 13 ans il y a | 1

Réponse apportée
Is it possible to plot a function T(x,y,z,t), or even just T(x,y,z)?
Sure, the easiest way is to represent the T value using color, using scatter3 (for discrete data), or patch/surf (for continuous...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
unexact calculations when using delayss
Hi David, This is due to the fact that Matlab (like any computational program) stores numbers in a finite-precision length. I...

plus de 13 ans il y a | 0

Réponse apportée
How to Import unformatted text data?
Hi Maddila, This looks like a rather non-uniform format, so your best bet might be to read in the full file, and then separat...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
how to connect coordinate points?
Hi Sayak, I'm a little bit unclear on what you are trying to do, but I think you want to use bwboundaries. That will give you...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
Is there any other alternative fuction that I can use instead of fminunc?.
Hi Salva, You could use fminsearch or fminbnd, two derivative-free optimizers. However, given that the error is thrown when t...

plus de 13 ans il y a | 0

Réponse apportée
converting matlab image to jpg image
doc imwrite

plus de 13 ans il y a | 0

Réponse apportée
I want to read ascii file into matlab which has 191 rows and 9 columns. Then I have to convert it into matrix form that too row wise also I have to convert magnitude and angle into real and imaginary parts.
To read the ASCII file into Matlab: doc textscan To convert from magnitude-angle to complex a+bj, just use Complex=...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
Setting X as a column of a matrix
You can also do this using logical indexing, which is a more "Matlab-y" way to do this problem... y = repmat('A', size(M(...

plus de 13 ans il y a | 0

A soumis


Legend Toggle
Toggle visibility of graphics objects by clicking on legend. Allows for custom callback function.

plus de 13 ans il y a | 1 téléchargement |

0.0 / 5

Réponse apportée
how to get the background of an image?
This question is almost impossible to answer without a) the image in question, and b) your definition of what the "background" i...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
How can I withdraw a colon operator from a string
Mr. Azzi's technique is more general, and I would use it for your purpose. However, if you did want to use 'find' to locate s...

plus de 13 ans il y a | 0

Réponse apportée
normalize a maatrix of 13 columns
Hi Kim, Let's go through each step: To square, use A^.2 To sum, use the sum() function. Read the documentation to learn...

plus de 13 ans il y a | 0

Réponse apportée
Text file reading problem
Hi Oscar, I've had a similar issue (reading data from a text file with an irregular format, and instead a series of "keys" th...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
Delete the Whole Row and Merge The Next Row in a matrix
I'm not sure I understand what "merge" you are trying to do. It sounds like you just want to delete rows that satisfy a particul...

plus de 13 ans il y a | 1

| A accepté

Réponse apportée
open a folder outside of MATLAB
I am assuming by your directory structure you have Windows: winopen('G:\name1\inputs');

plus de 13 ans il y a | 7

| A accepté

Réponse apportée
about figure is control
Hi Pan, It is not really clear in your question what behavior you want. Are you saying that you have two figures, Figure1 and...

plus de 13 ans il y a | 0

Réponse apportée
Improving modal analysis code
Hi Pinco, What are the dimensions of BI2, PHI, and y? You might be able to use matrix multiplication directly to eliminate t...

plus de 13 ans il y a | 0

| A accepté

Réponse apportée
how to inverse a vector
doc sort

plus de 13 ans il y a | 0

Réponse apportée
plot 1st order bessel derivative
I think you need to use element-wise division with the z: a=besselj(0, z) - besselj(1, z)./z;

plus de 13 ans il y a | 1

| A accepté

Charger plus