From 7dd8b4fabce8d3a96772bbe4358e8173ee7c76dd Mon Sep 17 00:00:00 2001 From: Francesc Verdugo Date: Fri, 22 Sep 2023 17:08:11 +0200 Subject: [PATCH] Added solutions for Jacobi notebook --- docs/src/solutions_for_all_notebooks.md | 54 + notebooks/figures/fig_jacobi.svg | 22091 +++++++++++++++------- 2 files changed, 15735 insertions(+), 6410 deletions(-) diff --git a/docs/src/solutions_for_all_notebooks.md b/docs/src/solutions_for_all_notebooks.md index 80140b3..12340c3 100644 --- a/docs/src/solutions_for_all_notebooks.md +++ b/docs/src/solutions_for_all_notebooks.md @@ -213,4 +213,58 @@ end At each call to @spawnat we will communicate O(N) and compute O(N) in a worker process just like in algorithm 1. However, we will do this work N^2/P times on average at each worker. Thus, the total communication and computation on a worker will be O(N^3/P) for both communication and computation. Thus, the communication over computation ratio will still be O(1) and thus the communication will dominate in practice, making the algorithm inefficient. +## Jacobi method + +### Exercise 1 + +```julia +@everywhere workers() begin + using MPI + comm = MPI.Comm_dup(MPI.COMM_WORLD) + function jacobi_mpi(n,niters) + nranks = MPI.Comm_size(comm) + rank = MPI.Comm_rank(comm) + if mod(n,nranks) != 0 + println("n must be a multiple of nranks") + MPI.Abort(comm,1) + end + n_own = div(n,nranks) + u = zeros(n_own+2) + u[1] = -1 + u[end] = 1 + u_new = copy(u) + for t in 1:niters + reqs = MPI.Request[] + if rank != 0 + neig_rank = rank-1 + req = MPI.Isend(view(u,2:2),comm,dest=neig_rank,tag=0) + push!(reqs,req) + req = MPI.Irecv!(view(u,1:1),comm,source=neig_rank,tag=0) + push!(reqs,req) + end + if rank != (nranks-1) + neig_rank = rank+1 + s = n_own+1 + r = n_own+2 + req = MPI.Isend(view(u,s:s),comm,dest=neig_rank,tag=0) + push!(reqs,req) + req = MPI.Irecv!(view(u,r:r),comm,source=neig_rank,tag=0) + push!(reqs,req) + end + for i in 3:n_own + u_new[i] = 0.5*(u[i-1]+u[i+1]) + end + MPI.Waitall(reqs) + for i in (2,n_own+1) + u_new[i] = 0.5*(u[i-1]+u[i+1]) + end + u, u_new = u_new, u + end + return u + end +end +``` + + + diff --git a/notebooks/figures/fig_jacobi.svg b/notebooks/figures/fig_jacobi.svg index 0049c2b..f882af6 100644 --- a/notebooks/figures/fig_jacobi.svg +++ b/notebooks/figures/fig_jacobi.svg @@ -20,6 +20,36 @@ inkscape:export-ydpi="200"> + + + + + + 1 - - - - - - (i+1,j) - (i,j) - (i-1,j) - (i,j+1) - (i,j-1) + inkscape:export-ydpi="200"> + + + + + + (i+1,j) + (i,j) + (i-1,j) + (i,j+1) + (i,j-1) + + inkscape:export-ydpi="200" + transform="translate(35.814117)"> CPU 3 CPU 2 CPU 3 CPU 2 CPU 1 + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - CPU 1 + + style="fill:#0000ff;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + style="fill:#0000ff;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + style="fill:#0000ff;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> CPU 3 CPU 2 CPU 3 CPU 2 CPU 3 CPU 2 CPU 3 CPU 2 CPU 3 CPU 2 k - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CPU 3 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ? Data updated Data used (iteration k) - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CPU 3 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CPU 2 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ? Data updated Data used (iteration k) + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CPU 2 + - - - - - - - CPU 3 - N/P - N - 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CPU 2 + N/P + N + 1 + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="775.76117" + x="2097.4507" + height="5.1131492" + width="5.1131492" + id="rect13826-7" + style="fill:none;fill-opacity:0.29019608;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.96666715" /> + + + + + + k k CPU 3 Data used (iteration k) ? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + k k CPU 1 Data updated (iteration k) ? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + k k CPU 1 Data used (iteration k) ? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CPU 2 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Data updated Data used ? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id="path22057-6" + d="m 1240.7046,-318.87749 v 46.01836" + style="fill:#0000ff;stroke:#0000ff;stroke-width:0.565;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + + id="path22061-5" + d="m 1271.3835,-318.8775 v 46.01836" + style="fill:#0000ff;stroke:#0000ff;stroke-width:0.565;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - k k CPU 3 Data used (iteration k) ? - + id="path22555-74" + d="m 1286.723,-318.8775 v 46.01836" + style="fill:#0000ff;stroke:#0000ff;stroke-width:0.565;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + + + + + + CPU 5 Data updated Data used ? + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + CPU 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + y="-1.5138949" + x="1640.6113" + height="3.9838662" + width="3.9838662" + id="rect24841-5" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1596.7887" + height="3.9838662" + width="3.9838662" + id="rect24843-4" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1600.7726" + height="3.9838662" + width="3.9838662" + id="rect24845-1" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1604.7563" + height="3.9838662" + width="3.9838662" + id="rect24847-5" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1608.7404" + height="3.9838662" + width="3.9838662" + id="rect24849-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1612.7242" + height="3.9838662" + width="3.9838662" + id="rect24851-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1616.708" + height="3.9838662" + width="3.9838662" + id="rect24853-9" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340889" + x="1596.7887" + height="3.9838662" + width="3.9838662" + id="rect24855-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="6.4537868" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect24977-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + - + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="10.437674" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect24981-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect24983-9" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect24985-9" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect24987-0" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect24989-7" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect24991-6" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect24993-3" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect24995-7" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect24997-6" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect24999-1" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25001-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25003-0" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25005-6" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25007-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25009-0" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect25011-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25013-1" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25015-2" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25017-2" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25019-6" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25021-9" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect25023-1" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25025-0" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25027-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25029-2" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25031-7" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25033-4" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25035-0" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25037-3" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25039-2" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect25041-8" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25043-0" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25045-3" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25047-7" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25049-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25051-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect25053-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25055-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25057-9" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="2.4699309" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25059-2" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="6.4537868" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25061-7" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25063-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25065-2" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25067-5" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25069-2" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25071-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25073-4" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1680.4808" + height="3.9838662" + width="3.9838662" + id="rect25075-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1656.5775" + height="3.9838662" + width="3.9838662" + id="rect25077-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1660.5614" + height="3.9838662" + width="3.9838662" + id="rect25079-6" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1664.5453" + height="3.9838662" + width="3.9838662" + id="rect25081-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1668.5292" + height="3.9838662" + width="3.9838662" + id="rect25083-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1672.5131" + height="3.9838662" + width="3.9838662" + id="rect25085-9" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1676.4971" + height="3.9838662" + width="3.9838662" + id="rect25087-2" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + y="2.4699309" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25091-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="6.4537868" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25093-1" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="10.437674" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25095-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="14.421545" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25097-3" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="18.405416" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25099-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25101-2" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="22.389288" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25103-2" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25105-4" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373159" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25107-5" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1684.4647" + height="3.9838662" + width="3.9838662" + id="rect25109-1" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> @@ -105980,2409 +115334,2326 @@ inkscape:export-ydpi="200" inkscape:export-xdpi="200" inkscape:export-filename="/home/francesc/fig_jacobi_07.png" - y="959.16382" - x="1903.3292" - height="5.1131492" - width="5.1131492" - id="rect15638-0" - style="fill:none;fill-opacity:0.85238091;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:0.96666715" /> + y="-1.513956" + x="1688.4486" + height="3.9838662" + width="3.9838662" + id="rect25147-8" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="-1.5138949" + x="1696.4164" + height="3.9838662" + width="3.9838662" + id="rect25199-7" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="6.4537868" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25203-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="14.421576" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25207-1" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="22.389303" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25213-1" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373175" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25215-5" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="26.373175" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25217-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="30.357016" + x="1700.4001" + height="3.9838662" + width="3.9838662" + id="rect25219-9" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - + inkscape:export-ydpi="200" /> - + inkscape:export-ydpi="200" /> - + inkscape:export-ydpi="200" /> - + inkscape:export-ydpi="200" /> - + inkscape:export-ydpi="200" /> + + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + - - - - - - k + k CPU 1 + Data updated (iteration k) ? + + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="34.340889" + x="1688.4486" + height="3.9838662" + width="3.9838662" + id="rect25299-7" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="38.324745" + x="1688.4486" + height="3.9838662" + width="3.9838662" + id="rect25303-2" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="34.340904" + x="1692.4324" + height="3.9838662" + width="3.9838662" + id="rect25307-6" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="38.324776" + x="1692.4324" + height="3.9838662" + width="3.9838662" + id="rect25311-0" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + y="42.308601" + x="1692.4324" + height="3.9838662" + width="3.9838662" + id="rect25315-1" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340904" + x="1696.4164" + height="3.9838662" + width="3.9838662" + id="rect25317-5" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="34.340904" + x="1696.4164" + height="3.9838662" + width="3.9838662" + id="rect25319-6" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + y="38.324776" + x="1696.4164" + height="3.9838662" + width="3.9838662" + id="rect25321-5" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - + y="38.324776" + x="1696.4164" + height="3.9838662" + width="3.9838662" + id="rect25323-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.16673626;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + Data updated Data used ? + + u + u_new + CPU 2 ? ? ? + - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> - - - + inkscape:export-ydpi="200" /> + height="5.1131492" + x="1652.674" + y="-315.44467" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1668.0134" + y="-341.01044" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1668.0134" + y="-320.55783" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1637.3345" + y="-310.33154" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1657.7871" + y="-310.33154" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1673.1266" + y="-341.01044" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1673.1266" + y="-320.55783" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + + + + height="5.1131492" + x="1673.1266" + y="-310.33154" + inkscape:export-filename="/home/francesc/fig_jacobi_07.png" + inkscape:export-xdpi="200" + inkscape:export-ydpi="200" /> + id="rect22511-6-89-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22513-5-2-0" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22515-1-66-7" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22517-1-49-8" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22519-4-50-6" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22521-8-4-8" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22523-5-8-8" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22525-7-7-4" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22527-6-1-3" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22529-6-7-1" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22531-9-27-4" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22533-1-2-9" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22535-4-2-2" + style="fill:none;fill-opacity:0.21176471;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22537-3-6-0" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + id="rect22539-6-1-6" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - - - + id="rect22541-7-0-8" + style="fill:none;fill-opacity:0.21383099;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - - - + id="rect22543-6-6-9" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> - - - + id="rect22545-9-1-2" + style="fill:none;fill-opacity:1;stroke:#000000;stroke-width:0.114;stroke-linecap:square;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none" /> + + d="m 1637.3343,-305.21842 h 46.0184" + id="path22559-6-90-9" + inkscape:connector-curvature="0" /> + id="path22561-6-9-5" + d="m 1637.3343,-320.55792 h 46.0184" + style="fill:none;fill-opacity:0.21176471;stroke:#0000ff;stroke-width:0.56500006;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> + style="fill:none;fill-opacity:0.21176471;stroke:#0000ff;stroke-width:0.56500006;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + d="m 1637.3343,-335.89732 h 46.0184" + id="path22563-8-1-0" + inkscape:connector-curvature="0" /> + id="path22565-7-7-4" + d="m 1637.3343,-351.23682 h 46.0184" + style="fill:none;stroke:#0000ff;stroke-width:0.56500006;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" /> k k CPU 2 CPU 1 Data used (iteration k) CPU 1 ? + height="138.3909" + x="2125.3608" + y="-1872.7255" + style="fill:#0000ff" />CPU 3