Items tagged with matlab matlab Tagged Items Feed

Hello,

 

I have a complex set of non linear diff eqns in the form :

y1'' = f(y1',y1,y2'',y2',y2,y3'',y3',y3,y4'',....,y6'',y6',y6,u1,u2,u3,u4) ;

y2'' = f(y1'',y1',y1,y2',y2,y3'',y3',y3,y4'',....,y6'',y6',y6,u1,u2,u3,u4)

and so on ... y6''=(...)

As I want to resolve this coupled systeme in matlab using @ODE45... I wanted the equations in the form : y1''=f(y1',y1,y2',y2,....) and so on ... => X'[] = f(X[],U[])

 

How can I force maple to rearrange a system of coupled eqns with only the variables i want ?

 

I know this is possible beacause it is a nonlinear state space model but maple do not work with nonlinear state space model... It give me error when I tried to create statespace model with my non linear diff eqns.

 

Thanks a lot !

Hello

I am a student of an engineering career

The math teacher is going to ask us to solve some exercises Matlab

The teacher is very hard and explains nothing of Matlab in class

We must learn to use the program on our own viewing internet watching tutorials

I was wondering if somebody could help solve some exercises.

Are only three exercises which are imposible to me

I would appreciate it greatly.

Thank you

My e-mail :

alessagosti1@gmail.com

Environment: Maple2015, MATLAB_R2014b(MacOSX10.8.5), 2015b(MacOSX10.11.4)

MapleToolbox2015.1MacInstaller.app was successfully completed (log tells us), but when MATLAB were booted, following error messages appeared and symbolic operations of maple failed. 

This would be closely related to maple installation on MATLAB as such errors never occur for clean install of MATLABs and looks independent on OSX versions. Now javaforosx.dmg in use by instruction of Maplesoft.  Something wrong is in Maple2015. Note maple-MATLAB link works normally.

Please provide us with direction of how to fix it hopefully by Maplesoft professionals.

 

(Quote of MATLAB command window display)

Exception in thread "Startup Class Loader" java.lang.UnsatisfiedLinkError: jogamp.common.os.MachineDescriptionRuntime.getPointerSizeInBytesImpl()I

at jogamp.common.os.MachineDescriptionRuntime.getPointerSizeInBytesImpl(Native Method)

at jogamp.common.os.MachineDescriptionRuntime.getRuntimeImpl(MachineDescriptionRuntime.java:138)

at jogamp.common.os.MachineDescriptionRuntime.getRuntime(MachineDescriptionRuntime.java:124)

at com.jogamp.common.os.Platform.<clinit>(Platform.java:228)

at javax.media.opengl.GLProfile.<clinit>(GLProfile.java:83)

at com.mathworks.hg.peer.JavaSceneServerPeer.initializeJOGL(JavaSceneServerPeer.java:114)

at com.mathworks.hg.peer.JavaSceneServerPeer.<clinit>(JavaSceneServerPeer.java:100)

at java.lang.Class.forName0(Native Method)

at java.lang.Class.forName(Class.java:190)

at com.mathworks.mde.desk.StartupClassLoader.loadClass(StartupClassLoader.java:258)

at com.mathworks.mde.desk.StartupClassLoader.access$900(StartupClassLoader.java:25)

at com.mathworks.mde.desk.StartupClassLoader$2.run(StartupClassLoader.java:244)

at java.lang.Thread.run(Thread.java:745)

>> maple();

error: maple (line 178)

Invalid MEX-file '/Applications/MATLAB_R2014b.app/toolbox/maple/maplemex.mexmaci64':

dlopen(/Applications/MATLAB_R2014b.app/toolbox/maple/maplemex.mexmaci64, 6): Symbol not found: ___sincos_stret

  Referenced from: /Library/Frameworks/Maple.framework/Versions/2015/bin.APPLE_UNIVERSAL_OSX/libhf.dylib

  Expected in: /usr/lib/libSystem.B.dylib

 in /Library/Frameworks/Maple.framework/Versions/2015/bin.APPLE_UNIVERSAL_OSX/libhf.dylib

>> syms x  y

error: sym (line 186)

Invalid MEX-file '/Applications/MATLAB_R2014b.app/toolbox/maple/maplemex.mexmaci64':

dlopen(/Applications/MATLAB_R2014b.app/toolbox/maple/maplemex.mexmaci64, 6): Symbol not found: ___sincos_stret

  Referenced from: /Library/Frameworks/Maple.framework/Versions/2015/bin.APPLE_UNIVERSAL_OSX/libhf.dylib

  Expected in: /usr/lib/libSystem.B.dylib

 in /Library/Frameworks/Maple.framework/Versions/2015/bin.APPLE_UNIVERSAL_OSX/libhf.dylib

 error: sym (line 56)

           assignin('caller',varargin{i},sym(varargin{i})); 

