Matlab Definition and 1000 Threads
-
I
MATLAB How Can You Handle Unassigned Outputs in Simulink's Embedded MATLAB Function?
Hello everyone! In Simulink , I use the Embedded MATLAB Function function out = fcn(meas) if meas>10 out = 4; elseif meas<=0 out=2; end And I get this message: Output argument 'out' is not assigned on some execution paths. I would like the variable 'out' to change its...- ilconformista
- Thread
- Function Matlab Simulink
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
M
MATLAB, single command for multiple columns
Homework Statement Create the following matrix by typing one command. Do not type individual elements explicitly. \begin{array}{ccc} 0 & 0 & 0 & 0 & 0 \\ 0 & 0 & 1 & 4 & 7 \\ 0 & 0 & 2 & 5 & 8 \\ 0 & 0 & 3 & 6 & 9 \\ \end{array} Homework Equations None The Attempt at a...- moouers
- Thread
- Columns Matlab Multiple
- Replies: 3
- Forum: Engineering and Comp Sci Homework Help
-
L
Matlab - What does an array definition mean
I'm trying to make a MATLAB plot with two types of data, i.e. temperature and air flow rate. Since the temperature and air flow rate are on different scales I wanted two y-scales and since there are quite some data sets, I wanted to make the two air flow rates bold. I tried this, but it doesn't...- luitzen
- Thread
- Array Definition Matlab Mean
- Replies: 2
- Forum: Engineering and Comp Sci Homework Help
-
E
MATLAB How to do Abel inversion using Matlab
hi,everyone. How to do Abel inversion using Matlab? what is the algorithm? I read something in wiki,but I have no idea how to perform it! anything helpful would be highly appreciated.- einstein1921
- Thread
- Inversion Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
MATLAB - Autocorrelation Project
I'm trying to design a program that can accurately detect the frequency of a real, periodic audio signal, such as several guitar notes in sequence. I have the skeleton of the program working. It does, at times, accurately detect the frequency. However, it is very noisy, and I'm not too sure how...- ElijahRockers
- Thread
- Autocorrelation Matlab Project
- Replies: 19
- Forum: Engineering and Comp Sci Homework Help
-
M
MATLAB Matlab fails to access a list of variables
So I have a list of variables, defined in my workspace, and I'm trying to access them each in turn to compare them to a larger matrix A. The eval function calls each variable in turn, stores it under temporary matrix B, then compares it to matrix A, does the necessary calculation, and stores it...- MartinV
- Thread
- List Matlab Variables
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
Q
MATLAB Fit data with function in MATLAB
Dear users I have some points with coordinate x and y forexample : x=[1 2 3 4] and y=[2 4 6 8] and then I want to fit these 4 pair of points with some function for example y=a*x+b (here I know that the answer is a=2 and b=0) what should I...- quin
- Thread
- Data Fit Function Matlab
- Replies: 4
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
E
MATLAB How can I optimize my MATLAB program to reduce processing time?
Hello, I have a MATLAB code that contains a lot of for loops, and hence it is very slow, and takes hours and hours to get just initial results, which is very inefficient. I know writing the program in terms of vectors will fasten the process, however, I do not know how to write my program...- EngWiPy
- Thread
- Matlab Program
- Replies: 4
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
G
MATLAB code for generating PPM :
Hi all, I am quite new to MATLAB . I would like some help on the following: generation of Pulse Position Modulation using a MATLAB code. thank you :)- Ghassan99
- Thread
- Code Matlab Matlab code
- Replies: 1
- Forum: Engineering and Comp Sci Homework Help
-
MATLAB Mistakes in Matlab, Wolfram, Derive and Ti Nspire
hello remember not speak English and use a translator on line, together some pictures to show some errors,from a simple integral or easy to those who are not as oscillatory integrals, when I worked and ask oscillatory integrals or approximate numerical answers, also when try plot a complex...- jeffer vitola
- Thread
- Derive Matlab Nspire
- Replies: 5
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
V
MATLAB Simulate Hysteresis Loop in MATLAB | Step-by-Step Tutorial"
Hi there, Would anyone help me in simulating hysteresis loop in MATLAB? Thank You!- vinzie
- Thread
- Hysteresis Hysteresis loop Loop Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
J
MATLAB MATLAB trouble with reshape and random matricies
I am trying to learn MATLAB with MIT OCW and I am running into some trouble. It says as an assignment: c. cMat = a 10x10 matrix where the vector 1:100 runs down the columns (use reshape). so 1 11 21...91 2....92 . ..... 10...100 is the matrix I am trying to make and another...- JonDrew
- Thread
- Matlab Matricies Random
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
W
How to Create MATLAB Code for Geometrical Optics Image Transformation?
Hello all, i have frustrating task in my lab... i have to generate a code in MATLAB that will get the focal length and the object distance from the lens, i.e image (1000X1000 pixels). transfer it through the lens and, for the output it should be the result of it...- wuid
- Thread
- Code Geometrical Geometrical optics Matlab Matlab code Optics
- Replies: 8
- Forum: Advanced Physics Homework Help
-
O
MATLAB MATLAB FFT: Zero Out DC Component for Better Frequency Analysis
Hello, I am hoping someone can give me some advice. I need to zero out the DC component of an FFT I have done, so I can get a better look at the rest of the frequency components, so how would one go about doing that? I am not looking the code, just some advice ...I have just really started...- OnceMore
- Thread
- Fft Matlab
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
P
MATLAB Customize 3D Function Markers in MATLAB with Texts - Quick Guide
Hello, I am working on MATLAB and I want to plot a function in 3D. However, I want the markers to be a letter instead of the markers provided by MATLAB. Is there a way I can do this? Thanks- PaulaS
- Thread
- Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
K
MATLAB How can I change the x and y-axis limits in Matlab to arbitrary scales?
Hello, I have an image which gets displayed and has the x and y-axis ranging from 0-812 and 0-607 respectively. This is because these are the pixel sizes for my image. I would like to change the x-axis to show -3.85, 3.85 and for the y-axis to show -2.9,2.9. However, when I load my image into...- Kidphysics
- Thread
- Axis Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
S
MATLAB Solving Matlab Error: "The Expression to Left of Equals Sign
i have tried for an hour but have been constantly getting an error saying "The expression to the left of the equals sign is not a valid target for an assignment".what should i do? i need the expression E=[Z*(r-1/D)+exp(Z*(r-1/D))-1].*exp(-r.*Z).*1/(r-1/D).^2 ; please reply asap- supraja
- Thread
- Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
J
MATLAB How to do a dynamic graph in matlab
Hi guys, so I've never used MATLAB before, and i need to make a plot that changes constantly. Let's say that i have Sin(x) from 0 to 3pi Then i need it to change to a Cos(x) from 0 to 3pi then to a Tan(x). I could do it in other languaje like Php or c, but in MATLAB i have no idea. I...- juanitotruan77
- Thread
- Dynamic Graph Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
A
MATLAB Integration of a 2D matrix using MATLAB
How to do integration for a 2D matrix using MATLAB? That is to say, suppose I have a bunch of data points over a rectangular region in xy plane, how to find the integral over this plane? More explicitly, suppose I want to integrate over a square region, [0,4]x[0,4] my data is 2 4 5...- AlonsoMcLaren
- Thread
- 2d Integration Matlab Matrix
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
S
MATLAB Study material for CFD using Matlab
I want to learn some basics of Computational Fluid Dynamics.But most of the books that I found dealt mostly with the theory of it with very less examples or problems to be solved numerically. I know Matlab and am pretty good at coding too.So, I am searching for a book from which I can learn CFD...- sourav92
- Thread
- Cfd Material Matlab Study
- Replies: 5
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
B
How do I solve for H in matlab?
I need help implementing this bit of code into matlab. I have a known matrix lest call it Z. and I have another unknown matrix called H. The matrices are related by the following relationship. Z = HTH How do I solve for H in matlab? If it is relevant Z is a make up of other known matrices and...- Badger33
- Thread
- Matlab Matrix
- Replies: 2
- Forum: Engineering and Comp Sci Homework Help
-
N
Matlab Recursion Problem - Need help Understanding It
They give me this problem in my last exam, I did not get it right - its a very convoluted and I think poorly worded problem. Rants aside, how am I supposed to be able to answer a problem like this on the next exam? What sort of mindset will help me deal with recursion problems of this form? How...- Nano-Passion
- Thread
- Matlab Recursion
- Replies: 7
- Forum: Engineering and Comp Sci Homework Help
-
R
MATLAB [Matlab] Transform generated table to equation for for loop usage
I have posted a question on here before regarding the generation of a number sequence. I followed up that question with an answer. However, as I have developed my code more I need to use an equation instead of a lookup table. Note: I'm using MATLAB Given a matrix A of size r x c where r >=...- roldy
- Thread
- Loop Matlab Table Transform
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
G
MATLAB Extract and rearrange data in Matlab
Hi all, I need to rearrange my data. I have an excel file with 12 columns and 2045 rows, which I transformed that into a .mat. I need to query my data rearranged as follows (cf. example matrix below): 1-sum all values of Col 3 if: a-they belong to a given value of Col 1 and to a...- geoffrey g
- Thread
- Data Matlab Rearrange
- Replies: 8
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
MATLAB How to simulate 2nd order markov chain (if poss. Nth order) in MATLAB
Hi PF, I would like to simulate N th order markov chain (not by means of hidden markov models, but ordinary markov chain) using Matlab. If n-th order is a heavy thing atleast 2nd or 3rd order will do. TIA- dexterdev
- Thread
- 2nd order Chain Markov chain Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
MATLAB How to do this vector operation in MATLAB ?
Hi friends, I wanted a help in Matlab programming. I have some vectors as below : d4=cos(2*pi*293.665*(0:1/44100:.25)); f4=cos(2*pi*349.228*(0:1/44100:.25)); e4=cos(2*pi*329.628*(0:1/44100:.25)); g4=cos(2*pi*391.995*(0:1/44100:.25)); c5=cos(2*pi*523.251*(0:1/44100:.25))...- dexterdev
- Thread
- Matlab Vector
- Replies: 5
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
B
Matlab code for solving and plotting function x'(t) = 1 + t*sin(t*x)
Homework Statement I am trying to solve and plot the function, x'(t) = 1 + t*sin(t*x) where x(0) = 0 and t_final = 1, in order to compare this exact solution to the approximations of Euler's and Improved Euler's Method. Can anyone help me with the code in order to solve this problem, and then...- bdoherty1994
- Thread
- Code Function Matlab Matlab code Plotting
- Replies: 3
- Forum: Calculus and Beyond Homework Help
-
B
MATLAB Matlab Code for solving and plotting function x'(t) = 1 + t*sin(t*x)
Hi everyone, I am trying to solve and plot the function, x'(t) = 1 + t*sin(t*x) where x(0) = 0 and t_final = 1, in order to compare this exact solution to the approximations of Euler's and Improved Euler's Method. Can anyone help me with the code in order to solve this problem, and then plot...- bdoherty1994
- Thread
- Code Function Matlab Matlab code Plotting
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
E
MATLAB How to display all calculation results in Matlab
Hi, How can I set Matlab to display all the calculation results? I am solving the system of ODEs with large spatial variable and time step distribution. If I set total time to 100 with time step of 1 only the results starting from t=50 are displayed. How to fix it?:frown: Thanks.- Ein Krieger
- Thread
- Calculation Matlab
- Replies: 4
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
T
MATLAB How to convert GO TO (Fortran77) to Matlab
I'm translating some code from Fortran77 to Matlab and I'm struggling due to the sentence GO TO is not valid in Matlab. Usually using sentences while I can solve the problem but in a particular case I don't know how to face it. To put in situation, i.e: code line 1 line 2 ... 128...- Triscas
- Thread
- Convert Fortran77 Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
S
Finite Element MATLAB Code for Solving Boundary Value Problems
Homework Statement Consider the problem $$-u''\left(x\right) = 1, \;\; 0 < x < 3, \;\; u \left(0\right) = 0, \; -u' \left(3\right) = u\left(3\right)+1.$$ Formulate a MATLAB code to produce the solution and plot the solution from 0 to 3. Homework Equations The Attempt at a Solution Multiply by...- squenshl
- Thread
- Element Finite finite element Matlab
- Replies: 1
- Forum: Calculus and Beyond Homework Help
-
R
MATLAB Matlab code for detection of location of a crack using natural frequen
please help i have to write a MATLAB code for DETECTION OF THE LOCATION AND SIZE OF A CRACK IN STEPPED CANTILEVER BEAMS BASED ON MEASUREMENTS OF NATURAL FREQUENCIES the reference paper is DETECTION OF THE LOCATION AND SIZE OF A CRACK IN STEPPED CANTILEVER BEAMS BASED ON MEASUREMENTS OF...- ritika.krishna
- Thread
- Code Crack Detection Matlab Matlab code Natural
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
MATLAB MATLAB: How to add initial states to a circuit simulation
Hello! I am having trouble using the SimPowerSystems library from simulink to simulate circuits (with the powergui solver). On all the circuits I have simulated so far either of the following happens: - Adding the initial current/voltage directly at the RLC branch block culminates into...- franciobr
- Thread
- Circuit Initial Matlab Simulation States
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
R
MATLAB Matlab: what is the right 3D plotting function for my code?
Hi all, I have a simple question about 3D plotting. Consider this simple loop, which provides y and O for any x. and I am able to plot y vs O for given x. for Omega=0:.01:5 y(i)=(x*Omega^2); O(i)=Omega; i=i+1; end now consider I want to change the value of x, for x=0:.1:3...- Romik
- Thread
- 3d Code Function Matlab Plotting
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
M
Solving Rocket Launch Equations in matlab
Homework Statement A Super Loki rocket (http://en.wikipedia.org/wiki/Loki_(rocket )) is used to launch a small payload to above 100 km altitude in a sub orbital flight. Ignoring atmospheric resistance, find the apogee using both numerical and analytic techniques (solve the differential...- mysticboon
- Thread
- Launch Matlab Rocket
- Replies: 1
- Forum: Advanced Physics Homework Help
-
M
MATLAB How can I solve an equation with an integral in MATLAB?
hi people, I've just recently started using MATLAB (last week) and 've already got plenty of problems. Could anyone help me with this for example [??]: 1) 3=∫(0,inf) (sqrt(ε)/exp[(ε-μ)/(8*T)] dε so this is the equation. I would like to solve in a way that μ=... , and then plot the...- _Matt87_
- Thread
- Integral Matlab
- Replies: 13
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
E
MATLAB How code the following expression into Matlab
Hey, guys How can the following equation be entered into matlab: http://i074.radikal.ru/1304/fe/a8b8e0fccbe5.png Thakns.- Ein Krieger
- Thread
- Code Expression Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
E
Divide and Conquer, Matrix Multiplication MATLAB
Problem Statement We are asked to use the following divide and conquer algorithm to get the solution for the multiplication of some matrix A and some matrix B. (See below) Consider the matrix sizes. Comment the total computational time used on the following three algorithms, when different...- Evales
- Thread
- Matlab Matrix Matrix multiplication Multiplication
- Replies: 1
- Forum: Engineering and Comp Sci Homework Help
-
A
MATLAB Error Message while trying to Plot Magnification Factor
Homework Statement I am trying to make a plot of the magnification factor of an underdamped vibrating system versus the frequency ratio using MATLAB. However, my MATLAB skills are very basic and I keep getting an error message. Basically I am trying to plot: MF=1/√((1-r^2)^2+(2ζr)^2)...- amr55533
- Thread
- Error Magnification Matlab Plot
- Replies: 2
- Forum: Engineering and Comp Sci Homework Help
-
MATLAB Droplet Profile in Matlab- ODE stability
Hello, I'm currently modeling the profile of a droplet (sessile drop, axisymmetric) in matlab. I've coded differential equations, applied the solver, and I get a reasonable result, except that it spirals continuously. The ODE's in question are: \frac{dx}{ds}=cos(\theta)...- Kudaros
- Thread
- Matlab Ode Stability
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
P
MATLAB Differential Equation formulation (and execution in matlab) problem
Hello, I am trying to solve an equation and then execute it in matlab. It is dx/dt=I(S*A*x). so I am trying to see the evolution of x with time. The variables are all in an excel spreadsheet in different columns and the name of the columns are the name of the variables. 'I' is in an...- pottersj
- Thread
- Differential Differential equation Matlab
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
I
MATLAB Decoding a Playfair Code with Matlab: Tips and Tricks
Hi all, I hope my post is in the right section. I need some help with decoding a Playfair code. I only have the ciphertext which is 22 lines long. What's the best way to do this? I red that I have to do some frequency analysis of the English bigrams which I did. There's one combination which...- Impo
- Thread
- Code Matlab Tips
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
L
MATLAB Matlab and arduino: serial port connection
Hello, I am trying to hook up MATLAB to my arduino. I am trying to write a number to the serial port in the arduino IDE and retrieving the same number in the MATLAB IDE. My arduino code is: void setup() { // initialize serial communication at 9600 bits per second: Serial.begin(9600); }...- lcr2139
- Thread
- Arduino Connection Matlab Serial
- Replies: 5
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
S
MATLAB How Can I Code the Rate of Reaction in MATLAB?
Can Anybody help to code this in matlab A->B --- A is Sbbstrate here and B is Product Y[b][/a]=stiochimetric Initial values are A[0] and B[0] Q= reaction quotient R=active if Q<k ----- R is reaction R=Stops if Q=k t=...- sameer990
- Thread
- Matlab Rate Reaction
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
P
MATLAB MATLAB question - meshgrid and sum.
Hello, I am asked to evaluate the following expression using functions meshgrid, sum and dot operations in MATLAB: y = Ʃ(n=1 to N) xn*[cos(x2 + n2)/xn], where x is the vector of four equally spaced values from 1 to 2, N=10. Below is my attempt (I am quite positive it's incorrect, though): n =...- peripatein
- Thread
- Matlab Sum
- Replies: 10
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
N
MATLAB How Do You Solve a Differential Equation in MATLAB?
How to do you use MATLAB to solve this? dh/dt = 0.079577-0.066169*squareroot(h) where ho = 1.75 and hf = 1.46 and to=0- ngheo1128
- Thread
- Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
E
MATLAB MATLAB 3 equations and 3 unknowns
Hello, I have never really used MATLAB before, and I was assigned some homework on it. While I was able to solve most of them, I was unable to solve this one in particular, even after searching the internet and documentation, there was many kinds that I was left confused. Does anyone know...- Elecomputer
- Thread
- Matlab Unknowns
- Replies: 2
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
MATLAB How to Create a Grid on a Map in MATLAB?
I am working on a Bachelors thesis and need to make a grid on a map over a entire floor. Can someone show me how to do this in matlab?- beyondlight
- Thread
- Grid Map Matlab
- Replies: 1
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
R
MATLAB Frisbee flight in Matlab, can't run (Input argument x is undefined)
Frisbee flight in Matlab, can't run (Input argument "x" is undefined) I'm trying to use a frisbee flight simulation made by Sarah Hummel, but I'm having a hard time running it in Matlab. I get the first message when I press run in the program and the one in red when running in the...- Readinglevelup
- Thread
- Argument Flight Matlab
- Replies: 5
- Forum: MATLAB, Maple, Mathematica, LaTeX
-
U
MATLAB How do I differentiate in MATLAB?
I find that I don't have the symbolic toolbox. Due to this, I'm not being able to differentiate by using the usual 'diff' command. However, just as one can integrate numerically, by using the quad and quadl functions, is there no way to differentiate numerically on MATLAB (like using the ab...- Urmi Roy
- Thread
- Differentiate Matlab
- Replies: 3
- Forum: MATLAB, Maple, Mathematica, LaTeX