Welcome to the Blog!
Here you find a broad range of different tutorials and solutions which deal with programming and software engineering. Maybe a suitable solution helps you :) Have fun reading it! You can also checkout the german version.
Here you find a broad range of different tutorials and solutions which deal with programming and software engineering. Maybe a suitable solution helps you :) Have fun reading it! You can also checkout the german version.
Run/Start Docker Container and execute command In some situations you have to test different commands inside a docker container but you might not want to keep running in the background. Then you can use the following command which: will start the container with docker_image execute a command specified after the -c argument docker run --rm -v `$(pwd)`:/temp_volume docker_image \ /bin/bash -c "cd /temp_volume && python3 script.py"
How to fix a wrong horizontal aligned column border in a multicolumn table? Problem I just had the following problem in LaTex: As you can clearly see in the image the border of the right column in the first row is not aligned with the border in the rows below. The LaTex code for this error is: % table excerpt Class Type & \multicolumn{3}{c}{A} & \multicolumn{3}{|c}{B} For simplicities reasons I only show a small except of the table....
Removal of booksmarks in PDFs Open Xournal++ Open the PDF Export the PDF again Now the bookmarks are removed
Discretiazation of a PDE You might be wondering where such kind of matrix structures appear. A simple example is the discretization of PDE (partial differential equations) such as: $$ -\nabla u = f(x) $$ If we consider a discretization with finite differences you can approximate your u_i as: $$ u’’(x) \approx \frac{u_{i-1} - u_i - u_{i+1}}{h^2} $$. In a 2D setting you can apply the same discretization of course for the y-direction in the same manner....
Truncate Values in an array (matrix) below a certain threshold If you perform numerical calculations like the QR-Decomposition you can come across numerical rounding errors. In this code snippet we calculate the first householder vector and matrix to perform a QR Decomposition of random integer 4x4 Matrix. The matrix looks likes this: $$ A = \begin{bmatrix} -1 & -6 & 5 & -10 \ 7 & 6 & 7 & -2 \ -1 & -10 & 0 & -2 \ -6 & 9 & 6 & -6 \ \end{bmatrix} $$...