**Step 2**

Consider *ek*0,2. In Step 2, we show how to solve for *<sup>R</sup>*˜ *<sup>k</sup>*0,2, see Figure 5.

**Figure 5.** (**a**) Ω. (**b**) Subtree Ω<sup>2</sup> *k*0 , with *e*<sup>1</sup> = *ek*0,1.

Since *vk*<sup>0</sup> is the root of <sup>Ω</sup><sup>2</sup> *k*0 , the following equation is essentially a restatement of Lemma 1 to trees; the details of its proof are left to the reader.

$$\mathcal{R}\_{k\_0,2}(s) = \vec{r}\_{k\_0,2}(s) + \sum\_{m \ge 0} a\_m H(s - \check{\varsigma}\_m). \tag{39}$$

Here, 0 = *<sup>ξ</sup>*<sup>0</sup> < *<sup>ξ</sup>*<sup>1</sup> < ..., and *<sup>r</sup>*˜*k*0,2(*s*) ∈ F1. In what follows in Step 2, for readability, we rewrite *r*˜*k*0,2 as *r*˜.

Since we know -<sup>1</sup> and *q*1, we can solve the wave equation on *e*<sup>1</sup> with known boundary data. We identify *e*<sup>1</sup> as the interval (0, -<sup>1</sup>) with *vk*<sup>0</sup> corresponding to *<sup>x</sup>* = 0. Then *<sup>u</sup><sup>f</sup>* , restricted to *<sup>e</sup>*1, solves the following Cauchy problem, where we view *x* as the "time" variable:

$$\begin{aligned} u\_{tt} - u\_{xx} + q\_1 u &=& 0, \; x \in (0, \ell\_1), \; t > 0, \\ \partial u(\ell\_1, t) &=& f(t), \; t > 0, \\ u(\ell\_1, t) &=& (R\_{0,1} f)(t), \; t > 0, \\ u(x, 0) &=& 0, \; x \in (0, \ell\_1). \end{aligned}$$

Since the function *<sup>R</sup>*0,1(*s*) is known, we can thus uniquely determine *<sup>u</sup>f*(0, *<sup>t</sup>*) = *<sup>u</sup>f*(*vk*<sup>0</sup> , *<sup>t</sup>*) and *∂u<sup>f</sup>* <sup>1</sup> (*vk*<sup>0</sup> , *<sup>t</sup>*). Thus *<sup>p</sup>*(*t*) = *<sup>∂</sup>u<sup>δ</sup>* <sup>2</sup>(*vk*<sup>0</sup> , *t*) is determined.

We now show how *p* and *u<sup>δ</sup>* <sup>2</sup>(*vk*<sup>0</sup> , *<sup>t</sup>*) can be used to determine *<sup>R</sup>*˜ *<sup>k</sup>*0,2(*s*). The following equation follows from the definition of the response operators for any *<sup>f</sup>* ∈ *<sup>L</sup>*2:

$$\int\_0^t \mathcal{R}\_{k\_0, \mathcal{Z}}(s) p(t - s) ds = u\_2^\delta(v\_{k\_0 \prime} t) = \int\_0^t \mathcal{R}\_{k\_0, \mathcal{Z}}(s) \delta(t - s) ds. \tag{40}$$

In what follows, it is convenient to extend *<sup>f</sup>*(*t*) ∈ *<sup>L</sup>*2(0, *<sup>T</sup>*) as zero for *<sup>t</sup>* < 0. By Lemma <sup>1</sup> and by an adaptation of Lemma 2 to general trees, we have the following expansions:

$$R\_{k,2}(s) \quad = \quad r\_{k,2}(s) + \sum\_{n\geq 1} \phi\_n H(t - \gamma\_n) \ \ r\_{k,2}|\_{s \in (0, \mathfrak{f}\_1)} = 0, \ \nexists \ \ell\_1 = \ell\_1. \tag{41}$$

$$p(s) \quad = \quad a(s - \ell\_1) + \sum\_{l \ge 1} \psi\_l \delta(s - \zeta\_l) + \theta\_l H(s - \zeta\_l), \zeta\_1 = \nu\_1 = \ell\_1, \psi\_1 \ne 0, \tag{42}$$

Here, *rk*0,2 ∈ F<sup>1</sup> and *<sup>a</sup>*(*s*) ∈ F1, and {*ξk*} and {*βn*} are positive and increasing. Clearly *a*(*s*),*rk*0,2(*s*), {*ψm*}, {*θm*}, {*φn*}, {*γn*}, can all be determined by *R*0,1 and *Rk*0,2, whereas for now *r*˜ and the sets {*αm*}, {*ξm*} are unknown. Inserting (39),(41) and (42) into (40), we get