(Unquote)

 

 

 

Hello all,

here the programme I think there are some mistakes couldnot know where please any comment will be helpful:

# Firstly, set the size limit for the grid, which shall define how many
# points there are in both the vertical and horizontal direction
size=40;
# limit is a variable used to set an unobtainable upper bound
limit=size+1;
# x defined, starting at 1, and two other variables ud (upper diagonal) and
# dd (downward diagonal) begin at 0. All three are used to iterate through
# line creation

x=1;
ud=0;
dd=0;
# Iteration through x, using the line function to create a number of
# horizontal lines up to the limit point

while(x<(limit))
line([0, size], [x, x]);
x=x+1;
end

# Now iterating through the diagonals pointing upwards, using two sets of
# lines, both starting from the line going through the origin. The first
# iterates through the lines that pass through positive x values at y=0,
# the second iterates through the lines passing through negative x values
# at y=0
# ud must be increased by 2 each time to ensure that equilateral triangles
# are formed.

while(ud<(limit))
line([(ud), (size)], [0, (size-ud)]);
line([0, (size-ud)], [(ud), (size)]);
ud=ud+2;
end

# Similar to before, except this time iterating through downward pointing
# diagonals.

while(dd<(limit))
line([(dd), 0], [0, (dd)]);
line([(size), (dd)], [(dd), (size)]);
dd=dd+2;
end

# xvector and yvector set up as two vectors holding x and y co-ordinates of
# points respectively.

xvector = zeros(1, limit);
yvector = zeros(1, limit);

# Reinitiallising x and y values for iterative purposes.

x=0;
y=0.5;
n=1;

# The program now iterates through potential y values for the potential
# points. Then it tests the value of y to see what orientation the lattice
# is at that point, then randomly selects x values to enter, iterating
# between all the possible x values in the orientation before moving on to
# the next y value.

while(y<size)
if(mod(y,1)==0.5)
x=0.5;
while(x<size)
z=rand;
if(z>0.5)
xvector(n) =x;
yvector(n) =y;
n=n+1;
end
x=x+1;
end
elseif(mod(y,2)==1)
x=0;
while(x<size)
z=rand;
if(z>0.5)
xvector(n) =x;
yvector(n) =y;
n=n+1;
end
x=x+2;
end
else
x=1;
while(x<size)
z=rand;
if(z>0.5)
xvector(n) =x;
yvector(n) =y;
n=n+1;
end
x=x+2;
end
end
y=y+0.5;

end

# The program then enters the two co-ordinate vectors saved previously into
# the scatter function.

hold;
scatter(xvector, yvector);

Is this what is supposed to happen when linking Maple to Matlab?  I was hoping it would open the actual Matlab program and write variables to the current worksheet.  I'm I missing something?

Nothing even pops up on the Matlab Command window. What good is this?

 

Hi guys,
I want to import symbolic matrix from matlab to Maple, How I can do that ? 


Hey,

I wonder if there is an operator to skip inputs and outputs of functions. Consider this example:

The output would be:

However my system is much bigger and I only need the second output of the command and I dont want to waste memory on the first.

In Matlab I would write

~,ans := GenerateMatrix(...)Is there a similar shortcut availible in Maple?

 

Thanks in advance!

 

Hello all,

I am pretty new to Maple, but I am trying to understand something. I was able to find a numerical solution to a PDE in maple (with some community help, thanks guys!). I am trying to manipulate this data but am struggling with it. I thought if I could take this data to matlab it would be pretty easy for me to manipulate and do what I want. 

So my question is: How do I export my numerical solution (pds module) to matlab. Just taking the data is okay. I know you can evaluate the data at some points. 

 

I see there is "Matlab" command that converts code, it doesn't seem to like pds as an input though.

I also see an export matrix command. I guess it could be possible to create a matrix of plot data and convert it this way?

 

I had to do a change of coordinate system to solve the PDE because of boundary conditions. I'm trying to transform this data back to my regular x,y coordinate system to see if it matches some other simulations. 

Thanks in advance! And here is my file.


restart;
with(Physics):
Setup(mathematicalnotation = true):

V(Z, f);

If function ( varphi) is defined, use this one.

PDE1 := subs[inplace](x = xi*varphi(t), PDE1);
If function ( varphi) is defined, use this one.


PDE1 := subs[inplace](t = 2*vartheta*(1/omega), PDE1);


 

 

 

 

 

 

Thesis_Pde2_attempt.mw

                                                                                 

Hi everybody,

I have some experimental data from an oscillating system (time domaine) and I would like to get an approximation of the damping ratio (zeta). I have already try to use the half-power band width method with the vibrationdata Matlab package designed by Tom Irvine. But I would like to double-check the result with another method.

