Beantwortet
Run two functions in parallel
H Francesco, it depends on if function 1 is interuptible. You could try to run function 2 using the function "timer": create ...

mehr als 14 Jahre vor | 1

Beantwortet
Parallel Toolbox: some doubts
Hi, regarding 1): The default is usually indeed a good default: adding more workers usually only compete against each others ...

mehr als 14 Jahre vor | 1

Beantwortet
Matlab Coder entering varying size input
Hi Dan, if you use the MATLAB Coder tool for compiling, you specify the size of input either e.g. as :10 x 1 (if n always sma...

mehr als 14 Jahre vor | 0

| akzeptiert

Beantwortet
How to load pre-calculated matrix value in a file into Simulink for simulation ?
Hi Tom, if it is a constant matrix I would do the following: add the load command to the preload function of the model (menu ...

mehr als 14 Jahre vor | 2

| akzeptiert

Beantwortet
How to load pre-calculated matrix value in a file into Simulink for simulation ?
Hi Tom, I would use the From File block to directly work with the matrix in the file. You would just need to make sure it has...

mehr als 14 Jahre vor | 0

Beantwortet
Find the row of a word in a file
Hi, something like the following should do the trick fid = fopen('yourtextfile.txt', 'rt'); % read the entire file, i...

mehr als 14 Jahre vor | 2

| akzeptiert

Beantwortet
mysql&MATLAB
You could use the database toolbox, see <http://www.mathworks.com/products/database here>. Titus

mehr als 14 Jahre vor | 1

Beantwortet
Regarding the size of matrix that Matlab can handle
Hi, it depends on version and operating system: on a 32Bit OS this will definetely fail, because the matrix would need about ...

mehr als 14 Jahre vor | 0

| akzeptiert

Beantwortet
Size and position of command window on screen
Hi Joseph, if you only want to use the command window you might just start MATLAB without the desktop matlab -nodesktop ...

mehr als 14 Jahre vor | 0

Beantwortet
property access of objects arrays
Hi Johhny, the [] work here similar to accessing a field of a structure. There it is easy to explain using "comma seperated l...

mehr als 14 Jahre vor | 0

Beantwortet
coverting to c code
Hi Rajesh, just to confirm: I guess you invoke coder by coder -build pca.prj instead of "-new"? I just gave it anothe...

mehr als 14 Jahre vor | 0

Beantwortet
Making cpp code from Mfile.
Hi Jan, I would suggest to run the example from the MATLAB compiler section named "Libraries". Somewhere comes the call to mb...

mehr als 14 Jahre vor | 0

Beantwortet
select random pixels
Hi, randperm should help you, here some (non tested) example code: % let A be the image (either NxM or NxMx3): % numb...

mehr als 14 Jahre vor | 0

Beantwortet
how to control my datetick() axes
Hi, take a look at the parameters for datetick. I guess the "keeplimits" is what you are looking for. For the second questio...

mehr als 14 Jahre vor | 0

| akzeptiert

Beantwortet
run s-function in mfile
Hmm, there is indeed not much to be done: the function header of an S-function looks like this: [sys,x0,str,ts,simStateComp...

mehr als 14 Jahre vor | 0

Beantwortet
add a new column into a database
Hi, if you take a look at a.Message, do you see an error message from the database server? Titus

mehr als 14 Jahre vor | 0

Beantwortet
run s-function in mfile
Hi, it depends. Level-1 S-functions in MATLAB are just simple MATLAB functions. If you call with the correct input parameters...

mehr als 14 Jahre vor | 0

Gelöst


Differential equations I
Given a function handle |f| an initial condition |y0| and a final time |tf|, solve numerically the differential equation dy...

mehr als 14 Jahre vor

Gelöst


Math with Roman Numerals
Given a function R within (+,-,*,/) and two Roman numerals a & b, compute aRb in Roman numerals.

mehr als 14 Jahre vor

Gelöst


Pizza!
Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

mehr als 14 Jahre vor

Beantwortet
how can I remove duplicate objects (not integers) from an array?
Hi, something like this? x = [Quote Quote Quote]; x(1).ShareName = 'foo'; x(2).ShareName = 'bar'; x(3).ShareN...

mehr als 14 Jahre vor | 1

| akzeptiert

Gelöst


Count from 0 to N^M in base N.
Return an array of numbers which (effectively) count from 0 to N^M-1 in base N. The result should be returned in a matrix, with ...

mehr als 14 Jahre vor

Gelöst


Sorted highest to lowest?
Return 1 if the input is sorted from highest to lowest, 0 if not. Example: 1:7 -> 0 [7 5 2] -> 1

mehr als 14 Jahre vor

Gelöst


The Hitchhiker's Guide to MATLAB
Output logical "true" if the input is the answer to life, the universe and everything. Otherwise, output logical "false".

mehr als 14 Jahre vor

Gelöst


Too mean-spirited
Find the mean of each consecutive pair of numbers in the input row vector. For example, x=[1 2 3] ----> y = [1.5 2.5] x=[1...

mehr als 14 Jahre vor

Gelöst


How to find the position of an element in a vector without using the find function
Write a function posX=findPosition(x,y) where x is a vector and y is the number that you are searching for. Examples: fin...

mehr als 14 Jahre vor

Gelöst


Remove the vowels
Remove all the vowels in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill' Output s2 is 'Jck nd Jll wn...

mehr als 14 Jahre vor

Gelöst


Is my wife right?
Regardless of input, output the string 'yes'.

mehr als 14 Jahre vor

Gelöst


Swap the first and last columns
Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

mehr als 14 Jahre vor

Gelöst


Fibonacci sequence
Calculate the nth Fibonacci number. Given n, return f where f = fib(n) and f(1) = 1, f(2) = 1, f(3) = 2, ... Examples: Inpu...

mehr als 14 Jahre vor

Mehr laden