Skip to main content
1-Visitor
September 29, 2018
Question

How to rotate image without using "rotate" keyword in mathcad?

  • September 29, 2018
  • 3 replies
  • 9979 views

Example: A=(0,1,2) now by using rotate keyword Result = rotate(A,180); Result = (2,1,0). But how to do this without keyword ?

 

3 replies

24-Ruby IV
September 29, 2018

May be this help you

TT.png

1-Visitor
September 29, 2018

yes i'm aware of that but how to do for random degrees for ex:  rotate(A,41) or rotate(A,33)?

25-Diamond I
September 29, 2018

"rotate" is used to rotate a picture(matrix) by a given angle in degree with some sort of antialiasing.

Why would you like to program that function yourself and not use the built-in one?

B.png

 

1-Visitor
September 30, 2018

Yes i'm aware of that keyword but how to do without keyword ? or is it possible to see how that "rotate" function program has written in mathcad ? 

25-Diamond I
September 30, 2018

@Mathcad111 wrote:

Yes i'm aware of that keyword but how to do without keyword ?


You haven't answered my question which simply was: WHY?

 


@Mathcad111 wrote:

or is it possible to see how that "rotate" function program has written in mathcad ? 


No, not that I would be aware of. The algorithms used in Mathcad are not a secret but are hard coded and so can't not be inspected unless you have access to the source code of the program.

As far as I am aware many algorithms implemented in Mathcad followed the "Numerical Recipes" and the four volumes of "Knuth - The Art of Computer Programming" but I am not sure if this also applies to the algorithms for manipulating bitmaps.

 

But if you study Books about computer graphics you sure will find various ways and algorithms how to rotate a bitmap picture and implement anti-aliasing.

Searching the net will reveal a lot of possible implementations, too. Some less, some more elaborate.

As one example you may ave a look at https://www.codeproject.com/Articles/12230/Anti-Aliased-Image-Rotation

1-Visitor
October 9, 2018

krogerfeedback


@Mathcad111 wrote:

Example: A=(0,1,2) now by using rotate keyword Result = rotate(A,180); Result = (2,1,0). But how to do this without keyword ?

 


I didn't exactly understand this? Am I missing something?

23-Emerald IV
October 9, 2018

The OP didn't want to know the result of rotating, but wanted insight in the algorithm of how to do it.

 

Luc