projects
/
TDDE44.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
998077d
)
update
author
Nils Forssén
<forssennils@gmail.com>
Tue, 8 Feb 2022 10:10:26 +0000
(11:10 +0100)
committer
Nils Forssén
<forssennils@gmail.com>
Tue, 8 Feb 2022 10:10:26 +0000
(11:10 +0100)
laboration3/uppgift_2.py
patch
|
blob
|
history
diff --git
a/laboration3/uppgift_2.py
b/laboration3/uppgift_2.py
index ae7af5229bbdfd6308479c111e4a2ca134470a53..fafc5f66023d8bad22350688dec27578593d664d 100644
(file)
--- a/
laboration3/uppgift_2.py
+++ b/
laboration3/uppgift_2.py
@@
-68,8
+68,8
@@
def matrix_square(matrix):
cols = get_all_columns(matrix)
for i in range(len(matrix)):
- for
row in matrix
:
- tot[i].append(scalar_product(
row, cols
[i]))
+ for
col in cols
:
+ tot[i].append(scalar_product(
col, matrix
[i]))
return tot