Stretto

145 Reputation

5 Badges

1 years, 69 days

MaplePrimes Activity


These are replies submitted by Stretto

@acer 

 

kernelopts(homedir) gives `C:\User\Me`

 

which is not what I've set in the maple ini files(there are two and both have the dir I want).

I have 3 maple ini files. One seems to be the total settings and others are minor. They all have the proper dir and set according to the files but none change the home dir.

 

in maplelauncher.l4j.ini

# Define a folder where to store Maple preferences
-Dmaple.user.home="B:\Maple Files"

If I drop the parenthesis maple refuses to load,

 

So this definitely seems to be the correct file that but it refuses to set the dir and execute the maple.ini file in that directory. I've tried using various formats but maple never reads the file. It seems the space causes it to crash without quotes. If I change it to anything maple still does not get the correct dir and just uses C:\User\Me.

I created the maple.ini file in C:\User\Me and it does load it, I then added a read to the file I want and it does read it, so that is a "solution".

 

I added

 

interface(echo = 0):
interface(warnlevel = 0):

 

but that does not hide all the junk that the code prints at the top of the worksheet which I'd like to avoid.

 

 

interface(echo = 0):
interface(warnlevel = 0):
 
 
  read `B:\\Maple Files\\maple.ini`;
 
 
interface(echo = 2):
interface(warnlevel = 4):

 

and the read file does some stuff and some of that stuff get's printed:

>                              I
> interface(warnlevel = 4):
>   
>   
> interface(echo = 2):
> interface(warnlevel = 4):

 

 

 

 

Thanks. Yes it seems to.

 

Is there any way to overload the _?

 

I'd like to have a notation [x]_n.. which is simply a rewrite of q(x,n) for some special functions.

 

 

@acer 

if not i::numeric then return 'procname'(args); end if;

 

That works except that it get the wrong values ;/

 

The only difference is I have

 

f := proc(a,b)
    if not a::numeric or not b::numeric then return 'procname'(a,b); end if;

 

When using add it works fine and I get the wrong values but using sum I get the wrong ones. Without the above sum fails.

 

 

 

@Carl Love 

Thanks, but i do not get what you mean by DataFrames. I've never used them, they seem just like tables with info attached. How can one define a simple boolean type of [a=b] which returns 1 if a = b and 0 else?

 

@Carl Love Thanks for the informative response.

@Carl Love Thanks. I usually add with(plots) and I thought I did but I guess I didn't.

@tomleslie 

 

I've tried that but it doesn't seem to work. I was able to change the folders but I don't see where to get a worksheet or library loaded.

 

https://www.maplesoft.com/support/help/Maple/view.aspx?path=worksheet/reference/initialization

 

Under Windows, the initialization file is called maple.ini.

 

I changed

 

2. 

Open the file, maplejava.i4j.ini.

3. 

Uncomment the second line # -Dmaple.user.home="C:Temp" and change C:\Temp to the directory you want to store the .ini file in.

 

 

(was maplelauncher.i4j.ini as I did not have maplejava.i4j.ini)

 

The initialization file is an ASCII text file that contains the commands in Maple syntax. It is recommended that you use a colon to end the commands so that the output is not printed in the worksheet on startup. In multiple user environments, one initialization file can be defined for all users, and all users can also have their own initialization file. The specific name and location of this file varies depending on the operating system.

 

A new maple.ini was ultimately created with all the settings(reset to defaults). But I see no where to add or change files to add commands to the initialization file.

 

It seems this info is outdated. maple.ini are just the settings from options.

@Kitonum 

 

That is what I was looking for, Thanks!

@tomleslie  I should never have mentioned erf or any other specific function, it has nothing to do with the real problem and has only gotten the problem off on a tangent. I don't care about erf, I was just using it as a placeholder to specify a real function for simplicity.

 

The point is that

fourier: Entering fourier with erf(t)
inttrans/fourier/lookup: Enter with  erf(t) t v
inttrans/fourier/lookup: Returning  FAIL
inttrans/fourier/main: Entering with erf(t) t v
inttrans/fourier/lookup: Enter with  erf(t) t _S
inttrans/fourier/lookup: Returning  FAIL

inttrans/fourier/main: Leaving(3) with fourier(erf(t) t v)

 

 

 

