sija

35 Reputation

0 Badges

9 years, 153 days

MaplePrimes Activity


These are replies submitted by sija

@janhardo 

Hello,

All animations work in Maple 2024. Try it and see for yourself.

By the way, I'm posting the last set of DiffGeo procedures, I also changed the procedure calls a bit.

Regards.

clsdgproc_cur&sur.txt

Hello,

Attached is the completed diffgeo procedures and Maple worksheet containing the animation below.

Regards.

Rolling_circle_on_surface.zip

@acer Thank you for the information.

@Rouben Rostamian  

Your code also works on any type of graphics, png..gif.
Thank you very much for helping me!

I greet you very warmly!

@acer 

Your solution works perfectly!!! I don't know how to thank you! Thank you very much for your help!

This is what I was missing. I am very grateful to you!

I greet you very warmly!

P.S.

I will test your code on the rest of my code.

Once again, thank you very much!

@acer 

After applying the function:

#**********************************
# MAPLE 18 RESIZE IMAGE *
#**********************************
Resize := proc(P,m::posint,n::posint)
      op(0,P)(op(P),ROOT(BOUNDS_X(0),BOUNDS_Y(0),
                   BOUNDS_WIDTH(n),BOUNDS_HEIGHT(m)));
end proc:

it is impossible to do export with:

plottools:-exportplot(path, rpl);

Where:

rpl := Resize(plots:-display(seq(plotAll(t),t=tRange,step),insequence=true,labels=[x,y,z],labelfont=["TimesNewRoman",16],orientation= [30,30],scaling=constrained),1000,1000);

This cannot be done because rpl is no longer a PLOT3D structure but a function. So if it was possible to restore rpl to the PLOT3D structure, export would be possible. But I don't know how to do it.

@acer 

Hello,

Attached I am sending the code and the necessary txt file.

Thank you very much Acer.

Regards.

ClsDGproc_Curves.zip

@C_R 
 

It is possible to perform manual scaling and manual export.

However, it would be useful programmatically.

@C_R 

The export could not be performed because Maple 18 cannot perform - I think - enlarged graphics. So when I removed the function to zoom

#************************
# MAPLE 18 RESIZE IMAGE *
#************************
Resize := proc(P,m::posint,n::posint)
       op(0,P)(op(P),ROOT(BOUNDS_X(0),BOUNDS_Y(0),
                    BOUNDS_WIDTH(n),BOUNDS_HEIGHT(m)));
end proc:

everything went OK. For now, I have done it manually, but it will also work programmatically.

So the question is, can Maple 18 export better graphics quality in another way?

@C_R 

Thank you C_R 2005.

However, I have a problem and I don't know how to solve it. I use the code below to export the animation to a gif file:

# EXPORT ANIMATIOM SEQUENCE TO GIF FILE IN THE WORKSHEET DIRECTORY
currentdir(interface(worksheetdir)):
pathName := interface(worksheetdir):
fileName := "oscCirSeq.gif":
path := FileTools:-JoinPath([pathName, fileName]):

if not FileTools:-Exists(path)
then
   seqPlot := plots:-display(seq(plotAll(t),t=tRange,step),insequence=true,labels=[x,y,z],labelfont=["TimesNewRoman",16],orientation=[30 ,30],scaling=constrained):

   plottools:-exportplot(fileName,seqPlot):
end if:

The problem is that the gif file is created correctly, but Maple gives an error:

Error, (in plottools:-exportplot) exported file oscCirSeq.gif could not be created

I cannot determine its cause. Changing the directory for saving the file has no effect.

The second type of the problem arises when I try to export to giff manually, then the dialog box for saving the file to giff remains open indefinitely, and the size of the started but not saved giff file is 0 bytes.

I'm trying to find the reasons but unfortunately to no avail.

@Carl Love 

I think I've found an "easy" way to solve the geodetic equations numerically. It's nothing complicated, but this piece of code is crucial.

restart;
N := 4:
L:=[]:
build:= proc(j)
  local k;
  global L;
  L:=[]:
 
  for k from 2 to j do
    L:= [op(L), v[k]];
  end do;

  RETURN(L);
end proc:

for j from 2 to N-1 do
  for i from 2 to j do
   if nops(L) = 0
    then
      # print(nops(L)); # Debug only
      # I need this here, but how to do ?
      nops(L); # <- Not working
    end if;
    
    build(i);
    
    if nops(L) > 0
    then
      for s from 1 to nops(L) do
        # print(L[s]); # Debug only
        # I need this here, but how to do ?
        L[s]; # <- Not working
      end do;
    end if;
  end do;
end do;

 

@acer 

At first I thought it was an index problem. Later I realized that this was not the case. The issue is beyond me, I don't know how to deal with it - maybe the solution is trivial, but I don't see it.

I explained everything in Maple worksheet.

Test.mw

@jganding 

Problem solved! Thanks to you, everything works as it should! Thank you!

@jganding 

Thank you very, very, very much for your in-depth analysis of the problem and comprehensive comment and description. Your comments are already starting to result in a more correct implementation of the issue. I must admit that I never thought that my definition of odeSys and initial conditions could be the cause of all the "confusion". That's why I thank you even more for your help. Thank you!

Best regards!

1 2 Page 1 of 2