## How to simplify certain terms of it?...

hi,

here a comlicated formula,how i simplify

thanks  a lot.

 >
 (1)
 >
 (2)
 >

f is a complicated function,i want to make it more simplify,but i want to keep square style,

let coefficients of X and Y keep one unit,and simplify terms  containd special symbol of omega

it what i wanted.

## Word command for square?...

The word command for square root is sqrt.  What is the word command for square?  How to square all the values in a list?

## Exponentiation in the Physics package...

I ran into a problem with the physics package that I subsequently solved. But I am wondering whether this would be a candidate for an SCR and/or be considered a bug.

The calculation I am trying is actually (so far) very simple.

I define a Hamiltonian H:

H := sqrt(p_^2*c^2+m^2*c^4); # note the square of vector p_

p_:=p1*_i+p2*_j+p3*_k;

H;

So far so good. Now I want to take the differentials of H against the components of p:

diff(H,p1) assuming c::real;

Hmm... I am not sure why the p2 and p3 still show up; but then, the product between the unit vectors should be 0 for different ones and one for equal unit vectors so maybe this is ok.

But H behaves weird: I can simplify it:

but if I try to do anything with it, it barfs:

dH+0;

Error, (in Physics:-Vectors:-+) invalid operation * between vectors _i and _j

As it turns out the issue is the square of the vector p_. Maple (or rather, Physics) does not recognize that it needs to expand p_^2 as p_.p_ and seems to treat is like p_*p_.

I would like Edgardo---& others more experienced with the Physics package than I am---to look at this. I do not understand the Physics package well enough to judge whether overloading the exponentiation operator to make this work is the right thing.

The example works once I replace p_^2 by p_.p_. But the ^2 notation is fairly standard usage so it feels slightly awkward.

Thanks,

Mac Dude.

Derivation_of_H.mw

## Simplifying square root term...

Hi,

I m trying to simplify an expression involving square roots in Maple. But instead of giving the expected output it is not simplifying it. Please find the attached maple file for reference. I calculated manually and the result is 1. Please help me out for this. Thanx in advance.

Regards

Sunit

 >
 >
 (1)
 >
 (2)
 >

## display square brackets (versus subscripts)...

Is it possible to have Maple display square brackets, instead of a subscript ? (Seperately, I would still like to use subscripts. So, I don't want everything in square-bracket notation.)

Input:

Evaluates to:

## Interface Question...

Hi,

The default way a prompt shows on my maple is

[> blah blah blah

but i see in many worksheets including maple help pages that it shows as

> blah blah blah

My Question is how do i remove that left square bracket "[" from appearing ?

## modification of expression...

Hello people in mapleprimes,

Basically, what I want to do is to change the expression of sqrt((-a)^2) to sqrt(a^2).

The expression I want to modify is this:

aa:=phi[n, j] = a[j, D]-a-sqrt((-a[j, D]+a+tau[n, j])^2+4*gamma*f[c, n, j]/L[j])

I want to change this to

phi[n, j] = a[j, D]-a-sqrt((a[j, D]-a-tau[n, j])^2+4*gamma*f[c, n, j]/L[j])

To do this, I wrote as

subs(sqrt((-a[j, D]+a+tau[n, j])^2+4*gamma*f[c, n, j]/L[j]) = sqrt((a[j, D]-a-tau[n, j])^2+4*gamma*f[c, n, j]/L[j]), phi[n, j] = a[j, D]-a-((-a[j, D]+a+tau[n, j])^2+4*gamma*f[c, n, j]/L[j])^(1/2))

Or, I wrote as

subs(op([2,3,2,1,1],aa)=(a[j, D]-a-tau[n, j])^2,aa)

If there is better ways, please tell me them.

Best wishes.

taro

## Order symbolic output for complex number...

Hi all,

my problem concerns operation with complex number in Maple 18. The issue is the following:

i define this complex: c:=a+i*b

then i compute the square: sort(evalc(c^2))

and the output is: a^2+2*i*ab-b^2

So, how can i obtain an output like the following?  a^2-b^2b^2 +a*i*ab

In other word i want an output where the real part precede the complex part.

## Is there any way to make Maple produce an image of...

I am trying to use Maple to produce an image that will be part of a math paper.  The final image must be in .eps format.  Whenever I produce a plot in Maple17 and click on it, it looks like the image has the shape of a square (regardless of what's inside it), perhaps with a lot of empty space.  I want an image without a lot of empty space, and I'd like Maple to do this.  If I crop a square image using some other application, it is not going to improve the quality of the image and might hurt it.

If the answer to question in the Title is "no", can anyone suggest a good way to produce a good .eps image from a Maple plot that is cropped properly to eliminate as much empty space as possible?  I have Photoshop, but I don't know if this is the best way to go.

I wrote a toy file that plots a simple curve.  I'll upload it and provide a link to it.  If you execute the code and click on the image, you'll see that it is a square with a lot of empty space.

Nov122013.mw

 > restart:
 > with(plots):
 > p1:=plot(x^2,x=0..1,scaling=constrained,view=[-4..5,-1..3]):
 > display(p1);
 >
 >

## Removing units with power...

Hi again! :-)

I just ran into another problem with units...

I want to remove all units from an expression like this one

V[dis]:=(3/100000)*Unit('m')^3+0.1e-2*Pi*Unit('m')^2*(.112-0.28e-1*cos(theta)-sqrt(0.7e-2-0.1e-2*sin(theta)^2))

I've tried with convert(V[dis],'units_free') but Maple wont let me use that command, when the expression contains units in powers (square and cubic).

I guess there is another way arround, but how?

Best regards

 Page 1 of 1
﻿