diff --git a/phasefield/analytical.py b/phasefield/analytical.py
index 2a3854e287b70bb9ad8142b0e04bd62dd9aa767a..39796f0834734146d9bd5c7323b482afe5045501 100644
--- a/phasefield/analytical.py
+++ b/phasefield/analytical.py
@@ -373,5 +373,5 @@ def force_from_pressure_tensor(pressure_tensor, functions=None, pbs=None):
 
 
 def pressure_tensor_bulk_sqrt_term(free_energy, order_parameters, density, c_s_sq=sp.Rational(1, 3)):
-    pbs = sp.sqrt(density*c_s_sq - pressure_tensor_bulk_component(free_energy, order_parameters))
+    pbs = sp.sqrt(density * c_s_sq - pressure_tensor_bulk_component(free_energy, order_parameters))
     return pbs
diff --git a/phasefield/contact_angle_circle_fitting.py b/phasefield/contact_angle_circle_fitting.py
index 10976f75be99d580db789a55429ee1c01699df46..606c5f12b375ba10d22526eda48196a53468f2ca 100644
--- a/phasefield/contact_angle_circle_fitting.py
+++ b/phasefield/contact_angle_circle_fitting.py
@@ -69,7 +69,7 @@ def fit_circle(points):
 
     def point_distances(xc, yc):
         """ calculate the distance of each 2D points from the center (xc, yc) """
-        return np.sqrt((points[:, 0]-xc)**2 + (points[:, 1]-yc)**2)
+        return np.sqrt((points[:, 0] - xc) ** 2 + (points[:, 1] - yc) ** 2)
 
     def f(c):
         """ calculate the algebraic distance between the data points and the mean circle centered at c=(xc, yc) """
diff --git a/phasefield/experiments1D.py b/phasefield/experiments1D.py
index 90058e2ffeaad8d574f21a6998bc84f838bb7f1e..828fcc585613d6f0422bf8b798b3882cd5ff97a7 100644
--- a/phasefield/experiments1D.py
+++ b/phasefield/experiments1D.py
@@ -89,9 +89,8 @@ def init_tanh(pf_step, phase_idx, x1=None, x2=None, width=1):
         x = b.cell_index_arrays[0]
         phi = b[pf_step.phi_field_name]
 
-        phi[..., phase_idx] = (1 + np.tanh((x - x1)  / (2 * width))) / 2 + \
-                              (1 + np.tanh((-x + x2) / (2 * width))) / 2 \
-                              -1
+        phi[..., phase_idx] = (1 + np.tanh((x - x1) / (2 * width))) / 2 + \
+                              (1 + np.tanh((-x + x2) / (2 * width))) / 2 - 1
 
     pf_step.set_pdf_fields_from_macroscopic_values()
 
diff --git a/phasefield/kerneleqs.py b/phasefield/kerneleqs.py
index 65b8b60758cb02207b2e9d3de254599ddc7b6b76..c0c522cf9f2ffc8c2d55d3af7c8aeaf4277f8c47 100644
--- a/phasefield/kerneleqs.py
+++ b/phasefield/kerneleqs.py
@@ -2,8 +2,8 @@ import sympy as sp
 from pystencils import Assignment
 from pystencils.fd import Discretization2ndOrder
 from lbmpy.phasefield.analytical import chemical_potentials_from_free_energy, substitute_laplacian_by_sum, \
-    force_from_phi_and_mu, symmetric_tensor_linearization, pressure_tensor_from_free_energy, force_from_pressure_tensor, \
-    pressure_tensor_bulk_sqrt_term
+    force_from_phi_and_mu, symmetric_tensor_linearization, pressure_tensor_from_free_energy, \
+    force_from_pressure_tensor, pressure_tensor_bulk_sqrt_term
 
 
 # ---------------------------------- Kernels to compute force ----------------------------------------------------------
diff --git a/phasefield/phasefieldstep.py b/phasefield/phasefieldstep.py
index d15a6558426e145bd1f1c44f4f97095850f351cb..74bafa65ea0e1d5355f0876a150ca0ae2991661b 100644
--- a/phasefield/phasefieldstep.py
+++ b/phasefield/phasefieldstep.py
@@ -103,7 +103,8 @@ class PhaseFieldStep:
             self.pbs_field = dh.add_array(self.pbs_field_name, gpu=gpu)
             self.pressure_tensor_eqs = pressure_tensor_kernel_pbs(self.free_energy, order_parameters, self.phi_field,
                                                                   self.pressure_tensor_field, self.pbs_field, dx=dx,
-                                                                  density_field=None) # TODO get current density! not last one
+                                                                  density_field=None)
+            # TODO get current density! not last one
             # TODO call post-run on hydro-lbm before computing pbs to store the latest density
         else:
             self.pressure_tensor_eqs = pressure_tensor_kernel(self.free_energy, order_parameters,
diff --git a/phasefield/scenarios.py b/phasefield/scenarios.py
index 807970ea33e919e184eafa9b76e5dec2a6bb3026..49ce06cb7114308de99a1dc2b1024a89f6f6b525 100644
--- a/phasefield/scenarios.py
+++ b/phasefield/scenarios.py
@@ -11,7 +11,7 @@ def create_three_phase_model(alpha=1, kappa=(0.015, 0.015, 0.015), include_rho=T
                   sp.Symbol("kappa_1"): kappa[1],
                   sp.Symbol("kappa_2"): kappa[2]}
     if 'cahn_hilliard_gammas' not in kwargs:
-        kwargs['cahn_hilliard_gammas'] = [1, 1, 1/3]
+        kwargs['cahn_hilliard_gammas'] = [1, 1, 1 / 3]
 
     if include_rho:
         order_parameters = sp.symbols("rho phi psi")