$$\begin{split} r\_{\mathbb{b},2}(t) + \sum\_{n} \phi\_{\mathbb{b}} H(t - \gamma\_{n}) &= \int\_{0}^{l} \mathbb{f}(s) a(t - s - \ell\_{1}) ds + \sum\_{l} \psi\_{l} \mathbb{f}(t - \zeta\_{l}) + \int\_{0}^{l} \sum\_{l} \theta\_{l} H(t - s - \zeta\_{l}) \mathbb{f}(s) ds \\ + \sum\_{m} a\_{m} \int\_{0}^{l} a(t - s - \ell\_{1}) H(s - \tilde{\zeta}\_{m}) ds + \sum\_{m,l} \psi\_{l} a\_{m} H(t - \zeta\_{l} - \zeta\_{m}) + \sum\_{m,l} \theta\_{l} a\_{m} \int\_{0}^{l} H(s - \tilde{\zeta}\_{m}) H(t - s - \zeta\_{l}) ds. \end{split} \tag{43}$$

Here all sums have 1 as lower limit of summation.

**Lemma 4.** *The sets* {*αm*}, {*ξm*} *can be determined by R*0,1 *and Rk*0,2*.*

**Proof.** We mimic an iterative argument in [26]. Differentiating (43) and then matching the delta singularities, we get

$$\sum\_{n\geq 1} \phi\_n \delta(t - \gamma\_n) = \sum\_{m\geq 1} \sum\_{l\geq 1} \psi\_l a\_m \delta(t - \mathbb{Z}\_l - \mathbb{Z}\_m) \,. \tag{44}$$

