Skip to content

Instantly share code, notes, and snippets.

View jjakob's full-sized avatar

Jernej Jakob jjakob

View GitHub Profile

To calculate the pressure difference in a convective loop for water with two temperature points, we can use the hydrostatic pressure equation along with the properties of water.

Step 1: Determine the Density of Water

The density of water varies with temperature. At approximately 20°C, the density is about 998 kg/m³, and at 60°C, it decreases to about 983 kg/m³. For our calculation, we can average the two densities, but let's take the values as they are for simplicity in this case.

Step 2: Hydrostatic Pressure Equation

The hydrostatic pressure difference can be expressed as:

$$\Delta P = \rho g h$$

/*
* webkit-gtk userscript h264ify
* Licensed under The MIT License (MIT)
* Original author: Copyright (c) 2015 erkserkserks
*/
function override() {
// Override video element canPlayType() function
var videoElem = document.createElement('video');
var origCanPlayType = videoElem.canPlayType.bind(videoElem);
@jjakob
jjakob / delete_conflict_senders.sql
Last active June 12, 2022 12:40
Quassel-IRC plpgsql procedure to delete senders that violate the unique index constraint. https://bugs.quassel-irc.org/issues/1245
CREATE OR REPLACE PROCEDURE delete_conflict_senders() AS $$
BEGIN
DROP INDEX IF EXISTS sender_sender_realname_avatarurl_uindex;
/* part 1: update columns */
UPDATE sender
SET realname=''
WHERE realname IS NULL
;
@jjakob
jjakob / Building_openmediavault_5_on_Buster.md
Last active April 26, 2024 09:30
Guide for building Openmediavault 5 on Debian Buster

This guide is only for Debian Buster (10) as of 2019-01-07. It was tested on a mipsel system (GnuBee PC2).

  1. Enable buster-backports (needed for monit)
echo "deb http://httpredir.debian.org/debian buster-backports main" >> /etc/apt/sources.list
apt-get update
  1. Install prerequisites