tomleslie

5204 Reputation

15 Badges

9 years, 246 days

MaplePrimes Activity


These are answers submitted by tomleslie

Try this

profit.mw

 

@krismalo 

Using default (ie cubic) spline curve fitting, the following works

  restart;
  with(CurveFitting):
  xlist:= [150, 250, 500, 800, 1300, 2500, 5000]:
  ylist:= [.3, .5, .8, 1.0, 1.2, 1.4, 1.6]:
#
# Define a function to retiurn y-value for given x
#
  gety:= unapply( Spline([seq([xlist[j], ylist[j]], j=1..7)], x), x):
#
# Define a function to retiurn x-value for given y
#
  getx:= unapply( Spline([seq([ylist[j], xlist[j]], j=1..7)], y), y):
#
# Compute the y-value for say x=3000
#
  gety(3000);
#
# Check that previous result corresponds to the supplied x-value
# (near enough!)
#
  getx(%);

Not sure I understand the problem - if I change your final command to

CodeTools:-Usage( plot([f1,u21], 0..10, adaptive=false, axes=none, numpoints=200,labels=[x,u],legend=["t=0","t=0.2"],color=[green,red]) )

then two curves are plotted -one of which shows that your "double integral" is more or less identically zero.

So what exactly is your issue???

the variable Et whose entries you wish to solve for may seem to be a column vector, but is actually a matrix - so Et[1] returns the first 'row' of the matrix as a vector. If you want the first entry, you need to use Et[1][1].

ie

solve(Et[1][1], Q[1])

returns -36949.67738  

plot( sum(0.5^(n), n=1..x), x=0..10 );

Could someone explain what are the main (functional) differences.

I agree with Carl - there are none

On the other hand, if you ever want to make any money out of what you do with Maple (aka commercial use), then you really shoul have a "professional" edition

You might also find an issue with upgrades?

If you were to do this with pencil and paper, then you would proceed by comparing Matrix elements in your final expression. No other option is possible. So the question becomes - how close can I get to this process in Maple?

How about

restart;
A:=Matrix(3,3, (i,j)->a[i,j](t)):
B:=Matrix(3,3, (i,j)->b[i,j](t)):
C:=LinearAlgebra[Transpose](A).B:
ArrayTools[IsEqual]( diff~(C,t),
                     diff~(LinearAlgebra[Transpose](A),t).B+LinearAlgebra[Transpose](A).diff~(B,t)
                   );

whihchwill return true!

So far as I can tell the equations you give in polar coordinates do not correspond to those given in Cartesian cooordinates.

See attached.

deCC.mw

In maple 2015.1, the script

restart;
with(Units[Standard]):
1.0*Unit(volt)/(2000.0*Unit(ampere));

ought to provide output with units of ohms (indicated by a capital omega)

I do not know any way to force the display to use "engineering" notation

 

Adding a couple of simple commands to the end of your original worksheet, I come up with the following

_C3=0,
_C2 is arbitrary
_C1=-2*_C2*s+2/s

see attached.

LGMsol.mw

As in

#
# Generate the expression and save it to a txt file
# because the file extension is .txt, then this file
# will be human-readable
#
   f:=x^2;
   f1:=diff(f,x);
   save f1, "J:/Users/TomLeslie/savetest.txt";
#
# Wipe the previous info, check f1 to make sure it
# has been cleared, then read it from the file and
# check again
#
   restart;
   f1;
   read "J:/Users/TomLeslie/savetest.txt":
   f1;

Obviously you wiill have to change the pathName/filename in the above commands to something appropriate for your machine

Assuming that you want to import data from Excel ranges to and assign these to "sensible" Maple names, consider the attached (contains a lot of step by step comments)

XLimport.mw

Well actually , as far as Maple is concerned, you hav 32 "variables". You seem to thing that Maple can telll the difference between "variablles" and "paramters" with no guidance. Trust me, this is not going to happen!!

You have 32 unknowns and 6 equations, which essentially means that you can pick any 6 unknowms and solve for these in terms of the other 26. The attached woksheet shows one possibility

elimPoob.mw

I'm not exactly sure what you want because your question is too general.

However tha attached file computes

  1. the "exact" solution,
  2. the "approximate" solution ( using a method with which I am unfamilar)
  3. graphs the difference,
  4.  computes the differnce between the exact an the approximate solution at a few points

I'm not sure if this covers your requirements or not - maybe if you can clarify in some way???

VIMdebug1.mw

File extension should be .mpl

If I run

restart;
read "J:\\Users\\TomLeslie\\testproc.mpl"
create({{a, b}, {b, c}, {b, d}});

where testproc.mpl is

create := proc (data::set)
                        local G;
                        with(GraphTheory);
                        G := GraphTheory:-Graph(data);
                        printf("My Graph is %a", G);
                        save G, "J:\\Users\\TomLeslie\\graph.txt":
              end proc:

Then the file graph.txt appears where I would expect it to.

Before trying the above you will have to change the path names back to those relevant for your machine

 

First 106 107 108 109 110 111 112 Last Page 108 of 116