segfault

110 Reputation

4 Badges

1 years, 347 days

MaplePrimes Activity


These are questions asked by segfault

While these things are a walk in the park with languages like C and system administration languages like bash, the maple file IO is really a bit wanting

I tried, but nowhere in the manual could I find how to use a variable in a filename.

As an example with bash,   you can assign a value to a variable say Ver=01.

The program code contains the filename as
filename$Ver.txt,
and upon execution of the file saved, it is saved as filename01.txt .
Where it replaced the variable with its value in the saved file.

There seems to be no such thing in Maple I could find.
If it exists, it must be so obscure that normal manual searches cannot find it.

So, how do you save a file using a variable in the filename, which then uses the value of the variable in the saved filename. ?
This is basically a prerequisite e.g. for server based maple doing large datasets, so maple must be capable doing it.

Is it possible in maple to resume an asymptotic expansion from a specific order onwards.

To be more specific.

Let's assume that I have the asymptotic expansion to say Order 20 already calculated or can import it from file.

Is it possible for Maple to use the expansion I already have and immediately start calculating Order 21 onwards ?

This will save a lot of time for numerical  expansions that can take literally days to complete.

The local command is really horribly treated in the manual. Very difficult to figure out heads from tails.

What follows is Maple code to unprotect the metric tensor g_[], and alter the components. that part I figured out by trial and error where the manual fails to clearly describe how.

But, the problem I now have, is that the unprotected metric does not show the tensor "visual matrix" form anymore if I execute  g_[] . So it makes it all unusable.

How do I enter the unprotected and altered g_[] back into maple so it can be used to calculate the Ricci tensor, Einstein tensor and such ? I guess it will have to be protected again etc. ?

Here is the code


restart;
with(Physics);
g_[sc];
g_[];
_local(g_[]);
g_[1, 2] := 1;
g_[3, 3];
Physics:-g_[1, 1];
g_[1, 2];
Physics:-g_[1, 1];
g_[];
for x to 4 do
    for y to 4 do g_[x, y] := Physics:-g_[x, y]; end do;
end do;
g_[];


So the question is. How do you reverse a localalized metric back to being protected after you altered the metric ?

Maple defaults to expressing output in terms of Cosines.

Is it possible to instruct maple to rather calculate the output  with Sine as the default ?

Why do maple not contract over inert differentials ?
The last command just return the defining equation and refuses to contract.

See example below

restart;
with(Physics);
g_[[5, 29, 1]];
eq1 := g_[~mu, ~nu]*Diff(w(r, theta), mu)*Diff(w(r, theta), nu);
SumOverRepeatedIndices(eq1);

-----------------------------------------------------------------------------------
However Check return empty coordinates, which is completely contradictory.

Check(eq1, all);
      The repeated indices per term are: ((...),(...),...)

        , the free indices are: (...)

                    [{}], {~mu, ~nu}

1 2 3 4 5 6 Page 1 of 6