Answered

Solving coupled system of second order differential equations symbolically

Like the Greek godess used to say: Just do it!: y'' = k/m * y + w/m * z, z'' = J/I * z + w/I * y, syms t syms y(t) z(t) syms...

Solving coupled system of second order differential equations symbolically

Like the Greek godess used to say: Just do it!: y'' = k/m * y + w/m * z, z'' = J/I * z + w/I * y, syms t syms y(t) z(t) syms...

3 månader ago | 0

| accepted

Answered

Convert netcdf time ('minutes since 2013-2-1 00:00:00') to actual date

Remember that datenum is in (fractional) days, while your netcdf-time is in minutes. It seems likely that you want to do: t1 = ...

Convert netcdf time ('minutes since 2013-2-1 00:00:00') to actual date

Remember that datenum is in (fractional) days, while your netcdf-time is in minutes. It seems likely that you want to do: t1 = ...

3 månader ago | 1

Answered

Solve systems of equations graphically

You can start investigating the surfaces of the functions f1(x,y) = x.^2+y.^2-29 and f2(x,y) = y.^2-4*x.^2-9 with something like...

Solve systems of equations graphically

You can start investigating the surfaces of the functions f1(x,y) = x.^2+y.^2-29 and f2(x,y) = y.^2-4*x.^2-9 with something like...

3 månader ago | 0

Answered

ODE45 outputs only zeros

When you have discontinuities in the ODEs (the derivative of command) then the safe approach is to separate the integration into...

ODE45 outputs only zeros

When you have discontinuities in the ODEs (the derivative of command) then the safe approach is to separate the integration into...

3 månader ago | 0

| accepted

Answered

Unable to perform assignment because the left and right sides have a different number of elements.

It appears because you try to squeeze in/stretch out an array with some number of elements into different number of elements of ...

Unable to perform assignment because the left and right sides have a different number of elements.

It appears because you try to squeeze in/stretch out an array with some number of elements into different number of elements of ...

3 månader ago | 1

Answered

how to load mutiple mat files which has names in 'YYYYMMDD.mat' format?

