Sep-13-2019, 02:42 PM
(This post was last modified: Sep-13-2019, 02:42 PM by newbieAuggie2019.)
I'm having some problems when I try to post (already a few times) and then a python-forum.io/newreplay.php in blank appears, instead of adding my post, so I'm going to try to cut in several pieces (posts) what I wanted to tell you... Sorry!
I was just thinking of a way to show you clearly that the reason for having a nicer or uglier display of the output of such big matrices is the width of the window where they are displayed. For that, I modified, once again, the program to show you two ways of displaying matrices, in this case, keeping the square brackets ([, ]). With the second way of displaying matrices, I'm probably committing a mortal sin in Python, but I think it's worth the effort to show you how the vision of the matrices changes, and how one method is better to keep the format (actually, it's the last one, which I think is coded with my worst Python). First, the program (just add these lines of code after your whole matrix m1 = [['x0101+y0101i', 'x0102+y0102i', ..., 'x1514+y1514i', 'x1515+y1515i']], overwriting the one method that was already there):
First, the one too narrow for the “This is matrix m1 (15x15)”:
![[Image: window-too-wide-for-This-is-matrix-m1.png]](https://i.postimg.cc/sgCrQ5X6/window-too-wide-for-This-is-matrix-m1.png)
Second, the one with just the right width for both matrices:
![[Image: window-with-the-right-width-for-both-matrices-m1.png]](https://i.postimg.cc/mgk5rD3X/window-with-the-right-width-for-both-matrices-m1.png)
Third, the one too narrow for both matrices:
![[Image: window-too-narrow-for-both-matrices-m1.png]](https://i.postimg.cc/J0djY1y0/window-too-narrow-for-both-matrices-m1.png)
I repeat, all 3 images are images of the same output, but the elements of the matrices have moved themselves when I have narrowed or widened the width of the window of my Python 3.7.4 Shell!!!
Here, I have modified the size of the images to appear the same (and they look still smaller than in my Python Shell), but you can check by yourself.
And as you can see, I think the second way for displaying the matrices seem to cause lesser movement of the elements of the matrices.
All the best,
![Confused Confused](https://python-forum.io/images/smilies/confused.png)
I was just thinking of a way to show you clearly that the reason for having a nicer or uglier display of the output of such big matrices is the width of the window where they are displayed. For that, I modified, once again, the program to show you two ways of displaying matrices, in this case, keeping the square brackets ([, ]). With the second way of displaying matrices, I'm probably committing a mortal sin in Python, but I think it's worth the effort to show you how the vision of the matrices changes, and how one method is better to keep the format (actually, it's the last one, which I think is coded with my worst Python). First, the program (just add these lines of code after your whole matrix m1 = [['x0101+y0101i', 'x0102+y0102i', ..., 'x1514+y1514i', 'x1515+y1515i']], overwriting the one method that was already there):
print("\n\nThis is matrix m1 (15x15):\n") print(m1) print("\n\nBuilding matrix m1 (15x15):\n") print(end="[") for row in range(0, 15): print(m1[row], sep="], [") print("]", end='')Now, as I’m having some problems trying to post all together, I’m going to post one by one, the 3 different images of the same output, made different by just narrowing or widening the window of my Python 3.7.4 Shell.
First, the one too narrow for the “This is matrix m1 (15x15)”:
![[Image: window-too-wide-for-This-is-matrix-m1.png]](https://i.postimg.cc/sgCrQ5X6/window-too-wide-for-This-is-matrix-m1.png)
Second, the one with just the right width for both matrices:
![[Image: window-with-the-right-width-for-both-matrices-m1.png]](https://i.postimg.cc/mgk5rD3X/window-with-the-right-width-for-both-matrices-m1.png)
Third, the one too narrow for both matrices:
![[Image: window-too-narrow-for-both-matrices-m1.png]](https://i.postimg.cc/J0djY1y0/window-too-narrow-for-both-matrices-m1.png)
I repeat, all 3 images are images of the same output, but the elements of the matrices have moved themselves when I have narrowed or widened the width of the window of my Python 3.7.4 Shell!!!
Here, I have modified the size of the images to appear the same (and they look still smaller than in my Python Shell), but you can check by yourself.
And as you can see, I think the second way for displaying the matrices seem to cause lesser movement of the elements of the matrices.
All the best,
newbieAuggie2019
"That's been one of my mantras - focus and simplicity. Simple can be harder than complex: You have to work hard to get your thinking clean to make it simple. But it's worth it in the end because once you get there, you can move mountains."
Steve Jobs
"That's been one of my mantras - focus and simplicity. Simple can be harder than complex: You have to work hard to get your thinking clean to make it simple. But it's worth it in the end because once you get there, you can move mountains."
Steve Jobs