Fails FOR some functions such... For some very complex functions it will always fail since there is no closed form solution. In those cases I want to evaulate numerically. I could do this by computing the fourier transform or even the fft but I would expect maple to have the machinery inside it to do this stuff for me... since all I want to do is plot.

 

In matlab I can do this basically with the fft command.. I can even define an arbitrary function and use it to compute the values.

 

Maple is symbolic, but plotting has nothing to do with symbols... since all I want to do is plot there should be some way to plot complex functions without having to go in to another program or wait years for it to complete.

 

 

@Mariusz Iwaniuk 

 

I should never have mentioned erf or any other specific function, it has nothing to do with the real problem and has only gotten the problem off on a tangent. I don't care about erf, I was just using it as a placeholder to specify a real function for simplicity.

 

@Carl Love 

 

No. f does not matter. It has nothing to to do with f. All you did was align the bounds between the two animations so they both start and stop together. That is ok, but that doesn't solve the problem of mapping t->g(t) making the animation take 100x longer.

 

It would be easier to compute the values for t myself per frame and input them in

T := [seq(2^(k/10),k=0..10]

animate(plot, [fourier(f(x,t),x,w)/2^t, w= 0..100], t= T)

 

Now the fourier trasnform will run at full speed since it isn't trying to figure out 2^t dependence.

 

The point is that 2^t should not cause the fourier transform to crap out. The CAS should be able to handle it and even make the substitution of u = 2^t and take the same time to compute fourier(f(x,u),x,w);

 

If fourier(f(x,u),x,w) is fast then

fourier(f(x,2^t),x,w) should be fast.

 

This really isn't a problem with the animation, except that I'm specifically mapping t to 2^t to make the animation "smoother"(since it counters the log[2] dependence of t in f(x,t).

 

 

 

 

@acer 

Ok, I did not see those items in the list because of the coloration... THe main menu items at the top are so dominant and questions are the first one. It's obvious after one see's it.

Thanks.

 

Some of the maple coloration is a bit hard to see. Medium Grey with White text and such... Might be my browser or monitor or eyes... I rather have a more contrasting color theme.

@acer 

 

The second one was about insequence and I said I tried that and it did not work. It just plotted every frame individually with no animation.

I did not try the first as it seems a bit of a pain... it should be something VERY easy for maple to do... surely there is a proper way. This is not an NP hard problem. It is simple interpolation. N frames and M frames, we want them to finish at the same time, hence N/M is the ratio, modify frame rate by that amount and volia. It doesn't have to be perfect and if one frame is played half a ms sooner than it should then it's not going to end the world.

@Mariusz Iwaniuk 

 

An example is an example, an example is not general. I gave erf because it did not work in general using the general method. The reason why erf works is PRECISELY because it is defined by an integeral of a gaussian so the derivative simply returns a gaussian AND then the fourier transform of a gaussian is a gaussian.

 

For functions that are not defined by an integeral, the derivative wont necessarily simplify it in to somethign that has a fourier transform.  You want a specific case as if that is a general solution.

 

For something to be general means that it works for all inputs. What happens when I want to try a different function? Your method fails, you come up with a new one. I try it, it works, then I try a new function and your method fails... and the process is not general.

 

It is not about calculating a derivative symbolically, it is about taking the inverse transform of a function in general... seems you fail to understand that.

 

Your method works ONLY because of the special nature of erf. It does not work in general. How many functions do I have to show you to prove that? And how many will it take for you to realize that?

You want a function? Zeta(s), happy? Now try your derivative method!

Oh, maybe you figured out a trick with Zeta(s)? What about Zeta(s*Zeta(s + 1))? Oh, another trick? What about Zeta(s*cos(Zeta(s + erf(s^2 -sin(Zeta(s)))))*Zeta(s^2)^3. Ok, you found a trick! Great, you are now famous!

To plot something does not require symbolic manipulation. I realize maple is a CAS, but plotting functions should be possible and easy, even transforms of functions. Plotting helps visualize functions and it is an important area of mathematics. To limit plotting of functions to only those that are symbolically computable is nonsense.

 

 

 

 

 

@Mariusz Iwaniuk 

 

But this is not going to work in general, is it? You can take the derivative to erf because it is simply a gaussian and maple then can take the transform of a guassian... but in general the derivative may not be symbolically computable... so then what?

1 2 3 4 5 6 Page 5 of 6