You could do something like this, provided you have the filenames-of-interest: for iFiles = numel(dataFiles):-1:1 Sloaded{i1...

how to load mutiple mat files which has names in 'YYYYMMDD.mat' format?

You could do something like this, provided you have the filenames-of-interest: for iFiles = numel(dataFiles):-1:1 Sloaded{i1...

3 månader ago | 0

| accepted

Answered

3 Differential equation using 4th order runge kutta

You have a function for a 2-D system of ODEs. That then is messed up: function diffeqs =ode_Q10(t,var) % t = var(1); % This ov...

3 Differential equation using 4th order runge kutta

You have a function for a 2-D system of ODEs. That then is messed up: function diffeqs =ode_Q10(t,var) % t = var(1); % This ov...

3 månader ago | 1

| accepted

Answered

Rotation Matrices - omega phi kappa vs yaw pitch roll

If you have mixed up the order of the rotations you might step through the different combinations of rotations and sign-conventi...

Rotation Matrices - omega phi kappa vs yaw pitch roll

If you have mixed up the order of the rotations you might step through the different combinations of rotations and sign-conventi...

3 månader ago | 0

Answered

How can I perform large sparse matrix multiplication efficiently when one sparse matrix is block diagonal?

Shouldn't straight summation be preferable for the calculations of sums rather than doing it by way of matrix multiplication. Pe...

How can I perform large sparse matrix multiplication efficiently when one sparse matrix is block diagonal?

Shouldn't straight summation be preferable for the calculations of sums rather than doing it by way of matrix multiplication. Pe...

3 månader ago | 0

Answered

How can I convert deformation data into FRF using FFT?

Simply use fft? That will give you the complex discrete Fourier-transform. If you do: fS = fft(S); % fS will have "DC"-componen...

How can I convert deformation data into FRF using FFT?

Simply use fft? That will give you the complex discrete Fourier-transform. If you do: fS = fft(S); % fS will have "DC"-componen...

3 månader ago | 0

| accepted

Answered

How to differentiate between an index and a value in a function?

Your function J expects a single input as defined. I get: J_0 = J(x_0); to run without problems... HTH

How to differentiate between an index and a value in a function?

Your function J expects a single input as defined. I get: J_0 = J(x_0); to run without problems... HTH

3 månader ago | 0

Answered

Looping through 4 Images that have fixed names

You can for example put the filenames into a cell-array: imFileNames = {'im1.jpg','im2.png','im3.jpeg','im5.tiff'}; Then you c...

Looping through 4 Images that have fixed names

You can for example put the filenames into a cell-array: imFileNames = {'im1.jpg','im2.png','im3.jpeg','im5.tiff'}; Then you c...

3 månader ago | 0

| accepted

Answered

Why am i getting this error message? "Array indices must be positive integers or logical values."

In matlab (and most other programming-languages) you will have to write out the multiplication-operator (* for matrix multiplica...

Why am i getting this error message? "Array indices must be positive integers or logical values."

In matlab (and most other programming-languages) you will have to write out the multiplication-operator (* for matrix multiplica...

3 månader ago | 1

| accepted

Answered

Does anyone have the periodic cubic spline codes in matlab?

You will find plenty of examples of spline-tools with different levels of support for periodic boundary-conditions on the file e...

Does anyone have the periodic cubic spline codes in matlab?

You will find plenty of examples of spline-tools with different levels of support for periodic boundary-conditions on the file e...

3 månader ago | 0

Answered

Multiply two griddedInterpolant functions

If you have 2 functions f(x,y) and g(x,y) you can evaluate the product on your selected grid-points and multiply them: fx_at_xy...

Multiply two griddedInterpolant functions

If you have 2 functions f(x,y) and g(x,y) you can evaluate the product on your selected grid-points and multiply them: fx_at_xy...

3 månader ago | 0

| accepted

Answered

History function for ODE45

Since ode45 solves systems of first-order differential equations on the standard form the history does not matter, so I've never...

History function for ODE45

Since ode45 solves systems of first-order differential equations on the standard form the history does not matter, so I've never...

3 månader ago | 1

| accepted

Answered

how to plot two different plots with different axis in a single graph?

Have a look at the documentation and help for yyaxis. There you should find illustrating examples doing what you want. Possibly ...

how to plot two different plots with different axis in a single graph?

Have a look at the documentation and help for yyaxis. There you should find illustrating examples doing what you want. Possibly ...

3 månader ago | 0

| accepted

Answered

How to write a code for plotting a Poincare map for the analysis of a double pendulum and also How to simulate the motion of the double pendulum.

You will find a couple of contributions on the file exchange for Poincare-maps, the first seems promising: FEX-hits on "poincare...

How to write a code for plotting a Poincare map for the analysis of a double pendulum and also How to simulate the motion of the double pendulum.

You will find a couple of contributions on the file exchange for Poincare-maps, the first seems promising: FEX-hits on "poincare...

3 månader ago | 0

Answered

area of water body in a grey color image

If the water-surface are flatter than the not-water-surfaces (seems reasonable assumption for standard optical satellite imaging...

area of water body in a grey color image

If the water-surface are flatter than the not-water-surfaces (seems reasonable assumption for standard optical satellite imaging...

3 månader ago | 0

Answered

solve a complex second order differential equation

The first step is to convert your second-order ODE to two coupled first-order ODEs: Then you should write that ODE-system as ...

solve a complex second order differential equation

The first step is to convert your second-order ODE to two coupled first-order ODEs: Then you should write that ODE-system as ...

3 månader ago | 0

| accepted

Answered

2D Minimization problem, not good for fminsearch?

For problems like these (It seems likely that your function has multiple local minima or at least very very flat regions) the be...

2D Minimization problem, not good for fminsearch?

For problems like these (It seems likely that your function has multiple local minima or at least very very flat regions) the be...

3 månader ago | 0

Answered

Error using * Incorrect dimensions

For problems like these you should learn to run the code line-by-line at the command-line prompt. Then check the size and type o...

Error using * Incorrect dimensions

For problems like these you should learn to run the code line-by-line at the command-line prompt. Then check the size and type o...

3 månader ago | 0

Answered

Can someone please drop the code for ICA( independent component analysis) for image segmentation on matlab for classifying thermal images

Look on the file exchange for ICA-implementations: ICA at FEX Get fastICA from the/(a significant) source: FastICA Then the ma...

Can someone please drop the code for ICA( independent component analysis) for image segmentation on matlab for classifying thermal images

Look on the file exchange for ICA-implementations: ICA at FEX Get fastICA from the/(a significant) source: FastICA Then the ma...

3 månader ago | 0

Answered

Integer eigenvalues in Matlab

Since you have a matrix and want the eigenvalues then the best approach seems to be to actually calculate the eigenvalues. For t...

Integer eigenvalues in Matlab

Since you have a matrix and want the eigenvalues then the best approach seems to be to actually calculate the eigenvalues. For t...

3 månader ago | 0

Answered

How to solve simultaneous equations?

Using symbolic tools you have solve - look at the help and documentation for that function for examlpes. Your problem should red...

How to solve simultaneous equations?

Using symbolic tools you have solve - look at the help and documentation for that function for examlpes. Your problem should red...

3 månader ago | 0

Answered

How to extract data from a function or functions. Also how to export this data to excel.

Your functions have their own name-space where the variables that are defined exists (in addition to the input variables that yo...

How to extract data from a function or functions. Also how to export this data to excel.

Your functions have their own name-space where the variables that are defined exists (in addition to the input variables that yo...

3 månader ago | 2

| accepted

Answered

how to Solve 4 Equation and 3 unknown

When you have four non-linear equations with three unknowns you cannot, in general, expect to get a symbolic solution. For these...

how to Solve 4 Equation and 3 unknown

When you have four non-linear equations with three unknowns you cannot, in general, expect to get a symbolic solution. For these...

4 månader ago | 0

| accepted

Answered

fitting data to system of ode

You will find the answer to this problem in a link to yet another answer (by Star Strider) here: fit-a-parameterised-ode-solutio...

fitting data to system of ode

You will find the answer to this problem in a link to yet another answer (by Star Strider) here: fit-a-parameterised-ode-solutio...

4 månader ago | 0

| accepted

Answered

How to solve differential equations with varying constants

For the case you describe you have to add information about how X and p varies with time. Are they constant over some fixed inte...

How to solve differential equations with varying constants

For the case you describe you have to add information about how X and p varies with time. Are they constant over some fixed inte...

4 månader ago | 0

Answered

What should go in a next-generation MATLAB X?

Allow elementary mathematical operations on function-handles. So instead of writing the sum of two functions as: f1 = @(x) x.^2...

What should go in a next-generation MATLAB X?

Allow elementary mathematical operations on function-handles. So instead of writing the sum of two functions as: f1 = @(x) x.^2...

4 månader ago | 0