Rouben Rostamian

MaplePrimes Activity


These are replies submitted by Rouben Rostamian

@Carl Love That proc may be useful for something but it goes against the OP's requirement of "without having to ... keep the command prompt busy in Maple".

This doesn't answer your question but it accomplishes what appears to be your objective:

restart;
vars   := [a, b__c, t[1]];
assign(vars =~ [$1..3]);

 

@acer Thanks for noting the {`+`,`*`}.  Somehow I had assumed (incorrectly) that the ts option to frontend supplements the default `+`,`*`.  It is clear now that it overrides it.

 

@acer That's a collection of good ideas. Vote up!

The OP needs to be aware, however, that although frontend() works in this case, it is not a universal solution.  For instance,

frontend(diff, [x(t)^2 + sin(x(t)), x(t)]);

yields 2 x(t), which is not what is expected.  This can be fixed by giving an extra option to frontend, as in

frontend(diff, [x(t)^2 + sin(x(t)), x(t)], [{},{sin}]);

which produces the correct result, but even that is not fool-proof as seen in:

frontend(diff, [x(t)^2 + sin(x(t)+y(t)), x(t)], [{},{sin}]);

which yields the incorrect result 2 x(t).  Perhaps that too can be fixed by providing additional options to frontend but I don't see how right now.

 

@andmail This proc, which returns the area of any polygon, may be of use to you.

restart;

This proc returns the area of an n-gon whose vertices are given
as a list of lists L = [[x__1, y__2], () .. (), [x__n, y__n]] or as a list of vectors

"L=[ <`x__1`,`y__1`>, ..., <`x__n`,`y__n`> ]."  It is assumed that
  the vertices are listed in the counterclockwise order,
  the n-gon does not self-intersect.

polygon_area := proc(L)
  local n := nops(L);
  add(L[i][1]*L[i+1][2] - L[i][2]*L[i+1][1], i=1..n-1)
   + L[n][1]*L[1][2] - L[n][2]*L[1][1];
  return %/2;
end proc:

Example: The area of a rectangle

polygon_area([[0,0],[1,0],[1,5],[0,5]]);

5

Example: The area of a regular pentagon

polygon_area([<cos(2*Pi/5*i), sin(2*Pi/5*i)> $i=1..5]):
convert(simplify(%), radical);

(5/8)*2^(1/2)*(5+5^(1/2))^(1/2)

Download mw.mw

 

@HaHu Do this

plot([x^2, 1-x^2], x=0..1, color=[red,green], legend=[supply, demand]);

@acer I have been interested in coloring spacecurves but I haven't figured out a good way of doing that.  What you have suggested is very helpful.  Additionally, I would like to learn how to colorize a curve based on its parametric representation.  Earlier in this thread you referred to an older discussion where you do that but the illustration there is too complicated for me to grasp the underlying idea.  Would you be able to provide a simpler example of doing that?  For instance, let's take the spacecurve

with(LinearAlgebra):
C := <cos(t), 2*sin(t), t^2/20>;
C1, C2 := diff(C,t), diff(C,t,t);
kappa := Norm(CrossProduct(C1,C2),2) / Norm(C1,2)^3; # curvature

How do we color C over the range 0 < t < 2*Pi according to the curvature kappa? It will be illuminating to see how that is done.

 

@Earl Yes, normals to two smooth (i.e. differentiable) surfaces at their point of tangency are always collinear.  That's a consequence of the following two definitions.

  1. Definition: Two smooth surfaces are tangent to each other at a common point P if their tangent planes at P coincide. 
  2. Definition: A normal vector to a smooth surface at a point P is a (nonzero) vector which is perpendicular to the tangent plane at P.

Show what you did to get a solution that looks like a step function.

In general, it is a good idea to upload a worksheet to show your work rather than saying something vague like "it didn't work".

 

People here will be happy to help with you with problems that you encounter in using Maple, but they are not here to do your homework problems for you.

Show what you have done so far, and point out where you need help.

 

Your calculation shows that KdV_f has a term with the fifth derivative of f with respect to x, but your target equation has at most the fourth derivative.  Are you sure that you are looking at the right thing?

 

@suvetha2000 I expect that the solution that I have shown to gain all 3 marks on Qs1ci.

As to Qs1Cii, the solution is more of a conceptual type rather than computational.  It is possible to use Maple to express some of the concepts however that use is really superfluous since you will need to work out the answer in your head anyway.

 

 

@suvetha2000 If you are asked to take someone's picture and you take a picture of the back of their head, that's not wrong, but that's not quite what is expected. In that same sense, your graphs are not wrong, but they miss the interesting region of activity.  If I were to mark that work, I would give 1 out of 3 points.

 

There are various ways of building flexibility in an essentially one-dimensional object which would be the curve of descent.  The simplest models are those of the Euler beam (from the 1700s) and the Timoshenko beam (from the early 1900s) each of which leads to a fourth order linear partial differential equation (see their respective entries in Wikipedia).  Neither of these is suitable for the problem that you have posed since they are valid only under infinitesimal displacements.

The theory of finite deformation of one-dimensional structures is called rod theory and is quite complex. Stuart Antman's article, The Theory of Rods, has a detailed exposition.  The equations are heavily nonlinear and I am afraid too involved for an elementary optimization analysis.
 

Thanks, acer, for this very useful option.  It's good enough to be merged into the future releases of Maple.

 

First 39 40 41 42 43 44 45 Last Page 41 of 99