Coverage for pyrc \ validation \ coupling \ __init__.py: 0%

10 statements  

« prev     ^ index     » next       coverage.py v7.13.5, created at 2026-04-13 16:59 +0200

1# ------------------------------------------------------------------------------- 

2# Copyright (C) 2026 Joel Kimmich, Tim Jourdan 

3# ------------------------------------------------------------------------------ 

4# License 

5# This file is part of PyRC, distributed under GPL-3.0-or-later. 

6# ------------------------------------------------------------------------------ 

7 

8from pyrc.validation.network import Block 

9 

10name_add_on = "" 

11 

12 

13def setup(save_step=0.1): 

14 increments_per_block = 1000 

15 increments_per_width = 1000 // 15 

16 blocks = [ 

17 Block(8, 20, increments=increments_per_width * 8), 

18 Block(4, 60, increments=increments_per_width * 4), 

19 Block(2, -10, increments=increments_per_width * 2), 

20 Block(6, 0, increments=increments_per_width * 6), 

21 ] 

22 # blocks = [ 

23 # Block(8, 0, increments=increments_per_block), 

24 # Block(4, 60, increments=increments_per_block), 

25 # Block(8, 0, increments=increments_per_block), 

26 # ] 

27 kwargs = { 

28 # "thermal_conductivity": 10, 

29 # "density": 100, 

30 # "heat_capacity": 100, 

31 } 

32 # blocks = [ 

33 # Block(5, 0, increments=increments_per_block, **kwargs), 

34 # Block(5, 60, increments=increments_per_block, **kwargs), 

35 # Block(5, 0, increments=increments_per_block, **kwargs), 

36 # ] 

37 

38 time_indexes = [x for x in [0] + [n * 10 ** i for i in [0, 1, 2, 3, 4] for n in [1, 2, 5]] if x <= 2000 / save_step] 

39 times = [t * save_step for t in time_indexes] 

40 

41 return blocks, time_indexes, times, name_add_on