From 3635b05eb67217a24ccb40f92723d728e464d592 Mon Sep 17 00:00:00 2001 From: Paul Garlick Date: Fri, 17 Dec 2021 18:27:24 +0000 Subject: fullswof-utils: Add script to monitor convergence history. * fullswof-utils/specificPoints.py: New file. --- fullswof-utils/specificPoints.py | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 fullswof-utils/specificPoints.py diff --git a/fullswof-utils/specificPoints.py b/fullswof-utils/specificPoints.py new file mode 100755 index 0000000..eb96eb7 --- /dev/null +++ b/fullswof-utils/specificPoints.py @@ -0,0 +1,24 @@ +#!/usr/bin/env python3 + +import matplotlib.pyplot as plt +import numpy as np +import os +from matplotlib.ticker import MultipleLocator + +def detach_display(): + t, x, y, h, u, v = np.loadtxt( + 'hu_specific_points.dat', delimiter='\t', unpack=True) + fig, ax = plt.subplots() + plt.plot(t,h, label='elevation') + plt.xlabel('t / s') + plt.ylabel('h / m') + ax.yaxis.set_minor_locator(MultipleLocator(0.2)) + plt.grid(True, which='minor') + plt.show() + +if os.fork(): + # parent + pass +else: + # child + detach_display() -- cgit