How to refer subfigures using subpar and custom numbering

Hi. If the table content is not relevant, then you should remove it, it’s harder to work with big examples.

The what numbering? It includes the figure and sub-figure number, so it’s correct. To change the default reference styling, use How to refer subfigures using subpar and custom numbering - #2 by flokl, though a simpler version would be this:

  numbering-sub-ref: (..n) => {
    numbering("1.1a", ..counter(heading.where(level: 1)).get(), ..n)
  },

#import "@preview/subpar:0.2.2"

#set heading(numbering: "1.")

= Heading
= Heading
== Heading

@simulations

#subpar.grid(
  figure(rect(), caption: [Geometric description of meshes]),
  <meshes>,
  figure(rect(), caption: [Simulation parameters]),
  <simulations>,
  columns: 1,
  caption: [Case study descriptions],
  kind: table,
  numbering: n => {
    numbering("1.1", ..counter(heading.where(level: 1)).get(), n)
  },
  numbering-sub-ref: (..n) => {
    numbering("1.1a", ..counter(heading.where(level: 1)).get(), ..n)
  },
)

image


Regarding the tables, you can shorten some stuff:

#import "@preview/subpar:0.2.2"
#import "@preview/fancy-units:0.1.1": (
  add-macros,
  fancy-units-configure,
  num,
  qty,
  unit,
)

#subpar.grid(
  figure(
    table(
      columns: (1fr,) * 4,
      table.header[Case study][\# Nodes][\# Interfaces][\# Cells],
      [Toce], [6 716], [19 731], [12 996],
      [Toce _XL_], [406 115], [1 214 591], [808 457],
      [Square basin], [290 132], [868 393], [578 262],
    ),
    gap: 0.75em,
    caption: [Geometric description of meshes],
  ),
  <meshes>,
  figure(
    table(
      columns: (1fr,) * 3,
      table.header[Parameter][Toce][Square basin],
      [$t_"start"$ [#unit[s]]], [7], [0],
      [$t_"end"$ [#unit[s]]], [60], [60],
      [$n$ [#unit[-]]], [0.0162], [0.06],
      [$sigma$ [#unit[-]]], [0.9], [0.95],
      [$Delta t_"pics"$ [#unit[s]]], [1], [1],
      [$Delta t_"gauges"$ [#unit[s]]], [1], [],
      [$Delta t_"sections"$ [#unit[s]]], [1], [],
      [$Delta t_"enveloppes"$ [#unit[s]]], [1], [1],
    ),
    gap: 0.75em,
    caption: [Simulation parameters],
  ),
  <simulations>,
  columns: 1,
  caption: [Case study descriptions],
  kind: table,
  numbering: n => numbering("1.1", ..counter(heading.where(level: 1)).get(), n),
  numbering-sub-ref: (..n) => {
    numbering("1.1a", ..counter(heading.where(level: 1)).get(), ..n)
  },
  gap: 1em,
  placement: auto,
)