I found several methods in this paper and I would like to try to do the curve fitting method with the Curve Fitting Toolbox of Maple or Matlab (R2014b) (2.2.2 Curve fitting in the paper). data.txt

It's the first I use this Toolbox with a custom equation, so, I do not really know how to do it with my sample data.

Can anybody help me with this ? I have attached the .txt file sample data to this post.

Cheers

Dear all, I have obtained some figures in Maple code. But they looks not very good. Iwant to export the plot data to matlab. Then try to plot in matlab. I think it should't be very hard. Does anyone can help me? Thanks

Hello

Is there any option for impoting MATLAB's variables eith struct format (*.mat)?

Could you please to help me!

Thank you.

 

Good Day Everybody, I m new to maple and would like to translate the following for loop from Matlab to Maple. The FromMatlab Translater didnt work for this expression related to the matrix Q, A, B D and A1. Any help would be greatly appreciated.

Related Matlab Code:

...

Q(3,3)=2*Q(3,3);

 for i=1:length(R)

    T(1,1)=cos(R(i))^2; 

    T(2,2)=cos(R(i))^2; 

    T(1,2)=sin(R(i))^2; 

    T(2,1)=sin(R(i))^2; 

    T(3,1)=-sin(R(i))*cos(R(i)); 

    T(3,2)=sin(R(i))*cos(R(i)); 

    T(1,3)=2*sin(R(i))*cos(R(i)); 

    T(2,3)=-2*sin(R(i))*cos(R(i)); 

    T(3,3)=cos(R(i))^2-sin(R(i))^2;

    T1(1,1)=cos(R(i)); 

    T1(1,2)=-sin(R(i)); 

    T1(2,1)=sin(R(i)); 

    T1(2,2)=cos(R(i));

    

    Qk(:,:,i)=inv(T)*Q*T; 

    Qk(:,3,i)=Qk(:,3,i)/2; 

    Qk1(:,:,i)=inv(T1)*Q1*T1;

    A=A+Qk(:,:,i)*(h(i+1)-h(i)); 

    B=B+.5*Qk(:,:,i)*(h(i+1)^2-h(i)^2); 

    D=D+1/3*Qk(:,:,i)*(h(i+1)^3-h(i)^3); 

    A1=A1+Qk1(:,:,i)*(h(i+1)-h(i));

end

Thanks a lot in advance.

Hello people

i have a quetion

what is the perposes of these softwares,maple,matlab,mathmatica and latex.

for example i listened from somewhere that matlab is best for matrices, then what are the major task of these softwares which i listed above including matlab,

how we make comparison of these softwares.

thanks

 

Is there a way to convert this FDTD code into Maple

Hy(1 to M)=0;

Ex(1 to M+1)=0;

For t=1 to T,

Ex(1)=exp(-t);

For k=1 to M,

Hy(k)=Hy(k)-(Ex(k+1)-Ex(k));

end

For k=2 to M,

Ex(k)=Ex(k)-(Hy(k)-Hy(k-1));

end

end

Thanks in advance.

Hello,

From a simulation software, I obtain in a matlab file my differential equations in the following way :

C_p_e = C_state/C_c;
C_p_f = I_state/I_i;
R_p_e = R_r*C_p_f;
I_p_e = (Se_p_e-R_p_e)-C_p_e;

For theses expressions, I would like to do two operations :
1) Transform it into equations
2) Conduct substitutions so as to change the names of the variables with nicer names.

For this objectives, I could do with the following code:

restart;
eq1:=C_p_e = C_state/C_c;
eq2:=C_p_f = I_state/I_i;
eq3:=R_p_e = R_r*C_p_f;
eq4:=I_p_e = (Se_p_e-R_p_e)-C_p_e
allsubs:= proc(XX )
subs(C_p_e=fs(t),C_p_f=v(t),R_p_e=fd(t),I_p_e=fm(t),C_c=1/k,I_i=m,R_r=c,Se_p_e=fe(t),I_state=int(fm(t),t),C_state=int(v(t),t),XX)
end proc:
eq1_a:=allsubs(eq1);
eq2_a:=allsubs(eq2);
eq3_a:=allsubs(eq3);
eq4_a:=allsubs(eq4);

Now, I would like to automatisation the creation of the equations eq1, eq2, eq3, eq4. For the moment, to create these equations, I have done copy/ paste from matlab.

But, I would like to create these equations eq1, eq2, eq3, eq4 with a automative process from my matlab equations. The reason comes from the fact that I would like to make the same work on bigger system which are composed with numerous equations.

How can I create equations labeled eq1, ...eqn from a list of expressions from matlab ?

Thank you for your help

1 2 3 4 5 6 7 Page 1 of 7