Since the sequences {*γn*}, {*ζl*}, {*ξm*} are all strictly increasing, clearly we have *γ*<sup>1</sup> = *ζ*<sup>1</sup> + *ξ*1, so that *φ*<sup>1</sup> = *α*1*ψ*1, and so *ξ*<sup>1</sup> = *γ*<sup>1</sup> − *ζ*<sup>1</sup> and *α*<sup>1</sup> = *φ*1/*ψ*1. We represent that the set {*φ*1, *γ*1}, {*ζ*1, *ψ*1} determines the set {*ξ*1, *α*1} by

{*φ*1, *γ*1}, {*ξ*1, *ψ*1} =⇒ {*ξ*1, *α*1}.

We now match the term *δ*(*t* − *γ*2) with its counterpart on the right hand side of (44). There are three possible cases.

**Case 1:** *γ*<sup>2</sup> = *ζ*<sup>2</sup> + *ξ*1.

In this case, we must have

$$
\zeta\_2 = \gamma\_2 - \zeta\_1, \ \varkappa\_2 = \phi\_2/\psi\_1.
$$

**Case 2a:** *γ*<sup>2</sup> = *ζ*<sup>2</sup> + *ξ*<sup>1</sup> and *φ*<sup>2</sup> = *ψ*2*α*1. Note that the last inequality can be verified by an observer at this stage. Then *γ*<sup>2</sup> = *ζ*<sup>1</sup> + *ξ*<sup>2</sup> and *φ*<sup>2</sup> = *ψ*1*α*<sup>2</sup> + *ψ*2*α*1. and hence

$$
\mathfrak{F}\_2 = \mathfrak{F}\_1 - \gamma\_2,\\
\mathfrak{a}\_2 = (\phi\_2 - \psi\_2 \alpha\_1) / \psi\_1.
$$

**Case 2b:** *γ*<sup>2</sup> = *ζ*<sup>2</sup> + *ξ*<sup>1</sup> and *φ*<sup>2</sup> = *ψ*2*α*1. Then *γ*<sup>2</sup> = *ζ*<sup>1</sup> + *ξ*2. Note we have not yet solved for {*ξ*2, *α*2}. In this case, we now repeat the matching coefficient argument just used with *δ*(*t* − *γ*3).

Again there are three cases:

Case 2bi: *γ*<sup>3</sup> = *ζ*<sup>3</sup> + *ξ*1. Note all of these terms are known, so this inequality can be verified. In this case, *γ*<sup>3</sup> = *ζ*<sup>1</sup> + *ξ*2, so *ξ*<sup>2</sup> = *γ*<sup>3</sup> − *ζ*<sup>1</sup> and *α*<sup>2</sup> = *φ*3/*ψ*1.

Case 2bii: *γ*<sup>3</sup> = *ζ*<sup>3</sup> + *ξ*<sup>1</sup> and *φ*<sup>3</sup> = *α*1*ψ*3. Then *γ*<sup>3</sup> = *ζ*<sup>1</sup> + *ξ*2, and *φ*<sup>3</sup> = *α*1*ψ*<sup>3</sup> + *α*2*ψ*1. Thus *ξ*<sup>2</sup> = *γ*<sup>3</sup> − *ζ*<sup>1</sup> and *α*<sup>2</sup> = (*φ*<sup>3</sup> − *α*1*ψ*3)/*ψ*1.

Case 2biii: *γ*<sup>3</sup> = *ζ*<sup>3</sup> + *ξ*<sup>1</sup> and *φ*<sup>3</sup> = *α*1*ψ*3. Then *γ*<sup>3</sup> < *ζ*<sup>1</sup> + *ξ*2, and we need to continue our procedure with *γ*4.

Repeating this procedure as necessary, say for a total of *N*<sup>2</sup> times, we solve for {*ξ*2, *α*2}. We represent this process as

$$\{\phi\_{k\prime}\gamma\_k\}\_{k=1}^{N\_2} \implies \{\xi\_{k\prime}^{\prime}\alpha\_k\}\_{k=1}^2.$$

We must have *N*<sup>2</sup> finite by (44) and the finiteness of the graph. Iterating this procedure, suppose for *<sup>p</sup>* <sup>∈</sup> <sup>N</sup> we have

$$\{\phi\_{k\prime}\gamma\_k\}\_{k=1}^{N\_p} \implies \{\xi\_{k\prime}^{\iota}\alpha\_k\}\_{k=1}^p.$$

Here *Np* is chosen to be minimal, and so *γNp* = *ζ*<sup>1</sup> + *ξ <sup>p</sup>*. We wish to solve for {*ζ <sup>p</sup>*+1, *φp*+1}. We can again distinguish three cases:

**Case 1:** *γ*(*Np*+1) <sup>=</sup> *<sup>ζ</sup><sup>k</sup>* <sup>+</sup> *<sup>ξ</sup>j*, <sup>∀</sup>*<sup>j</sup>* <sup>≤</sup> *<sup>p</sup>*, <sup>∀</sup>*k*. Note that we know {*ξj*}*<sup>p</sup>* <sup>1</sup> and {*ζk*}, so these inequalities are verifiable. In this case, we must have *γ*(*Np*+1) = *ζ*<sup>1</sup> + *ξ <sup>p</sup>*+<sup>1</sup> and *ψ*1*αp*+<sup>1</sup> = *φ*(*Np*+1), so we have determined *αp*+1, *ξ <sup>p</sup>*+<sup>1</sup> in this case.

**Case 2:** There exists an integer *<sup>Q</sup>* and pairs {*ζin* , *<sup>ξ</sup>jn* }*<sup>Q</sup> <sup>n</sup>*=1, with *jn* ≤ *p*, such that

$$
\gamma\_{(N\_p+1)} = \mathbb{Z}\_{i\_1} + \mathbb{Z}\_{j\_1} = \dots = \mathbb{Z}\_{i\_Q} + \xi\_{j\_Q}.\tag{45}
$$

Note that all the numbers {*ζin* , *ξjn* } have been determined, so these equations can be all verified. We can assume all pairs {*ζin* , *ξjn* } satisfying (45) with *jn* ≤ *p* are listed. In this case, we have either

Case 2i: *φ*(*Np*+1) = *αj*1*ψi*<sup>1</sup> + ... + *αjQ ψiQ* . It follows then that *γ*(*Np*+1) = *ζ*<sup>1</sup> + *ξ <sup>p</sup>*+1, and

$$
\phi\_{(N\_p+1)} = \alpha\_{p+1}\psi\_1 + \phi\_{j\_1}\psi\_{i\_1} + \dots + \phi\_{j\_Q}\psi\_{i\_Q}.
$$

We thus solve for *ξ <sup>p</sup>*+1, *αp*+1.

Case 2ii: *γ*(*Np*+1) = *φj*1*ψi*<sup>1</sup> + ... + *φjQ ψiQ* . It follows then that *α*(*Np*+1) = *ζ*<sup>1</sup> + *ξ <sup>p</sup>*+1, and we have to repeat this process with *γ*(*Np*+2).

Repeating the reasoning in Case 2ii as often as necessary, we eventually solve for {*ξ <sup>p</sup>*<sup>+</sup>1, *αp*+1}. Thus,

$$\{\phi\_{k\prime}\gamma\_k\}\_{k=1}^{N\_{p+1}} \implies \{\xi\_{k\prime}^{\iota}\alpha\_k\}\_{k=1}^{p+1}.$$

Hence, we can solve for {*ξ <sup>p</sup>* : *p* ≤ *L*}, {*α<sup>p</sup>* : *p* ≤ *L*} for any positive integer *L* given knowledge of *RT* 0,1, *<sup>R</sup><sup>T</sup> <sup>k</sup>*0,2 for *<sup>T</sup>* = *<sup>T</sup>*(*L*) sufficiently large.

It remains to solve for *r*˜. In what follows, we set *R*˜(*s*) = 0 for *s* < 0. We use *G*(*t*) to denote various functions that we have already established to be determined by *R*0,1 and *Rk*0,2. Having already solved for {*ξn*, *αn*}, we can eliminate from (43) the Heavyside functions to get, recalling *ζ*<sup>1</sup> = -1,

$$G(t) = \sum\_{l\geq 1} \psi\_l \overline{r}(t - \zeta\_l) + \int\_0^t \overline{r}(s) \left( a(t - s - \zeta\_1) \right) + \sum\_{l\geq 1} \theta\_l H(t - s - \zeta\_l) ds. \tag{46}$$

We solve this with an iterative argument. Let *α* = min*m*{*ζl*+<sup>1</sup> − *ζl*}. For *t* < *ζ*<sup>1</sup> + *α*, we have for *l* > 1 that *t* − *ζ<sup>l</sup>* < 0 so *r*(*t*) = 0. Hence

$$G(t) = \psi\_1 \overline{r}(t - \zeta\_1) + \int\_0^t \left(\theta\_1 H(t - s - \zeta\_1) + a(t - s - \zeta\_1)\right) \overline{r}(s)ds, \ t < \zeta\_1 + a. \tag{47}$$

Letting *r* = *t* − *ζ*1, we get

$$\begin{aligned} G(r) &= \quad \psi\_1 \overline{r}(r) + \int\_0^{r + \zeta\_1} \left( \theta\_1 H(r - s) + a(r - s) \right) \overline{r}(s) ds, \\ &= \quad \psi\_1 \overline{r}(r) + \int\_0^r \left( \theta\_1 H(r - s) + a(r - s) \right) \overline{r}(s) ds, \ r < a. \end{aligned}$$

We solve this VESK to determine *r*˜(*s*), *r* < *α*. Now for *t* < *ζ*<sup>1</sup> + 2*α*, we have for *l* > 1 that *t* − *ζ<sup>l</sup>* < *α*, and so those terms in (46) with *t* − *ζ<sup>l</sup>* can be absorbed in *G* to again give

$$G(r) = \psi\_1 \overline{r}(r) + \int\_0^r \left(\theta\_1 H(r - s) + a(r - s)\right) \overline{r}(s) ds, \; r < 2a.s$$

We solve this VESK to determine *r*˜(*s*), *r* < 2*α*. Iterating this procedure, we solve for *r*˜(*s*) for any finite *s*.

**Step 3** Because *Rk*0,*<sup>j</sup>* are determined by assumption for *<sup>j</sup>* <sup>=</sup> 2, ..., <sup>Υ</sup>*k*<sup>0</sup> <sup>−</sup> 1, the functions *<sup>u</sup><sup>f</sup> <sup>j</sup>* (*vk*<sup>0</sup> , *t*) are determined. In Step 2, we showed *u<sup>f</sup>* <sup>1</sup> (*vk*<sup>0</sup> , *<sup>t</sup>*) is also determined. Hence by (4), *<sup>u</sup><sup>f</sup>* Υ*k*0 (*vk*<sup>0</sup> , *t*) is also determined. We can now carry out the argument in Step 2 on the remaining edges *ek*0,3, ...,*ek*0,Υ*k*<sup>0</sup> incident on *vk*<sup>0</sup> to determine *<sup>R</sup>*˜ *<sup>k</sup>*0,*<sup>j</sup>* for all *<sup>j</sup>*.

**Step 4** For each *j* = 2, ..., Υ*k*<sup>0</sup> , we use Proposition 1, to find the associated *<sup>j</sup>*, *qj* together with the valence of the vertex adjacent to *vk*<sup>0</sup> . Careful reading of Steps 2 and 3 shows that we can use *<sup>R</sup><sup>T</sup>* 0,1 and *RT <sup>k</sup>*0,*<sup>j</sup>* for any *<sup>T</sup>* > <sup>2</sup>(-<sup>1</sup> + *j*).

**Step 5** Let *vk*<sup>1</sup> , ... be the vertices adjacent to *vk*<sup>0</sup> , other than *γ*0. We now iterate Steps 2–4 for the each of these vertices. Choose for instance *vk*<sup>1</sup> . If it were a boundary vertex, this fact would be determined in Step 4, and then this algorithm goes to the next vertex, which we, for convenience, still label *vk*<sup>1</sup> . We can thus assume *vk*<sup>1</sup> is an interior vertex. Let us label an incident edge (other than *e*<sup>2</sup> := *ek*0,2) as *e*<sup>3</sup> := *ek*1,3, see Figure 6.

**Figure 6.** For Step 5: a subtree of Ω<sup>2</sup> *k*0

.

We wish to determine *<sup>R</sup>*˜ *<sup>k</sup>*1,3. Mimicking Step 2, let *<sup>u</sup><sup>δ</sup>* solve (1)–(6), let *<sup>b</sup>*(*t*) = *<sup>∂</sup>u<sup>δ</sup>* <sup>3</sup>(*vk*<sup>1</sup> , *t*). We have the following formula holding by the definition of response operators:

$$\int\_0^t \mathcal{R}\_{k\_1,3}(s)\,b(t-s)ds = \int\_0^t \mathcal{R}\_{k\_1,3}(s)\delta(t-s)ds.$$

Of course *Rk*1,3(*s*) is assumed to be known. We determine *b* as follows. We have, from Step 2, that *p*(*t*) = *∂u<sup>δ</sup>* <sup>1</sup>(*vk*<sup>0</sup> , *t*) is known. We identify *e*<sup>2</sup> as the interval (0, -<sup>2</sup>) with *vk*<sup>1</sup> corresponding to *x* = 0.

Then *b*(*t*) = *∂u<sup>f</sup>* <sup>2</sup> (*vk*<sup>1</sup> , *t*) arises as a solution to the following Cauchy problem on *e*2, where we view *x* as the "time" variable:

$$\begin{aligned} y\_{tt} - y\_{xx} + q\_2 y &=& 0, \; x \in (0, \ell\_2), \; t > 0, \\ y\_x(\ell\_2, t) &=& p(t), \; t > 0 \\ y(\ell\_2, t) &=& (R\_{k\_0 2} \delta)(t), \; t > 0 \\ y(x, 0) &=& 0, \; x \in (0, \ell\_2). \end{aligned}$$

Since *q*2, -2, and *Rk*0,2 are all known, we can thus determine *b*(*t*) = *yx*(0, *t*).

The rest of the argument here is a straightforward adaptation of Steps 2–4 above. The details are left to the reader.

**Step 6** Arguing as in Step 5, we determine *<sup>R</sup>*˜ *<sup>k</sup>*,*<sup>j</sup>* for all other vertices adjacent to *vk*<sup>0</sup> and their associated edges. The details are left to the reader.

**Steps above 6** Clearly this procedure can be iterated until all edges of our finite graph have been covered.

#### **5. Conclusions**

In this paper, we applied the ideas of the boundary control and leaf peeling methods to solve an inverse problem on a tree featuring non-standard, delta-prime vertex conditions on the interior. Our method required using only one boundary actuator and one boundary sensor, all other observations being internal. Using the Neumann-to-Dirichlet map (acting from one boundary vertex to one boundary and all internal vertices) we recovered the topology and geometry of the graph together with the coefficients *qj* of the equations. It would be interesting to see a numerical implementation of our method. It would also be interesting to adapt our methods to quantum graphs with cycles.

**Author Contributions:** Conceptualization, S.A. and J.E.; methodology, S.A. and J.E.; formal analysis, S.A. and J.E.; writing—original draft preparation, S.A. and J.E.; writing—review and editing, S.A. and J.E. All authors have read and agreed to the published version of the manuscript.

**Funding:** The research of the first author was supported in part by the National Science Foundation, grant DMS 1909869.

**Conflicts of Interest:** The authors declare no conflict of interest. The funders had no role in the design of the study; in the collection, analyses, or interpretation of data; in the writing of the manuscript, or in the decision to publish the results.

#### **Abbreviations**

The following abbreviations are used in this manuscript:

VESK Volterra equation of the second kind

#### **References**


**Publisher's Note:** MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

© 2020 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).
