Respondida
Creating mex file for complicated fortran code
I am not familiar with aerodyn, but you might have a look at this FEX package for generic double variable interfacing between MA...

más de 14 años hace | 0

Respondida
equality operator between matrix and scalar
You can try this to see what the numbers are exactly: num2strexact((-1:0.1:1)') Sometimes a beter way to do this is to h...

más de 14 años hace | 0

Respondida
eigen values of 3D matrix
You can try Bruno Luong's small size multi-eigenvalue solver on the FEX: <http://www.mathworks.com/matlabcentral/fileexchange...

más de 14 años hace | 2

Respondida
Segmentation Faults when Running MEX files in Parallel
Do you use any MATLAB API functions that allocate or change memory, such as mxCreateDoubleMatrix, mxMalloc, etc.? These are not ...

más de 14 años hace | 1

Respondida
Concatenate vector in a 3d matrix
For your exact problem: M = reshape([a;c;b;d],2,2,4); Then generalize as appropriate. E.g., if a,b,c,d are not row vecto...

más de 14 años hace | 1

| aceptada

Respondida
How to create a solid spherical cluster with random distribution of points
Here is my cut at it. The asin( ) correction is to take care of the fact that we need progressively fewer samples as we get ...

más de 14 años hace | 2

Respondida
problem in running mex file
Versions of MATLAB through R2006b had the BLAS and LAPACK routines in one library, the libmwlapack.lib file. Versions of MATLAB ...

más de 14 años hace | 0

| aceptada

Respondida
Simulate single precision arithmetic in Matlab?
It is very difficult to verify what is actually happening behind the scenes for single precision calculations. E.g., on a PC it ...

más de 14 años hace | 0

Respondida
floating point precision
E.g., >> X = 1 X = 1 >> Y = X + eps(X) Y = 1.0000 >> Z = X - eps(X) Z = 1.0000 >> n...

más de 14 años hace | 0

| aceptada

Respondida
Hidden memory?
To add to what Daniel has already written, consider these lines: function obj=lu_apply(A) [L,U]=lu(A...

más de 14 años hace | 2

| aceptada

Respondida
[SOLVED] compile mex with blas under windows
Drop the trailing underscore _ on Windows. E.g., #define F77_CALL(x) x ## _ puts a trailing underscore on the BLAS li...

más de 14 años hace | 1

Respondida
insert new mexPrintf to stop Matlab crash
Inserting mexPrintf calls changes the state of some internal register(s) and can have an effect on buggy code. E.g., I once saw ...

más de 14 años hace | 1

Respondida
creating multi-dimensional arrays from vectors
You can also see this related discussion: <http://www.mathworks.com/matlabcentral/answers/31594-multiply-each-element-of-a-ve...

más de 14 años hace | 1

Respondida
Absoft Pro-Fortran 10 and Matlab R2011a
To my knowledge, MATLAB has *never* shipped with a Fortran compiler. You can find a list of 3rd party supported Fortran compiler...

más de 14 años hace | 0

Respondida
How to include libraries in a mex file
What happens when you try this: #include <stdio.h> #include <math.h> #include <stdlib.h> #include <time.h> ...

más de 14 años hace | 1

Respondida
Matlab crashed
You very likely have coding errors in A.mexw32 and B.mexw32 and it is corrupting memory and causing crashes. The reason it is in...

más de 14 años hace | 1

Respondida
UTC time
If this is "seconds since 1970-01-01 00:00:00 TAI" it is more properly called "unix time" or "posix time" or sometimes "epoch ti...

más de 14 años hace | 1

Respondida
Reshaping a square matrix to a vector
This matches your words: A = rand(10,10); B = A(:); % one way B = reshape(A,100,1); % another way This matches you...

más de 14 años hace | 2

| aceptada

Respondida
Appending new dimensions to existing variable
Two options to consider: 1) Preallocate your cell array so that it is not changing size throughout your looping. Put this sta...

más de 14 años hace | 0

Respondida
Does your MATLAB FileExchange work OK?
My files seem to still be there, but the comments section has disappeared, which is unfortunate since that is how I have been ke...

más de 14 años hace | 0

Respondida
Transposing matrix using reshape
This is an ill-posed problem or something is missing from the problem statement. There are various ways to accomplish a transpos...

más de 14 años hace | 1

Respondida
C++ Mex File Clear All Memory and Dynamic Memory
Yeah, that's going to crash for sure. A couple of things: 1) prhs[0] is a read-only input. You should not be trying to free a...

más de 14 años hace | 0

| aceptada

Respondida
Add each row in a matrix with corresponding element in a vector?
bsxfun(@plus,M,V) bsxfun(@times,M,V)

más de 14 años hace | 1

| aceptada

Respondida
What version of MATLAB do you code against
32-bit Windows XP R2006b - R2011b (R2012a once I get it installed). Since all of my submissions are mex routines, I run against ...

más de 14 años hace | 1

Respondida
Multithreading with mex functions
As I understand it, the executable you plan on running is a completely separate process (is this true?), and as such there are n...

más de 14 años hace | 0

Respondida
Using ACO to determine the parameters(K,Tau)
<http://www.mathworks.com/matlabcentral/answers/29922-why-your-question-is-not-urgent-or-an-emergency>

más de 14 años hace | 1

Pregunta


Pi Day
In recognition of Pi Day (3/14 using MM/DD format), I suggest everyone eat a slice of pie today, and while you are eating it dow...

más de 14 años hace | 3 respuestas | 5

3

respuestas

Respondida
how to preallocate large logical array
Another alternative (assumes that all of the elements are filled in downstream): A = uninit(numRows, numCols, 'logical'); ...

más de 14 años hace | 1

Respondida
Program that displays the first 20 even numbers beginning with 100?
Close. But: 1) You need the mod function inside your while loop. 2) You need mod(num,2) instead of mod(x,y) 3) You don'...

más de 14 años hace | 0

Respondida
Convertion between empty matrix and Null
Why not use the isequal function?

más de 14 años hace | 0

| aceptada

Cargar más