1 Introduction

In curved spacetime, conserved energy for matter fields can be obtained from the energy–momentum tensor of the Einstein equation, but this is not applicable for a gravitational field. Instead, we should extract the conserved energy from the metric or the Riemann tensor, but constructing the concept of gravitational energy was an arduous task in the early days of general relativity due to the unification of space and time. Another difficulty was that in curved spacetime physical quantities are computed locally, whereas there is no meaningful local notion of energy density of the gravitational field to construct a conserved charge in general relativity.

Notwithstanding these difficulties, the global charge for a gravitational field was first successfully obtained in 1959 by Arnowitt, Deser, and Misner, which is known as the ADM mass [1,2,3,4]. Through this approach, spacetime is decomposed into a spatial hypersurface foliated by time so that the traditional canonical method is applied for a gravitational field at spatial infinity. The ADM result implies that a global charge is independent of the choice of a coordinate. Based on this success Komar alternatively constructed a conserved charge formula by using a Killing vector field,

$$\begin{aligned} Q_{\xi } = \frac{c}{16 \pi G} \lim _{S_{t} \rightarrow \infty } \oint _{S_{t}} \nabla ^{\alpha } \xi ^{\beta } \mathrm{{d}}S_{\alpha \beta } \end{aligned}$$
(1)

where \(c=-2\) for a timelike Killing vector field and \(c=1\) for a rotational Killing vector field which give mass and angular momentum for a gravitational field, respectively. Later, various methods such as the AD(T) method [5, 6], Brown–York’s quasilocal method [7], and the covariant phase space method [8, 9] have been developed for calculating a global charge of a gravitational field. Nevertheless there are cases that are technically involved when applying these methods to systems such as the charged rotating black hole. For that case, in 1973 [10] Smarr found that a mass parameter, M, can be expressed by a simple algebraic relation between physical variables. By applying Euler’s theorem the black hole charge M is written as

$$\begin{aligned} M = 2 T_{\text {eff}} A + 2 \Omega L + \Phi Q \end{aligned}$$
(2)

where \(T_{\text {eff}} = \frac{{\tilde{\kappa }}}{8 \pi }\) is an effective surface gravity, A is the black hole area, \(\Omega \) is an angular velocity, L is an angular momentum, \(\Phi \) is an electromagnetic potential, and Q is the charge of the electromagnetic field. It is important to note that the mass is expressed in a bilinear form of other physical variables. The differential form of mass, \(\mathrm{{d}}M\), was also shown in the paper to be

$$\begin{aligned} \mathrm{{d}}M = T_{\text {eff}} \mathrm{{d}}A + \Omega \mathrm{{d}}L + \Phi \mathrm{{d}}Q. \end{aligned}$$
(3)

Soon afterward, Bardeen et al. published the same results as (2) and they interpreted (3) in an analogous way to the first law of thermodynamics by correspondence of \(4 T_{\text {eff}}= T = \frac{{\tilde{\kappa }}}{2 \pi }\) to the real temperature and \(S=\frac{A}{4G}\) to the entropy [11]. At that time, those authors considered that T and S should be distinct from real temperature and entropy. Later Bekenstein argued that S could be the real entropy of black holes [12,13,14], and Hawking further corroborated this by showing that black holes radiate as thermal objects at a temperature of precisely \(\frac{{\tilde{\kappa }}}{2 \pi }\) [15, 16].

All of this work was developed using asymptotic charges. However, it is important to describe the physical variables of a gravitational system in a quasilocal frame for several reasons. First, the quasilocal quantities could describe more realistic and detailed physical situations, such as binary stars or black hole mergers. Second, spatial infinity cannot be realized in numerical work, but rather finite domains are always required. Numerical studies of collapse also often track apparent horizons which are quasilocal in nature, to be compared to event horizons [17, 18]. Several quasilocal formalisms have been suggested [19], and the first law of black hole thermodynamics in a quasilocal frame is studied in Brown–York’s work [7]. In such work, the subtraction background method is employed to render the gravity action finite, and the boundary energy–momentum stress tensor is constructed so as to define quasilocal quantities. They showed that the first law of thermodynamics in a finite domain for the four-dimensional Schwarzchild black hole is

$$\begin{aligned} \mathrm{{d}} E = T_{\text {Tolman}} \mathrm{{d}} S + P \mathrm{{d}}A \end{aligned}$$
(4)

where the Bekenstein–Hawking entropy S is used, satisfying the area law. P is the surface pressure and A is the area of a quasilocal surface with a certain radius, for example \(r=R\). E is the quasilocal energy and \(T_{\text {Tolman}}\) is the Tolman temperature, defined by

$$\begin{aligned} T_{\text {Tolman}} = \frac{1}{N(R)} T_{\text {Hawking}} = \frac{1}{N(R)} \frac{{\tilde{\kappa }}}{2 \pi } \end{aligned}$$
(5)

where \({\tilde{\kappa }}\) is the surface gravity at the black hole horizon and N(R) is the lapse function evaluated on the quasilocal boundary. Hereafter we denote the Tolman temperature \(T_{\text {Tolman}}\) as \(T_{\text {R}}\), which means the temperature measured at \(r=R\) and the Hawking temperature \(T_{\text {Hawking}}\) as \(T_{\text {H}}\) which is measured by an observer at infinity.

Historically the Smarr relation was discovered as a consequence of the scaling relations present amongst the parameters in black hole thermodynamics and it can be obtained by geometric means. In this development the Smarr relation has been only associated with the Hawking temperature but not with the Tolman temperature. Thus we here aim to completely and consistently describe the Smarr relation and other thermodynamic relations by extending their notion at infinity to a quasilocal frame. In order to do so, we firstly employ the Brown–York qusilocal formalism and adopt a Mann–Marolf (MM) counterterm to construct a renormalized gravity action rather than using the subtraction method. This is because the MM-counterterm is more widely applicable to complicated spacetimes such as a spacetime with dilaton. We also show the electric and magnetic potential form in a quasilocal frame. Next we define a quasilocal thermodynamic potential through the Euclidean action combined with the Tolman temperature to obtain the entropy in a quasilocal frame. Here the quasilocal thermodynamic potential takes a different form for electrically or magnetically charged cases. Since they impose a different boundary condition on the Euclidean on-shell action the formal case yields the thermodynamic potential with the fixed gauge potential (grand potential) but the latter one yields the thermodynamic potential with the fixed charge (free energy) in [20] unless introducing the boundary term for the gauge field. From this construction we found that the surface pressure and its conjugate variable do not occur in the quasilocal thermodynamic potential and the entropy in a quasilocal frame agrees with the Bekenstein–Hawking entropy. For the case of a dilaton field, we found that there is no dilaton contribution in the thermodynamic potential. Then we formulate a quasilocal Smarr relation from Euler’s theorem. While the surface pressure and its quasilocal area occur in the relation, the dilaton field and its conjugate potential do not enter the relation since the length dimension of the dilaton field is zero. In the quasilocal first law the surface pressure terms are present but dilaton terms are only present for dynamical dilaton case. Thus the quasilocal thermodynamic relations can be summarized as follows:

$$\begin{aligned} F_\text {R}&= E -T_\mathrm{{R}} S - \Phi _{\text {R,e}} Q_\text {e} \end{aligned}$$
(6)
$$\begin{aligned} E&= 2T_\text {R} S + 2 P A + \Phi _{\text {R,e}} Q_\text {e} + \Phi _{\text {R,m}} Q_\text {m} ,\end{aligned}$$
(7)
$$\begin{aligned} \mathrm{{d}}E&= T_{\text {R}} \mathrm{{d}}S + P\mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}}Q_{\text {m}} + \Pi _{\text {R}} \mathrm{{d}}\phi _{\text {R}}, \end{aligned}$$
(8)

for the four-dimensional dyonic black hole with dynamic dilaton and where \(\phi _\mathrm{{R}}\) and \(\Pi _\mathrm{{R}}\) are the dilaton field and its conjugate potential in a quasilocal frame, respectively, and

$$\begin{aligned} F_\text {R}&= E -T_\mathrm{{R}} S - \Phi _{\text {R,e}} Q_\text {e} \end{aligned}$$
(9)
$$\begin{aligned} (n-3)E&= (n-2)T_\text {R} S + (n-2) P A + (n-3) \Phi _{\text {R,e}} Q_\text {e} , \end{aligned}$$
(10)
$$\begin{aligned} \mathrm{{d}}E&= T_{\text {R}} \mathrm{{d}}S + P\mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Pi _{\text {R}} \mathrm{{d}}\phi _{\text {R}}, \end{aligned}$$
(11)

for an n-dimensional electrically charged black hole with a dynamic dilaton. For the non-dynamic dilaton case, there is no dilaton contribution in the first law. Based on this formulation, we investigate the quasilocal thermodynamics for various black hole spacetimes in Einstein–Maxwell-dilaton theory.

This paper is organized as follows. In Sect. 2, we introduce the quasilocal formulations which are used in this paper. Firstly the Mann–Marolf counterterm and Brown–York’s formalism are briefly explained along with the construction of the renormalized gravity action, and the free energy (or thermodynamic potential) in a quasilocal frame is defined by the Euclidean method to derive the entropy in a quasilocal frame. Then a quasilocal Smarr relation is constructed from the Eulerian theorem for an electrically charged black hole in n-dimensional spacetime. In Sects. 3 and 4, we check these quasilocal thermodynamic relations with various black hole solutions from the Einstein–Maxwell (-dilaton) theory. Lastly, we summarize our results and discuss future work.

2 The quasilocal formulation

In this section we provide the quasilocal thermodynamic relations. Throughout this paper we consider an n-dimensional spacetime \(({\mathcal {M}},g)\) and denote its index \(\mu =0, \ldots ,n-1\). The timelike boundary \((\partial {\mathcal {M}},h)\) is a timelike hypersurface defined by a spacelike normal vector \(n^{\mu }\) and we denote its index \(a=0,2, \ldots , n-1\). Finally, the spatial boundary of a constant time slice \((B,\sigma )\) is a spacelike hypersurface which is normal to both of the spacelike normal vector \(n^{\mu }\) and a timelike normal vector \(u^{a}\) and we denote its index by \(A=2, \ldots , n-1\). Physically, B is the geometry of the quasilocal boundary and \(\partial {\mathcal {M}}\) is the evolution of B through time.

2.1 Mann–Marolf counterterm

It is well known that a gravity action diverges for a non-compact spacetime as r goes to infinity, while a compact spacetime does not have such a divergence. For an asymptotically flat spacetime, this divergence is mainly due to a surface term which is known as the Gibbons–Hawking (GH) term. As a remedy, a non-dynamical term is introduced in the action so as to remove the divergence. Here the non-dynamical term should not alter the equation of motion but render the total gravity action finite,

$$\begin{aligned} I_{\text {remormailzed}} = I_{\text {EH}} + I_{\text {GH}} + I_{\text {non-dynamical}}. \end{aligned}$$
(12)

To generate this non-dynamical term, the reference background approach was suggested in [21]. However, if the dimension of spacetime is higher than three, the existence or uniqueness of such embeddings of a hypersurface \((\partial {\mathcal {M}}, h)\) into a proper reference frame \(({\mathcal {M}}_{\text {Ref}},g_{\text {Ref}})\) is not clear. On the other hand, as the interest in AdS/CFT theory has increased, the algorithm to generate counterterms as a non-dynamical term have been well constructed for AdS spacetime firstly in [22] and later also studied in [23,24,25,26]. The same algorithm for generating counterterms, unfortunately, is not applicable to an asymptotically flat spacetime. However, the Mann–Marolf (MM) counterterm method provides one way to generate counterterms for an asymptotically flat spacetime and is described as follows.

The gravity action is written as

$$\begin{aligned} I = \frac{1}{\kappa ^{2}} \int _{{\mathcal {M}}} \sqrt{-g} R + \frac{2}{\kappa ^{2}} \int _{\partial {\mathcal {M}}} \sqrt{-h} (K - {\hat{K}}) \end{aligned}$$
(13)

where \({\hat{K}}\) is a solution of

$$\begin{aligned} {\mathcal {R}}_{ab} = {\hat{K}}_{ab} {\hat{K}} - {\hat{K}}_{a}^{\; c} {\hat{K}}_{cb} \end{aligned}$$
(14)

where \({\mathcal {R}}_{ab}\) is the Ricci tensor on the boundary \(\partial {\mathcal {M}}\). This counterterm is known to be local and covariant. Equation (14) is motivated by the Gauss–Codazzi equation for a timelike hypersurface, which is described as follows:

$$\begin{aligned} {\mathcal {R}}_{acbd} = R^{\text {Ref}}_{acbd} + K_{ab}K_{cd} - K_{cb}K_{ad} \end{aligned}$$
(15)

where \({\mathcal {R}}_{acbd}\) is the Riemann tensor on \(\partial {\mathcal {M}}\) compatible with the induced metric h and \(R^{\text {Ref}}_{acbd}\) is the Riemann tensor of \(({\mathcal {M}}_{\text {Ref}},g_{\text {Ref}})\) pulled back to \(\partial {\mathcal {M}}\), and is obtained by taking advantage of a reference background approach on a hypersurface near infinity. Taking the Minkowski spacetime as a reference frame, then \(R^{\text {Ref}}_{acbd}\) becomes zero and contracting (15) with \(g^{cd}\) yields (14).

Considering a general form of the metric in n-dimensional spacetime,

$$\begin{aligned} \mathrm{{d}}s^{2}&= N^{2} \mathrm{{d}}r^{2} + h_{ab} \mathrm{{d}}x^{a} \mathrm{{d}}x^{b} \nonumber \\&= \bigg (1+ \frac{\alpha }{r^{n-3}} \bigg )^{2} \mathrm{{d}}r^{2} \nonumber \\&\quad + \bigg ( h^{(0)}_{ab} + \frac{1}{r^{n-3}}h^{(1)}_{ab} + \frac{1}{r^{n-2}} h^{(2)}_{ab} + \cdots \bigg )\mathrm{{d}}x^{a} \mathrm{{d}}x^{b} \end{aligned}$$
(16)

where

$$\begin{aligned}&h_{ab} \mathrm{{d}}x^{a} \mathrm{{d}}x^{b} =\nonumber \\&\quad - \bigg ( 1 + \frac{\gamma ^{(1)}}{r^{n-3}} + \frac{\gamma ^{(2)}}{r^{n-2}} + \cdots \bigg ) \mathrm{{d}}t^{2} \nonumber \\&\quad + r^{2} \bigg (\mu ^{(0)}_{AB} + \frac{1}{r^{n-3}} \mu ^{(1)}_{AB} + \frac{1}{r^{n-2}} \mu ^{(2)}_{AB} + \cdots \bigg ) \mathrm{{d}} \eta ^{A} \mathrm{{d}} \eta ^{B}. \end{aligned}$$
(17)

Choosing \(\partial {\mathcal {M}}\) to be cylindrical \(\Omega ^{\mathrm {cyl}}\) such as

$$\begin{aligned} \Omega ^{\mathrm {cyl}} = r + O(r^{0}), \end{aligned}$$
(18)

the solution of (14) is calculated for four dimensions and for more than four dimensions,

$$\begin{aligned} (n=4) \; \; {\hat{K}}_{ab}&= r \mu ^{(0)}_{ab} + \frac{1}{2} \mu ^{(1)}_{ab} + D_{a}D_{b} \alpha + \cdots \end{aligned}$$
(19)
$$\begin{aligned} (n>4) \; \; {\hat{K}}_{ab}&= r \mu ^{(0)}_{ab} + \frac{1}{(n-4) r^{n-5}} \bigg [ (n-4)\mu ^{(1)}_{ab} \nonumber \\&\quad + \alpha \mu ^{(0)}_{ab} + \gamma ^{(1)} \mu ^{(0)}_{ab} +D_{a} D_{b} \alpha \bigg ] + \cdots \end{aligned}$$
(20)

where the higher sub-leading terms of order of r are omitted here, but up to the sub-sub-leading term of order of r are computed in [27]. In the asymptotically flat case, the leading term of the counterterm removes the divergence of the gravity action and sub-leading terms give corrections to the finite parts of the action. In this paper we consider up to the first sub-leading term of the MM-counterterm solutions, as displayed in (19) and (20). Even in the presence of matter fields, the MM-counterterm (19) and (20) can be still utilized, as long as the matter fields do not generate any divergent behavior in the action as r goes to infinity and a metric form is taken into (16).

2.2 BY method and electric/magnetic charge potential

The Hawking temperature is defined relative to an observer located where a timelike Killing vector field has unit norm, \(\sqrt{-\xi ^{\mu } \xi _{\mu }} = 1\), which indicates the observer is located at infinity in an asymptotically flat spacetime. As a consequence, any stationary observer at finite radius will measure a redshifted temperature known as the Tolman temperature (5). Associated with this local temperature, quasilocal thermodynamic quantities should be defined accordingly.

One of the quasilocal formalisms was constructed by Brown and York in [7]. Here we employ their method. In order to construct the renormalized action, the MM-counterterm is taken as follows:

$$\begin{aligned} I_{\text {remormailzed}} = I_{\text {EH}} + I_{\text {GH}} + I_{\text {MM-counterterm}}, \end{aligned}$$
(21)

and this produces the Brown–York boundary stress energy–momentum tensor, which is defined as

$$\begin{aligned} \tau ^{ab} = \frac{2}{\sqrt{-h}} \frac{\delta I_{cl}}{\delta h_{ab}} = \frac{2}{\kappa ^{2}}(\pi ^{ab} - {\hat{\pi }}^{ab}) \end{aligned}$$
(22)

where \(I_{cl}\) is the on-shell action of \(I_{\text {remormailzed}}\), \(\pi _{ab} = K_{ab} - K h_{ab}\), and \({\hat{\pi }}_{ab} = {\hat{K}}_{ab} - {\hat{K}} h_{ab}\). This tensor yields a quasilocal energy density \(\epsilon \), proper momentum surface density \(j_{A}\) and boundary stress \(s^{AB}\) as follows:

$$\begin{aligned} \varepsilon \equiv u_{a} u_{b} \tau ^{ab}, \qquad j_{A} \equiv - \sigma _{Aa}u_{b} \tau ^{ab}, \qquad s^{AB} \equiv \sigma ^{A}_{a} \sigma ^{B}_{b} \tau ^{ab}, \end{aligned}$$
(23)

where \(u_{a}\) is a timelike normal vector field, \(\sigma _{AB}\) is an induced metric on the hypersurface B. In n-dimensional spacetime, surface pressure is defined by

$$\begin{aligned} P = - \frac{1}{(n-2)} \tau _{ab} \sigma ^{ab} \end{aligned}$$
(24)

where \(\sigma ^{ab}\) is the pull-back of \(\sigma ^{AB}\). The quasilocal energy contained within B is obtained by surface integration,

$$\begin{aligned} E = \int _{B} d^{n-2} x \sqrt{\sigma } \varepsilon , \end{aligned}$$
(25)

and the conserved quantity along the Killing vector field, \(\xi \), is defined by

$$\begin{aligned} Q_{\xi } = \int _{B} d^{n-2} x \sqrt{\sigma } (\varepsilon u^{i} + j^{i}) \xi _{i}. \end{aligned}$$
(26)

In the presence of matter fields such as a non-abelian gauge field \({{\mathcal {A}}}_{\mu }\), the total electric charge \(Q_\text {e}\) which is confined inside of an event horizon is defined as

$$\begin{aligned} Q_{\text {e}} = \int *{{\mathcal {F}}} \end{aligned}$$
(27)

where \({{\mathcal {F}}}\) is a field strength, which is

$$\begin{aligned} {{\mathcal {F}}}_{\mu \nu } = \partial _{\mu } {{\mathcal {A}}}_{\nu } - \partial _{\nu } {{\mathcal {A}}}_{\mu }, \quad *{{\mathcal {F}}} = \frac{1}{2} \epsilon _{\mu \nu \alpha \beta } {{\mathcal {F}}}^{\alpha \beta } \mathrm{{d}}x^{\mu } \wedge \mathrm{{d}}x^{\nu }. \end{aligned}$$
(28)

An electric potential measured by an observer with a four-velocity \(u^{\mu }\) is given by [28]

$$\begin{aligned} \Phi _{\text {e}} (r) = {{\mathcal {A}}}_{\mu }(r) u^{\mu }(r) \bigg |^{r_{h}}_{r}. \end{aligned}$$
(29)

A magnetic charge in four dimensions is defined as

$$\begin{aligned} Q_{\text {m}} = \int {{\mathcal {F}}}, \end{aligned}$$
(30)

and due to the electromagnetic duality we can construct \({{\mathcal {A}}}^{*}_{\mu }\) as follows:

$$\begin{aligned} *{{\mathcal {F}}}_{\mu \nu } = \partial _{\mu } {{\mathcal {A}}}^{*}_{\nu } - \partial _{\nu } {{\mathcal {A}}}^{*}_{\mu },\qquad \end{aligned}$$
(31)

and a magnetic potential measured by an observer with a four-velocity \(u^{\mu }\) can be defined as

$$\begin{aligned} \Phi _{\text {m}}(r) = {{\mathcal {A}}}^{*}_{\mu }(r) u^{\mu }(r) \bigg |^{r_{h}}_{r}. \end{aligned}$$
(32)

2.3 Quasilocal thermodynamic potential

Here we aim to find the black hole entropy in a quasilocal frame. In order to do so, we define a quasilocal thermodynamic potential via the Euclidean method.

Black hole thermodynamics can be understood by a path integral at finite temperature in Euclidean space, which is generated by doing a Wick rotation \(\tau \rightarrow i t\) from the Lorentzian one. Then the partition function is written as

$$\begin{aligned} Z = \int D[g] D[\Psi ] e^{-I_{E}[g,\Psi ]/\hbar } \end{aligned}$$
(33)

where g is a fluctuation of the metric and \(\Psi \) are matter fields. Taking a saddle point approximation the partition function is approximated to

$$\begin{aligned} Z \sim e^{-I_{E}[g,\Psi ]/\hbar }. \end{aligned}$$
(34)

In the calculation of the Euclidean action \(I_E\), when we consider the boundary of spacetime at infinity, the radial coordinate r is integrated from the black hole horizon to infinity. The Euclidean time integration should give the periodicity \(\beta \) at the black hole horizon to avoid a conical singularity. Then it yields the inverse of the Hawking temperature, \(\int \mathrm{{d}} \tau = \beta = \frac{1}{T_{\text {H}}}\), which is consistent with the surface gravity having unit norm of the timelike Killing vector field. That is, the Euclidean time periodicity \(\beta \) is imposed at the horizon relative to the observer at infinity. Then we define the free energy (or thermodynamic potential) as follows:

$$\begin{aligned} F = - T_{\text {H}} \log Z \sim T_{\text {H}} I_{E,(r_{h},\infty )} = M - T_{\text {H}} S (- \Phi _{\text {e}} Q_{\text {e}}), \end{aligned}$$
(35)

where M is the conserved charge and \(\Phi _{\text {e}}\) is measured between the horizon and infinity.

Now we extend this formula to a quasilocal frame by considering the boundary of spacetime at the finite domain \(r=R\). The radial coordinate r is integrated from the horizon to the finite distance of \(r=R\) and then the time periodicity should be relative to the observer at \(r=R\), which is described by \(\int \mathrm{{d}} \tau ' = N(R)\int \mathrm{{d}}\tau = N(R)\beta = \frac{1}{T_{\text {R}}}\). Thus the Hawking temperature is replaced by the Tolman temperature. By doing so we define quasilocal free energy as follows:

$$\begin{aligned} F_{R} \equiv - T_{\text {R}} \log Z \sim T_{\text {R}} I_{E, (r_{h}, R)} = E - T_{\text {R}} S (- \Phi _{\text {R,e}} Q_{\text {e}}) \end{aligned}$$
(36)

where E is quasilocal energy and the electric potential, \(\Phi _{\text {R,e}}\), is measured to the finite distance \(r=R\). By obtaining this quasilocal free energy from the Euclidean on-shell action value we can derive the entropy in a quasilocal frame, which turns out to be the same as the Bekenstein–Hawking entropy from our examples in next sections.

2.4 Quasilocal Smarr relation by Euler’s theorem

In [10], Euler’s theorem on homogeneous functions is used to obtain the Smarr relation. Euler’s theorem states that, if a function f(xyz) obeys the scaling relation

$$\begin{aligned} f(\alpha ^p x, \alpha ^q y, \alpha ^k z) = \alpha ^r f(x,y,z), \end{aligned}$$
(37)

it satisfies

$$\begin{aligned} r f(x,y,z) = p \left( \frac{\partial f}{\partial x} \right) x + q \left( \frac{\partial f}{\partial y} \right) y + k \left( \frac{\partial f}{\partial z} \right) z. \end{aligned}$$
(38)

Applying this theorem to black hole systems for Einstein–Maxwell theory in four dimensions, a black hole charge M can be considered as a homogeneous function of entropy S and the Maxwell charge Q. These variables have the following scaling properties:

$$\begin{aligned} M \propto [L], \; \; \; S \propto [L]^{2}, \; \; \; Q \propto [L] \end{aligned}$$
(39)

where [L] is length dimension. Then Euler’s theorem yields

$$\begin{aligned} M&= 2 \bigg (\frac{\partial M}{\partial S} \bigg ) S + \bigg (\frac{\partial M}{\partial Q} \bigg ) Q = 2 T_{\text {H}} S + \Phi Q. \end{aligned}$$
(40)

Note that here we employ the natural units, \(c=\hbar =1\), and additionally impose the gravitational constant \(G=1\), which leads to a dimensionful action, \(I \propto [L]^{2}\).

Let us extend this argument to a quasilocal frame. In this case a family of timelike hypersurfaces exists for \(r=\mathrm{{constant}}\) and one specific hypersurface can be chosen, for example \(r=R\). Thus the quasilocal energy E becomes a homogeneous function of entropy S and the Maxwell charge Q, but also a quasilocal area A whose radius is R. Their scaling properties are found as

$$\begin{aligned} E \propto [L], \; \; \; S \propto [L]^{2}, \; \; \; Q \propto [L], \; \; \; A \propto [L]^{2}. \end{aligned}$$
(41)

So Euler’s theorem yields the following relation:

$$\begin{aligned} E&= 2 \bigg (\frac{\partial E}{\partial S} \bigg ) S + \bigg (\frac{\partial E}{\partial Q} \bigg ) Q + 2 \bigg (\frac{\partial E}{\partial A} \bigg ) A \nonumber \\&= 2 T_{\text {R}} S + \Phi _{\text {R}} Q + 2 P A , \end{aligned}$$
(42)

where a new term PA arises. When r goes to infinity the surface pressure P vanishes and the quasilocal Smarr relation is restored to (40). The electric potential (29) should be measured by an observer placed at \(r=R\) to be consistent with the Tolman temperature (5). When considering Einstein–Maxwell-dilaton theory we should investigate the participation of a dilaton field, \(\phi (r)\), to the quasilocal Smarr relation. The conjugate variable of the dilaton field is defined by [29]

$$\begin{aligned} \Pi (r)= \int \mathrm{{d}}^{2}x \sqrt{\sigma } n_{\mu } \partial _{\nu } \phi g^{\mu \nu }, \quad \Pi _{\text {R}} = \Pi (R)-\Pi (\infty ) \end{aligned}$$
(43)

where the dilaton potential \(\Pi _{\text {R}}\) is calibrated to be zero at infinity. However, since the length dimension of the dilaton field is \(\phi \propto [L]^{0}\) it does not contribute to the quasilocal Smarr relation.

If we expand this argument to n-dimensional spacetime, each variable has a length dimension as

$$\begin{aligned} E \propto [L]^{n-3}, \; \; \; S \propto [L]^{n-2}, \; \; \; A \propto [L]^{n-2}, \; \; \; Q \propto [L]^{n-3}, \; \; \; \phi \propto [L]^{0}, \end{aligned}$$
(44)

and Euler’s theorem yields the relation as follows:

$$\begin{aligned} (n-3) E&= (n-2) \left( \frac{\partial E}{\partial S} \right) S + (n-3) \left( \frac{\partial E}{\partial Q} \right) Q \nonumber \\&\quad + (n-2) {\left( \frac{\partial E}{\partial A} \right) A} \end{aligned}$$
(45)
$$\begin{aligned}&= (n-2) T_{\text {R}} S + (n-3) \Phi _{\text {R}} Q_ + (n-2) PA, \end{aligned}$$
(46)

which is the n-dimensional quasilocal Smarr relation for Einstein–Maxwell (-dilaton) theory. The thermodynamic first law associated with this Smarr relation in a quasilocal frame is written as

$$\begin{aligned} \mathrm{{d}} E = T_{\text {R}} \mathrm{{d}}S + \Phi _{\text {R}} \mathrm{{d}} Q + P \mathrm{{d}} A + \Pi _{\text {R}} \mathrm{{d}}\phi _{\text {R}} \end{aligned}$$
(47)

where \(\phi _{\text {R}} = \phi (R)\). Even though the dilaton field does not participate in the quasilocal Smarr relation it has an effect on the quasilocal first law [29].

These results are compared with the thermodynamic properties for Einstein–Maxwell (-dilaton) theory at infinity, which are described by

$$\begin{aligned} (n-3) M&= (n-2) T_{\text {H}} S + (n-3) \Phi Q, \end{aligned}$$
(48)
$$\begin{aligned} \mathrm{{d}}M&= T_{\text {H}} \mathrm{{d}} S + \Phi \mathrm{{d}} Q \end{aligned}$$
(49)

where \(\Phi \) is measured from the horizon to infinity. We examine this quasilocal Smarr relation (45) and the first law (47) with black hole solutions for Einstein and Einstein–Maxwell theory in n-dimensional spacetime in Sect. 3 and for Einstein–Maxwell-dilaton theory in four-dimensional spacetime in Sect. 4.

3 Einstein–Maxwell Theory

In this section, we consider several black hole solutions for Einstein(–Maxwell) theory in an asymptotically flat spacetime and check if our quasilocal formulation is satisfied. Firstly we start with a four-dimensional Schwarzschild black hole solution, and find its quasilocal first law along with the quasilocal Smarr relation. We also explore the Reissner–Nordström black hole and its higher-dimensional generalization.

3.1 Schwarzschild black holes

Let us write the Schwarzschild black hole spacetime (\({\mathcal {M}},g\)) in the form of

$$\begin{aligned} \mathrm{{d}}s^{2} = - N(r)^{2} \mathrm{{d}}t^{2} + f(r)^{2} \mathrm{{d}}r^{2} + r^{2} \mathrm{{d}} \Omega _{2} \end{aligned}$$
(50)

where

$$\begin{aligned} N(r) = \frac{1}{f(r)} = \sqrt{1 - \frac{2M}{r}}. \end{aligned}$$
(51)

Assuming an observer on a hypersurface (\(\mathcal {\partial M}, h\)) at \(r=R\), the temperature measured by this observer is given by (5)

$$\begin{aligned} T_{\text {R}} = \frac{1}{N(R)} \frac{1}{4 \pi r_{h}}. \end{aligned}$$
(52)

The quasilocal energy density and surface pressure are obtained as follows:

$$\begin{aligned} \varepsilon&=u_{i}u_{j} \tau ^{ij} = \frac{4}{\kappa ^{2}} \bigg ( \frac{1}{r} - \frac{1}{r f(r)} \bigg )\bigg |_{r=R} \nonumber \\&= \frac{4}{\kappa ^{2}} \bigg (\frac{1}{R} - \frac{1}{R f(R)} \bigg ), \end{aligned}$$
(53)
$$\begin{aligned} P&= - \frac{1}{2} \sigma _{ab} s^{ab} = -\frac{2}{\kappa ^{2}} \bigg (\frac{N'(r)}{f(r)N(r)} + \frac{1}{r f(r)} - \frac{1}{r} \bigg ) \bigg |_{r=R} \nonumber \\&= -\frac{2}{\kappa ^{2} R} \bigg (\frac{1}{N(R)} \bigg (1 - \frac{r_{h}}{2R} \bigg ) - 1 \bigg ), \end{aligned}$$
(54)

where

$$\begin{aligned} N(R) = \frac{1}{f(R)} = \sqrt{1 - \frac{r_{h}}{R} } \end{aligned}$$
(55)

and \(N(r_{h}) = 0\) is used. The total quasilocal energy is obtained by integrating the quasilocal energy density (53) over the hypersurface at constant time (\(B, \sigma \)) and is found to be

$$\begin{aligned} E(r_{h}, R) = \int _{B} \mathrm{{d}}^{2} x \sqrt{\sigma } \varepsilon = \frac{16 \pi R}{\kappa ^{2}} \bigg ( 1 - N(R) \bigg ), \end{aligned}$$
(56)

which approaches the conserved charge M when taking \(R \rightarrow \infty \) and \(G=1\).

To obtain the entropy in a quasilocal frame, we calculate the quasilocal free energy (36) from the Euclidean gravity action

$$\begin{aligned} F_\mathrm{{R}} = T_\mathrm{{R}} I_\mathrm{{E}} = \frac{8 \pi }{\kappa ^{2} N(R)} \bigg [ - \frac{r_{h}}{2} - 2 R \bigg ( 1 - \frac{r_{h}}{R} - \sqrt{1 - \frac{r_{h}}{R}} \bigg ) \bigg ], \end{aligned}$$
(57)

and then the entropy is

$$\begin{aligned} S = -\frac{F_\mathrm{{R}} - E}{T_\mathrm{{R}}} = \frac{16 \pi ^{2} r_{h}^{2}}{\kappa ^{2}}, \end{aligned}$$
(58)

which agrees with the Bekenstein–Hawking entropy. Then we find that these quasilocal variables agree with the quasilocal Smarr relation in (42) with \(Q=0\),

$$\begin{aligned} E = 2 T_{\text {R}} S + 2 P A. \end{aligned}$$

Now let us make a variation of E with respect to S and A; then it simply reproduces the first law of black hole thermodynamics

$$\begin{aligned} \mathrm{{d}}E = T_{\text {R}} \mathrm{{d}} S + P \mathrm{{d}} A \end{aligned}$$
(59)

where \(A = 4 \pi R^{2}\).

3.2 Reissner–Nordström black holes

In the presence of an abelian gauge field, the Einstein equation with the metric ansatz (50) yields the metric function as

$$\begin{aligned} N(r) = \frac{1}{f(r)} = \sqrt{1 - \frac{2M}{r} + \frac{q_{i}^{2}}{r^{2}} } \end{aligned}$$
(60)

where the index i indicates an electrically charged case with the electric charge parameter \(q_1=q\), a magnetically charged case with the magnetic charge parameter \(q_2=p\) or the presence of the two charges. The gauge field solutions become

$$\begin{aligned} {{\mathcal {A}}} = \pm \frac{2}{\kappa } \bigg (\frac{q}{r} - \frac{q}{r_{h}} \bigg )\mathrm{{d}}t, \quad {{\mathcal {A}}} = \pm \frac{2}{\kappa } p (1-\cos \theta ) \mathrm{{d}} \phi . \end{aligned}$$
(61)

Here the regularity condition is imposed so as to have \(A_{t} =0\) at the black hole horizon and another gauge patch is glued for \(A_{\phi }\) to be regular on the \(\theta \)-axis. The total electric or magnetic charge is computed from (27) and (30), respectively,

$$\begin{aligned} Q_E = \pm \frac{8 \pi }{\kappa } q, \qquad Q_M = \pm \frac{8 \pi }{\kappa } p. \end{aligned}$$
(62)

The Tolman temperature is calculated as

$$\begin{aligned} T_{\text {R}} = \frac{1}{N(R)} \frac{1}{4 \pi r_{h}} \bigg (1- \frac{q_{i}^{2}}{r_{h}^{2}} \bigg ). \end{aligned}$$
(63)

To compute the boundary stress energy–momentum tensor (22), we employ the MM-counterterm up to the sub-leading order of r. Then from the renormalized action we calculate the quasilocal energy (25), the surface pressure (24), and the electric (29) or magnetic potential (32) as follows:

$$\begin{aligned} E(r_{h}, R, q_{j})&= \int _{B} \mathrm{{d}}^{2} x \sqrt{\sigma } \varepsilon = \frac{16 \pi R}{\kappa ^{2}} \bigg ( 1 - N(R) \bigg ) , \end{aligned}$$
(64)
$$\begin{aligned} P&=- \frac{1}{2} \sigma _{ab} s^{ab} = - \frac{2}{\kappa ^{2} R} \bigg (\frac{1}{N(R)} \bigg (1 - \frac{r_{h}}{2R} \nonumber \\&\quad - \frac{q_{j}^{2}}{2 R r_{h}} \bigg ) - 1 \bigg ), \end{aligned}$$
(65)
$$\begin{aligned} \Phi _{\text {R},i}&= \pm \frac{1}{N(r)} \frac{2}{\kappa } \bigg ( \frac{q_{i}}{r} - \frac{q_{i}}{r_{h}} \bigg ) \bigg |^{r=r_{h}}_{r=R} \nonumber \\&= \pm \frac{1}{N(R)} \frac{2}{\kappa } \bigg ( \frac{q_{i}}{r_{h}} - \frac{q_{i}}{R} \bigg ), \end{aligned}$$
(66)

where

$$\begin{aligned} N(R) = \frac{1}{f(R)} = \sqrt{1 - \frac{r_{h}}{R} - \frac{q_{i}^{2}}{r_{h}R} + \frac{q_{i}^{2}}{R^{2}} }, \end{aligned}$$
(67)

and \(N(r_{h}) = 0\) is used. The quasilocal thermodynamic potential (36) obtained from the Euclidean gravity action becomes

$$\begin{aligned} F_\mathrm{{R}}&= T_\mathrm{{R}} I_\mathrm{{E}} = \frac{8 \pi }{\kappa ^{2}} \bigg [ \frac{1}{N(R)} \bigg (\frac{q_{j}^{2}}{R} - \frac{q_{j}^{2}}{r_{h}} \bigg ) - \frac{1}{N(R)} \bigg (M - \frac{q_{j}^{2}}{R}\bigg ) \nonumber \\&\quad - 2 R \bigg (N(R) -1 \bigg ) \bigg ] \end{aligned}$$
(68)
$$\begin{aligned}&\equiv E - T_{\text {R}}S - \Phi _{\text {R},i} Q_{i} \end{aligned}$$
(69)

and the entropy is computed as

$$\begin{aligned} S= - \frac{F_\mathrm{{R}} - (E-\Phi _{\text {R}, i} Q_{i})}{T_\mathrm{{R}}} = \frac{16 \pi ^{2} r_{h}^{2}}{\kappa ^{2}}, \end{aligned}$$
(70)

which agrees with the Bekenstein–Hawking entropy. From these quasilocal variables we find that our Smarr relation (42) is satisfied and we also confirm that the variation of the quasilocal energy (64) with respect to S, Q, and A retains the first law

$$\begin{aligned} E&= 2 T_\mathrm{{R}} S + \Phi _{\text {R},i} Q_{i} + 2 P A, \end{aligned}$$
(71)
$$\begin{aligned} \mathrm{{d}}E&= T_{\text {R}} \mathrm{{d}} S + P \mathrm{{d}} A + \Phi _{\text {R},i} \mathrm{{d}} Q_{i}. \end{aligned}$$
(72)

3.3 Higher-dimensional electrically charged black holes

Let us consider a higher-dimensional charged black hole with the following metric ansatz:

$$\begin{aligned} \mathrm{{d}}s^{2} = - N(r)^{2} \mathrm{{d}}t^{2} + f(r)^{2} \mathrm{{d}}r^{2} + r^{2} \mathrm{{d}} \Omega _{n-2}. \end{aligned}$$
(73)

By solving the Einstein equation, we obtain the metric and the electric potential

$$\begin{aligned} N(r)&= \frac{1}{f(r)} = \sqrt{1-\frac{\mu }{r^{n-3}} + \frac{q^{2}}{r^{2(n-3)}} }, \end{aligned}$$
(74)
$$\begin{aligned} {{\mathcal {A}}}(r)&= \pm \frac{1}{\kappa } \sqrt{\frac{2(n-2)}{n-3}} \bigg ( \frac{q}{r^{n-3}}-\frac{q}{r_{h}^{n-3}} \bigg ) \mathrm{{d}}t \end{aligned}$$
(75)

where the regularity condition is also imposed at the black hole horizon for \({{\mathcal {A}}}_t\), and the total electric charge is computed as

$$\begin{aligned} Q = \pm \frac{1}{\kappa }\sqrt{2(n-2)(n-3)} q \omega _{n-2}. \end{aligned}$$
(76)

From the metric, the Tolman temperature at \(r=R\) is easily read off

$$\begin{aligned} T_{\text {R}} = \frac{1}{N(R)} \frac{(n-3)}{4 \pi r_{h}} \frac{r_{h}^{2(n-3)} - q^{2}}{r_{h}^{2(n-3)}}. \end{aligned}$$
(77)

To construct the renormalized gravity action, we take the MM-counterterm solutions (20) with the metric (73) which becomes

$$\begin{aligned} {\hat{K}}_{ij} = r \mu ^{(0)}_{ij} \end{aligned}$$
(78)

where the first sub-leading term vanishes since \(\alpha = - \gamma ^{(1)}\) in this case. Then the quasilocal energy and surface pressure are computed as

$$\begin{aligned} E&= \int _{B} \mathrm{{d}}^{n-2} x \sqrt{\sigma } \epsilon = \frac{2(n-2)}{\kappa ^{2}} \omega _{n-2} R^{n-3} \bigg [1-N(R) \bigg ], \end{aligned}$$
(79)
$$\begin{aligned} P&=- \frac{1}{(n-2)} \tau _{ij} \sigma ^{ij} \bigg |_{r=R} \nonumber \\&= - \frac{2}{\kappa ^{2}} \frac{(n-3)}{R} \bigg [ \frac{1}{N(R)} \bigg (1-\frac{\mu }{2 R^{n-3}} \bigg ) -1 \bigg ], \end{aligned}$$
(80)

and when taking R to infinity we obtain \(E \approx \frac{(n-2) \omega _{n-2}}{\kappa ^{2}} \mu \), which agrees with one in [30]. The quasilocal electric potential at \(r=R\) is written as

$$\begin{aligned} \Phi _{\text {R}}&= \pm \frac{1}{N(R)} \frac{1}{\kappa } \sqrt{\frac{2(n-2)}{n-3}} \bigg ( \frac{q}{r_{h}^{n-3}} - \frac{q}{R^{n-3}} \bigg ), \end{aligned}$$
(81)

where

$$\begin{aligned} N(R) = \sqrt{1-\frac{\mu }{R^{n-3}} + \frac{q^{2}}{R^{2(n-3)}}} . \end{aligned}$$
(82)

The quasilocal thermodynamic potential (36) is calculated as

$$\begin{aligned} F_\mathrm{{R}}&= T_{\text {R}} I_{\text {E}} \end{aligned}$$
(83)
$$\begin{aligned}&= \frac{2 \omega _{n-2}}{\kappa ^{2}} \bigg [ \frac{1}{N(R)} \bigg (\frac{(n-2) q^2}{R^{n-3}} - \frac{(n-3)r_h^{n-3}}{2} \nonumber \\&\quad - \frac{(n-1)q^2}{2 r_h^{n-3}}\bigg ) + (n-2) R^{n-3} \bigg (1 - N(R) \bigg )\bigg ] \end{aligned}$$
(84)
$$\begin{aligned}&\equiv E - T_{\text {R}} S - \Phi _{\text {R}} Q \end{aligned}$$
(85)

and so the entropy is derived as

$$\begin{aligned} S = - \frac{F_\mathrm{{R}} - (E - \Phi _{R}Q)}{T_{R}} = \frac{4 \pi }{\kappa ^{2}} \omega _{n-2} r_{h}^{n-2}. \end{aligned}$$
(86)

We find that these quasilocal thermodynamic variables agree with the n-dimensional quasilocal Smarr relation (45),

$$\begin{aligned} (n-2)E = (n-2) T_\mathrm{{R}} S + (n-3) \Phi _\mathrm{{R}} Q + (n-2) PA, \end{aligned}$$

where

$$\begin{aligned} A = \omega _{n-2}R^{n-2}. \end{aligned}$$
(87)

The variation of the energy E with respect to S, A, and Q exactly takes the form of the first law of thermodynamics as follows:

$$\begin{aligned} \mathrm{{d}}E = T_{\text {R}} \mathrm{{d}}S + P \mathrm{{d}}A + \Phi _{R} Q. \end{aligned}$$
(88)

We note that the quasilocal Smarr relation also can be reproduced by equating the Euclidean action value with the definition of a thermodynamic potential. Namely, since the Euclidean on-shell action value is calculated as

$$\begin{aligned} F_\mathrm{{R}}&= \frac{1}{(n-2)} E - \frac{1}{(n-2)}\Phi _\mathrm{{R}} Q + PA \end{aligned}$$
(89)

and the thermodynamic potential is defined by (83), equating them yields the n-dimensional quasilocal Smarr relation (45).

4 Einstein–Maxwell-dilaton theory

Let us now consider Einstein–Maxwell theory with a dilaton coupling

$$\begin{aligned} {\mathcal {L}} = \sqrt{-g} \bigg ( \frac{1}{\kappa ^{2}}R - \frac{1}{2}(\partial \phi )^{2} - \frac{1}{4}e^{ \kappa a \phi } {{\mathcal {F}}}^{2} \bigg ). \end{aligned}$$
(90)

The equations of motion are

$$\begin{aligned} R_{\mu \nu } - \frac{1}{2} g_{\mu \nu } R&= \frac{\kappa ^{2}}{2} T_{\mu \nu }, \end{aligned}$$
(91)
$$\begin{aligned} T_{\mu \nu }&=\bigg (\partial _{\mu } \phi \partial _{\nu } \phi - \frac{1}{2} g_{\mu \nu } (\partial \phi )^{2} \bigg ) \nonumber \\&\quad + e^{\kappa a \phi } \bigg ({{\mathcal {F}}}_{\mu \gamma } {{\mathcal {F}}}_{\nu }^{\; \; \gamma } - \frac{1}{4} g_{\mu \nu } {{\mathcal {F}}}^{2} \bigg ), \end{aligned}$$
(92)
$$\begin{aligned} \Box \phi&= \frac{1}{4} \kappa a e^{ \kappa a \phi } {{\mathcal {F}}}^{2}, \qquad \nabla _{\mu } e^{\kappa a \phi } {{\mathcal {F}}}^{\mu \nu } = 0. \end{aligned}$$
(93)

The solutions of the equations of motion (91) are studied in [31, 32]. Here we firstly investigate the purely electrically or magnetically charged black hole solution with dilaton and then the dyonic black hole with dilaton.

4.1 Purely electrically or magnetically charged solutions with dilaton

For either purely electrically or magnetically charged cases with dynamic dilaton, black hole solutions are studied in [31,32,33]. The metric solution for both cases is written as

$$\begin{aligned} \mathrm{{d}}s^{2}&= - H^{-\frac{2}{a^{2}+1}} f \mathrm{{d}}t^{2} + H^{\frac{2}{a^{2}+1}} \left( \frac{\mathrm{{d}}r^{2}}{f} + r^{2} \mathrm{{d}} \Omega _{2}^{2} \right) , \; \; \; \nonumber \\ H&= 1 + \frac{\mu s^{2}}{r}, \; \; \; f = 1 - \frac{\mu }{r}, \end{aligned}$$
(94)

and the solutions for matter fields are, respectively, given by

$$\begin{aligned} {{\mathcal {F}}}&= \frac{2}{\kappa }\frac{q}{r^{2}} H^{-2} \mathrm{{d}}t \wedge \mathrm{{d}}r, \qquad \phi = \frac{1}{\kappa } \frac{2a}{a^{2}+1}\log H, \nonumber \\ q&= \frac{\mu }{\sqrt{a^{2} + 1}} c s , \end{aligned}$$
(95)
$$\begin{aligned} {{\mathcal {F}}}&= \frac{2}{\kappa } p \Omega _{2}, \quad \phi = - \frac{1}{\kappa } \frac{2a}{a^{2}+1}\log H, \nonumber \\ p&= \frac{\mu }{\sqrt{a^{2} + 1}} c s \end{aligned}$$
(96)

where \(c= \cosh \delta \) and \(s=\sinh \delta \). When \(a=0\) case, this solution becomes the RN black hole solution by using a simple coordinate transformation which is studied in Sect. 3 and so we exclude the \(a=0\) case here. The electric or magnetic charge is defined as

$$\begin{aligned} Q_{\text {e}}= \int e^{\kappa a \phi } *{{\mathcal {F}}} \; , \quad Q_{\text {m}} = \int {{\mathcal {F}}}. \end{aligned}$$
(97)

Employing the MM-counterterm in this coordinate, it takes the form of

$$\begin{aligned} {{\hat{K}}}_{ab} = \left( r+ \frac{\mu s^{2}}{1+a^{2}} \right) \sigma _{ab}. \end{aligned}$$
(98)

From the renormalized gravity action, the quasilocal energy (E) and the quasilocal surface pressure (P) are computed as

$$\begin{aligned} E&= \frac{16 \pi }{\kappa ^{2}} \bigg [-\sqrt{1-\frac{\mu }{R}} \left( R + \frac{a^{2} s^{2} \mu }{a^{2}+1} \right) \left( 1+\frac{s^{2} \mu }{R} \right) ^{-\frac{a^{2}}{a^{2}+1}} \nonumber \\&\quad + \left( R +\frac{s^{2} \mu }{a^{2}+1} \right) \bigg ], \end{aligned}$$
(99)
$$\begin{aligned} P&= \frac{1}{\kappa ^{2} R^{2}} \bigg [- \frac{2R - \mu }{\sqrt{1-\frac{\mu }{R}}} \left( 1 + \frac{s^{2}\mu }{R} \right) ^{-\frac{1}{a^{2}+1}} \nonumber \\&\quad +2 \left( R + \frac{s^{2} \mu }{a^{2}+1} \right) \left( 1 + \frac{s^{2} \mu }{R} \right) ^{-\frac{2}{a^{2}+1}} \bigg ], \end{aligned}$$
(100)

and the quasilocal surface (A) is easily read off to be

$$\begin{aligned} A&= 4 \pi R^{2} \left( 1 + \frac{s^{2} \mu }{R} \right) ^{\frac{2}{a^{2}+1}}. \end{aligned}$$
(101)

When taking \(R \rightarrow \infty \), the energy and the pressure become

$$\begin{aligned} E = \frac{1}{2} \mu \left( 1 + \frac{2}{1+a^{2}} s^{2} \right) , \qquad P = 0, \end{aligned}$$
(102)

which agree with [33]. The gauge field potential and charge in a quasilocal frame are calculated as

$$\begin{aligned} \Phi _{\text {R,e}}&= \pm \frac{1}{N(R)} \frac{2}{\kappa } \left( \frac{q}{c^{2} \mu } - \frac{q}{R + s^{2} \mu } \right) ,\qquad Q_{\text {e}} = \pm \frac{8 \pi }{\kappa } q , \end{aligned}$$
(103)
$$\begin{aligned} \Phi _{\text {R,m}}&= \pm \frac{1}{N(R)} \frac{2}{\kappa } \left( \frac{p}{c^{2} \mu } - \frac{p}{R + s^{2} \mu } \right) ,\qquad Q_{\text {m}} = \pm \frac{8 \pi }{\kappa } p. \end{aligned}$$
(104)

Here the magnetic potential is obtained by the dual electric field via the electromagnetic duality by using (31) and (32). The Tolman temperature is

$$\begin{aligned} T_{\text {R}} = \frac{1}{N(R)} \frac{1}{4 \pi \mu } c^{-\frac{4}{a^{2}+1}}. \end{aligned}$$
(105)

The Euclidean action is expressed as

$$\begin{aligned} I_\mathrm{{E}}&= -\int _{{\mathcal {M}}} \sqrt{g} \bigg ( \frac{1}{\kappa ^{2}} R - \frac{1}{2} (\partial {\phi })^{2}- \frac{1}{4} e^{\kappa a \phi } {{\mathcal {F}}}^{2} \bigg ) \nonumber \\&\quad - \frac{2}{\kappa ^{2}} \int _{\partial {\mathcal {M}}} \sqrt{h}(K-{\hat{K}}). \end{aligned}$$
(106)

For the electrically charged case, this yields a thermodynamic potential as follows:

$$\begin{aligned} F_{\text {R}}&\equiv I_\mathrm{{E}} T_{\text {R}} =\frac{1}{2} E - \frac{1}{2} \Phi _{\text {R,e}} Q_\mathrm{{e}} + PA \end{aligned}$$
(107)
$$\begin{aligned}&\equiv E - T_{\text {R}}S - \Phi _{\text {R,e}}Q_\mathrm{{e}}. \end{aligned}$$
(108)

Then we can compute the entropy

$$\begin{aligned} S = - \frac{F_\mathrm{{R}} - (E-\Phi _{\text {R,e}} Q_\mathrm{{e}})}{T_\mathrm{{R}}} = \frac{16 \pi ^{2} \mu ^{2}}{\kappa ^{2}} c^{\frac{4}{a^{2}+1}}, \end{aligned}$$
(109)

which agrees with the Bekenstein–Hawking entropy.

For a magnetically charged case, the Euclidean on-shell action yields the quasilocal free energy

$$\begin{aligned} F_\mathrm{{R}} \equiv I_\mathrm{{E}} T_{\text {R}} = E - T_\mathrm{{R}} S \end{aligned}$$
(110)

and the entropy is obtained as

$$\begin{aligned} S = - \frac{F_\mathrm{{R}} - E}{T_\mathrm{{R}}} = \frac{16 \pi ^{2} \mu ^{2}}{\kappa ^{2}} c^{\frac{4}{a^{2}+1}}, \end{aligned}$$
(111)

which is the same as (109).

Since there is an electromagnetic duality in four-dimensional spacetime, a magnetic charge has the same length dimension as an electric charge and contributes to the Smarr relation in the same way as the electrically charged case. Thus the above quasilocal thermodynamic variables satisfy the following Smarr relation, obtained in (42):

$$\begin{aligned} E = 2 T_\mathrm{{R}} S + 2 PA + \Phi _{\text {R,e}} Q_{\text {e}} \; ( \text {or} \; \; \Phi _{\text {R,m}} Q_{\text {m}} ), \end{aligned}$$
(112)

which are for the electrically (or magnetically) charged case.

On varying the quasilocal energy with respect to \(S, Q_\mathrm{{e}}\) (or \(Q_\mathrm{{m}}\)), and A, the form

$$\begin{aligned} \mathrm{{d}}E = T_{\text {R}} \mathrm{{d}}S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} \; ( \text {or} \; \; \Phi _{\text {R,m}} \mathrm{{d}}Q_{\text {m}} ) \end{aligned}$$
(113)

is only satisfied up to 1/R order in the large R expansion for the variation of S and Q’s and up to \(1/R^2\) order for the variation of R. Thus the first law (113) is not satisfied for any R and this is because of the non-trivial contribution of the dilaton field that is distributed in the bulk. The dilaton field contribution can be taken into account as follows:

$$\begin{aligned} \phi _{\text {R}}&= \frac{1}{\kappa } \frac{2a}{a^{2}+1}\log H(R), \end{aligned}$$
(114)
$$\begin{aligned} \Pi _{\text {R}}&=\frac{4 \pi a (-\sqrt{4 \left( a^2+1\right) q^2+\mu ^2} +\mu )}{(1+a^{2})\kappa } \bigg [ \bigg (1 \nonumber \\&\quad + \frac{\sqrt{4 \left( a^2+1\right) q^2+\mu ^2} - \mu }{2R} \bigg )^{-\frac{a^{2}}{1+a^{2}}} \sqrt{1-\frac{\mu }{R}} - 1 \bigg ] \end{aligned}$$
(115)

where \(\Pi _{\text {R}}\) is taken to be zero at infinity. Adding these to the previous one, the following first law is satisfied at any R,

$$\begin{aligned} \mathrm{{d}}E&= T_{\text {R}} \mathrm{{d}}S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} (+ \Phi _{\text {R,m}} \mathrm{{d}}Q_{\text {m}}) + \Pi _{\text {R}} \mathrm{{d}}\phi _{\text {R}}. \end{aligned}$$
(116)

On taking \(R \rightarrow \infty \), the Smarr relation and the first law are simply approximated to

$$\begin{aligned} M&= 2 T_{\text {H}} S + \Phi _{\text {e}} Q_{\text {e}} \; ( \text {or} \; \; \Phi _{\text {m}} Q_{\text {m}} ), \end{aligned}$$
(117)
$$\begin{aligned} dM&= T_{\text {H}} \mathrm{{d}}S + \Phi _{\text {e}} \mathrm{{d}}Q_{\text {e}} \;( \text {or} \; \; \Phi _{\text {m}} \mathrm{{d}}Q_{\text {m}} ). \end{aligned}$$
(118)

4.2 Dyonic solutions with dilaton

The equations of motion (91) admit the dyonic black hole either for constant dilaton \(\phi _{0}\) and running dilaton \(\phi \) with specific values of coupling constant, which is \(a=0,1,\) and \(\sqrt{3}\). The case of \(a=0\) is nothing but the dyonic RN black hole which is studied in Sect. 3 and so we do not repeat this study here. For the rest of the cases, we examine their thermodynamic properties in a quasilocal frame.

4.2.1 Constant dilaton \(\phi _{0}\)

For a constant dilaton \(\phi _{0}\), a dyonic black hole is given by

$$\begin{aligned} \mathrm{{d}}s^{2}&= - f(r) \mathrm{{d}}t^{2} + \frac{\mathrm{{d}}r^{2}}{f(r)} + r^{2} \mathrm{{d}} \Omega _{2}^{2},\quad \nonumber \\ f(r)&= 1 - \frac{2 M}{r} + \frac{qp}{2 r^{2}}, \end{aligned}$$
(119)
$$\begin{aligned} F&= \frac{1}{\kappa } \bigg (e^{-a \phi _{0}}\frac{q}{r^{2}} \mathrm{{d}}t \wedge \mathrm{{d}}r + p \Omega _{2} \bigg ), \end{aligned}$$
(120)
$$\begin{aligned} \phi&= \phi _{0}, \quad q = \sqrt{2} q_{0}e^{\frac{a}{2}\phi _{0}}, \quad p = \sqrt{2} q_{0}e^{-\frac{a}{2}\phi _{0}}. \end{aligned}$$
(121)

The MM-counterterm is taken for the renormalized gravity action and then the quasilocal variables are computed as

$$\begin{aligned} E&= \frac{16 \pi R}{\kappa ^{2}} \bigg (1-N(R) \bigg ), \end{aligned}$$
(122)
$$\begin{aligned} P&= \frac{2}{\kappa ^{2} R} \bigg [1 -\frac{1}{N(R)} \left( 1-\frac{M}{R} \right) \bigg ], \quad A = 4 \pi R^{2}, \end{aligned}$$
(123)
$$\begin{aligned} T_{\text {R}}&= \frac{1}{N(R)} \frac{1}{4 \pi } \bigg (\frac{2M}{r_{h}^{2}}-\frac{pq}{r_{h}^{3}} \bigg ), \qquad S = \frac{16 \pi ^{2} r_{h}^{2}}{\kappa ^{2}}, \end{aligned}$$
(124)
$$\begin{aligned} \Phi _{\text {R,e}}&= \frac{1}{N(R)} \frac{1}{\kappa } e^{- a \phi _{0}} \bigg (\frac{q}{r_{h}} -\frac{q}{R} \bigg ), \qquad Q_{\text {e}} = \frac{4 \pi }{\kappa } q,\end{aligned}$$
(125)
$$\begin{aligned} \Phi _{\text {R,m}}&= \frac{1}{N(R)} \frac{1}{\kappa } e^{a \phi _{0}} \bigg (\frac{p}{r_{h}} -\frac{p}{R} \bigg ), \qquad Q_{\text {m}} = \frac{4 \pi }{\kappa } p, \end{aligned}$$
(126)

where the magnetic potential \(\Phi _{\text {R,m}}\) is obtained via the electromagnetic duality (31) and (32). On taking \(R \rightarrow \infty \), the quasilocal energy and the pressure approach

$$\begin{aligned} E = \frac{16 \pi M}{\kappa ^{2}}, \quad P = 0. \end{aligned}$$
(127)

The Euclidean on-shell action value yields the quasilocal thermodynamic potential as follows:

$$\begin{aligned} F_{\text {R}}&\equiv I_\mathrm{{E}} T_{\text {R}} =\frac{1}{2} E - \frac{1}{2} \Phi _{\text {R,e}} Q_{\text {e}} + \frac{1}{2} \Phi _{\text {R,m}} Q_{\text {m}} + PA \end{aligned}$$
(128)
$$\begin{aligned}&\equiv E - T_{\text {R}}S - \Phi _{\text {R,e}}Q_{\text {e}}, \end{aligned}$$
(129)

and the entropy (S) in a quasilocal frame is obtained:

$$\begin{aligned} S = \frac{F_\mathrm{{R}} - (E - \Phi _{\text {R,e}}Q_{\text {e}})}{T_\mathrm{{R}}}, \end{aligned}$$
(130)

which agrees with the Bekenstein–Hawking entropy. These quasilocal quantities satisfy the Smarr relation and the first law as follows:

$$\begin{aligned} E&= 2 T_{\text {R}} S + 2 PA + \Phi _{\text {R,e}} Q_{\text {e}} + \Phi _{\text {R,m}} Q_{\text {m}} , \end{aligned}$$
(131)
$$\begin{aligned} \mathrm{{d}}E&= T_{\text {R}} \mathrm{{d}} S + P\mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}} Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}} Q_{\text {m}}. \end{aligned}$$
(132)

4.2.2 Dilaton coupling \(a=1\)

The dyonic black hole solution with the dilaton coupling \(a=1\) case takes the form

$$\begin{aligned} \mathrm{{d}}s^{2}&= - (H_{1}H_{2})^{-1} f \mathrm{{d}}t^{2} + (H_{1}H_{2}) \bigg (\frac{\mathrm{{d}}r^{2}}{f} + r^{2} \mathrm{{d}} \Omega ^{2}_{2} \bigg ). \end{aligned}$$
(133)
$$\begin{aligned} F&= \frac{1}{\kappa } \bigg (\frac{q}{r^{2}}H_{1}^{-2} \mathrm{{d}}t \wedge p \Omega _{2} \bigg ), \quad \phi = \frac{1}{\kappa } \log \frac{H_{1}}{H_{2}}, \end{aligned}$$
(134)
$$\begin{aligned} f&= 1 - \frac{\mu }{r}, \; \; \; H_{i} = 1 + \frac{\mu s_{i}^{2}}{r}, \end{aligned}$$
(135)
$$\begin{aligned} q&= \sqrt{2}\mu s_{1}c_{1}, \; \; \; p = \sqrt{2}\mu s_{2}c_{2} , \end{aligned}$$
(136)

where \(c_{i} = \cosh \delta _{i}\) and \(s_{i} = \sinh \delta _{i}\). The renormalized gravity action can be constructed by using the MM-counterterm (98). The quasilocal variables are computed as

$$\begin{aligned} E&= \frac{8 \pi R}{\kappa ^{2}} \left( 2 + \frac{\mu s_{1}^{2}}{R} + \frac{\mu s_{2}^{2}}{R} \right) \bigg (1- N(R) \bigg ), \end{aligned}$$
(137)
$$\begin{aligned} P&= \frac{R}{\kappa ^{2} (R + \mu s_{1}^{2})(R + \mu s_{2}^{2})} \bigg [2 + \frac{\mu s_{1}^{2}}{R} + \frac{\mu s_{2}^{2}}{R} \nonumber \\&\quad - \frac{1}{N(R)} \bigg (2- \frac{\mu }{R} \bigg ) \bigg ], \end{aligned}$$
(138)
$$\begin{aligned} A&= 4 \pi (R + \mu s_{1}^{2})(R + \mu s_{2}^{2}), \end{aligned}$$
(139)
$$\begin{aligned} T_{\text {R}}&= \frac{1}{N(R)}\frac{1}{4 \pi c_{1}^{2}c_{2}^{2} \mu }, \quad S = \frac{16 \pi ^{2} c_{1}^{2} c_{2}^{2} \mu ^{2}}{\kappa ^{2}}, \end{aligned}$$
(140)
$$\begin{aligned} \Phi _{\text {R,e}}&= \frac{1}{N(R)} \frac{1}{\kappa } \bigg (\frac{q}{\mu c_{1}^{2}} - \frac{q}{R + \mu s_{1}^{2}} \bigg ), \quad Q_\mathrm{{e}} = \frac{4 \pi }{\kappa } q, \end{aligned}$$
(141)
$$\begin{aligned} \Phi _{\text {R,m}}&= \frac{1}{N(R)} \frac{1}{\kappa } \bigg (\frac{p}{\mu c_{2}^{2}} - \frac{p}{R + \mu s_{2}^{2}} \bigg ), \quad Q_\mathrm{{m}} = \frac{4 \pi }{\kappa } p. \end{aligned}$$
(142)

Here \(s_1, c_1, s_2\) and \(c_2\) can be replaced in terms of \(\mu , q\) and p by using (136),

$$\begin{aligned} c_{1}^{2} -1&= s_{1}^{2} = -\frac{1}{2} + \frac{\sqrt{2q^{2} + \mu ^{2}}}{2 \mu }, \quad \nonumber \\ c_{2}^{2} -1&= s_{2}^{2} = -\frac{1}{2} + \frac{\sqrt{2p^{2} + \mu ^{2}}}{2 \mu }. \end{aligned}$$
(143)

The Euclidean on-shell action value yields the quasilocal thermodynamic potential as follows:

$$\begin{aligned} F_{\text {R}}&\equiv I_{E} T_{\text {R}} =\frac{1}{2} E - \frac{1}{2} \Phi _{\text {R,e}} Q_{\text {e}} + \frac{1}{2} \Phi _{\text {R,m}} Q_{\text {m}} + PA \end{aligned}$$
(144)
$$\begin{aligned}&\equiv E - T_{\text {R}}S - \Phi _{\text {R,e}}Q_{\text {e}}, \end{aligned}$$
(145)

and then the entropy (S) in a quasilocal frame can be found

$$\begin{aligned} S = \frac{F_\mathrm{{R}} - (E - \Phi _{\text {R,e}}Q_{\text {e}})}{R}; \end{aligned}$$
(146)

this is nothing but the Bekenstein–Hawking entropy. These variables satisfy the following Smarr relation:

$$\begin{aligned} E&= 2 T_{\text {R}} S + 2 PA + \Phi _{\text {R,e}} Q_{\text {e}} + \Phi _{\text {R,m}} Q_{\text {m}}. \end{aligned}$$
(147)

On varying the quasilocal energy with respect to \(S, Q_{\text {e}}, Q_{\text {m}}\) and R, the form

$$\begin{aligned} \mathrm{{d}} E = T_{\text {R}} \mathrm{{d}}S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}}Q_{\text {m}} \end{aligned}$$
(148)

is satisfied up to 1/R order for the large R expansion for the variation with respect to S and Q’s and up to \(1/R^2\) order for the variation with respect to A due to the dilaton contribution in the bulk. The dilaton field and its conjugate potential take the forms of

$$\begin{aligned} \phi _{\text {R}}&= \frac{1}{\kappa } \log \frac{H_{1}(R)}{H_{2}(R)}, \end{aligned}$$
(149)
$$\begin{aligned} \Pi _{\text {R}}&= \frac{2 \pi (x_{2}\!-\!y_{2})}{\kappa } \bigg [ \!\! -\frac{2 R \sqrt{1-\frac{\mu }{R}}}{\sqrt{(x_{2}\!+\! 2R \!-\! \mu )}\sqrt{(y_{2}\!+\! 2R \!-\! \mu )}} \!+\!1 \bigg ]\nonumber \\ \end{aligned}$$
(150)

where \(x_{2} = \sqrt{2q^{2} + \mu ^{2}}\) and \(y_{2} = \sqrt{2p^{2} + \mu ^{2}}\) and \(\Pi _{\text {R}}\) is taken to be zero at infinity. If adding this dilaton contribution, the following first law is satisfied for all orders of R:

$$\begin{aligned} \mathrm{{d}} E = T_{\text {R}} \mathrm{{d}}S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}}Q_{\text {m}} + \Pi _{\text {R}} \mathrm{{d}} \phi _{\text {R}}. \end{aligned}$$
(151)

As R approaches infinity, the quasilocal energy, pressure, and Tolman temperature become

$$\begin{aligned} E = \frac{8 \pi }{\kappa ^{2}} \mu (1+ s_{1}^{2} + s_{2}^{2}) = M, \qquad P = 0 \qquad T_\mathrm{{R}} = T_\mathrm{{H}} ,\end{aligned}$$
(152)

which agree with the ones in [33]; the Smarr and the first law are satisfied:

$$\begin{aligned} M&= 2 T_\mathrm{{H}} S + \Phi _{\text {e}} Q_{\text {e}} + \Phi _{\text {m}} Q_{\text {m}}, \end{aligned}$$
(153)
$$\begin{aligned} \mathrm{{d}}M&= T_\mathrm{{H}} \mathrm{{d}}S + \Phi _{\text {e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {m}} \mathrm{{d}}Q_{\text {m}} . \end{aligned}$$
(154)

4.2.3 Dilaton coupling \(a=\sqrt{3}\)

The dyonic black hole solution with the dilaton coupling \(a=\sqrt{3}\) case takes the form

$$\begin{aligned} \mathrm{{d}}s^{2}&= - (H_{1}H_{2})^{-\frac{1}{2}} f \mathrm{{d}}t^{2} + (H_{1}H_{2})^{\frac{1}{2}} \bigg (\frac{\mathrm{{d}}r^{2}}{f} + r^{2} \mathrm{{d}} \Omega ^{2}_{2} \bigg ). \end{aligned}$$
(155)
$$\begin{aligned} F&= \frac{1}{\kappa } \bigg (\frac{q}{r^{2}}H_{1}^{-2} H_{2} \mathrm{{d}}t \wedge p \Omega _{2} \bigg ), \quad \phi = \frac{\sqrt{3}}{2 \kappa } \log \frac{H_{1}}{H_{2}}, \end{aligned}$$
(156)
$$\begin{aligned} f&= 1 - \frac{\mu }{r}, \quad H_{i} = 1 + \frac{\mu s_{i}^{2}}{r} + \frac{\mu ^{2} c_{i}^{2} s_{1}^{2} s_{2}^{2}}{2(c_{1}^{2}+c_{2}^{2})r^{2}}, \end{aligned}$$
(157)
$$\begin{aligned} q&=\mu s_{1} c_{1} \sqrt{\frac{1+c_{1}^{2}}{c_{1}^{2} + c_{2}^{2}}}, \quad p = \mu s_{2} c_{2} \sqrt{\frac{1+c_{2}^{2}}{c_{1}^{2} + c_{2}^{2}}}, \end{aligned}$$
(158)

where \(c_{i} = \cosh \delta _{i}\) and \(s_{i} = \sinh \delta _{i}\). In the same way as before, the MM-counterterm (98) can be used to build the renormalized gravity action. Then we can compute all thermodynamic variables as follows:

$$\begin{aligned} E&= \frac{4 \pi }{\kappa ^{2}} \bigg [4R + (s_{1}^{2}+s_{2}^{2})\mu \nonumber \\&\quad - \sqrt{1-\frac{\mu }{R}} \frac{H_{1}(R)(2 R + s_{2}^{2} \mu ) + H_{2}(R) (2 R + s_{1}^{2} \mu )}{(H_{1}(R) H_{2}(R) )^{\frac{3}{4}} } \bigg ], \end{aligned}$$
(159)
$$\begin{aligned} P&= \frac{1}{2 \kappa ^{2}} \frac{1}{(H_{1}(R) H_{2} (R))^{\frac{1}{2}} R^{2}} \bigg [ 4R + (s_{1}^{2}+s_{2}^{2}) \mu \nonumber \\&\quad - \frac{1}{N(R)} \bigg (R-\frac{\mu }{2} \bigg ) \bigg ], \end{aligned}$$
(160)
$$\begin{aligned} A&= 4 \pi R^{2} (H_{1}(R) H_{2}(R))^{\frac{1}{2}}, \end{aligned}$$
(161)
$$\begin{aligned} T_{\text {R}}&= \frac{1}{N(R)} \frac{1}{4 \pi \mu } \frac{1}{c_{1} c_{2}} H_{0}^{-1}, \quad S = \frac{8 \pi ^{2} \mu ^{2}}{\kappa ^{2}} c_{1} c_{2} H_{0}, \end{aligned}$$
(162)
$$\begin{aligned} \Phi _{\text {R,e}}&= \frac{q}{4 \kappa } \bigg (\frac{2+s_{2}^{2}}{H_{0} c_{1}^{2} \mu } - \frac{2R + s_{2}^{2} \mu }{R^{2} H_{1}(R)} \bigg ), \qquad Q_{\text {e}} = \frac{4 \pi }{\kappa } q, \end{aligned}$$
(163)
$$\begin{aligned} \Phi _{\text {R,e}}&= \frac{p}{4 \kappa } \bigg (\frac{2+s_{1}^{2}}{H_{0} c_{2}^{2} \mu } - \frac{2R + s_{1}^{2} \mu }{R^{2} H_{2}(R)} \bigg ) , \quad Q_{\text {m}} = \frac{4 \pi }{\kappa } p, \end{aligned}$$
(164)

where \(H_{0} = 1+ \frac{s_{1}^{2} s_{2}^{2}}{2(c_{1}^{2}+ c_{2}^{2})}\). The Euclidean on-shell action value yields the quasilocal thermodynamic potential as follows:

$$\begin{aligned} F_{\text {R}}&\equiv I_\mathrm{{E}} T_{\text {R}} =\frac{1}{2} E - \frac{1}{2} \Phi _{\text {R,e}} Q_{\text {e}} + \frac{1}{2} \Phi _{\text {R,m}} Q_{\text {m}} + PA \end{aligned}$$
(165)
$$\begin{aligned}&\equiv E - T_{\text {R}}S - \Phi _{\text {R,e}}Q_{\text {e}} \end{aligned}$$
(166)

and then entropy (S) in a quasilocal frame is calculated to be

$$\begin{aligned} S = \frac{F_\mathrm{{R}} - (E-\Phi _{\text {R,e}}Q_{\text {e}})}{T_\mathrm{{R}}}, \end{aligned}$$
(167)

which turns out to agree with the Bekenstein–Hawking entropy. As expected, these quasilocal variables satisfy the following Smarr relation:

$$\begin{aligned} E = 2 T_{\text {R}} S + 2 PA + \Phi _{\text {R,e}} Q_{\text {e}} + \Phi _{\text {R,m}} Q_{\text {m}}. \end{aligned}$$
(168)

To make a variation of \(\delta _1 = \delta _1(\mu , q, p)\) and \(\delta _2 = \delta _2(\mu , q, p)\) with respect to \(\mu , q ,p\) and R, it is useful to use

$$\begin{aligned} \partial _{\mu } c_1^2&=-\frac{c_1^2 \left( c_1^4-1\right) \left( 3 c_2^4-1\right) }{\left( \left( 3 c_2^4-1\right) c_1^4+c_2^2 c_1^2-c_2^4\right) \mu }, \qquad \nonumber \\ \partial _{\mu } c_2^2&= -\frac{\left( 3 c_1^4-1\right) \left( c_2^4-1\right) \text {c2}^2}{\left( \left( 3 c_2^4-1\right) c_1^4+c_2^2 c_1^2-c_2^4\right) \mu }, \end{aligned}$$
(169)
$$\begin{aligned} \partial _{q} c_1^2&=\frac{c_1^2 \left( c_1^4-1\right) \left( \left( 3 c_2^4-1\right) \text {c1}^2+2 c_2^6\right) }{\left( \left( 3 c_2^4-1\right) c_1^6+3 c_2^6 c_1^4-c_2^6\right) q}, \qquad \nonumber \\ \partial _{q} c_2^2&= \frac{c_1^2 \left( c_1^4-1\right) \left( c_2^4-1\right) \text {c2}^2}{\left( \left( 3 c_2^4-1\right) c_1^6+3 c_2^6 c_1^4-c_2^6\right) q}, \end{aligned}$$
(170)
$$\begin{aligned} \partial _{p} c_1^2&=\frac{c_1^2 \left( c_1^4-1\right) c_2^2 \left( c_2^4-1\right) }{\left( \left( 3 c_2^4-1\right) c_1^6+3 c_2^6 c_1^4-c_2^6\right) p}, \qquad \nonumber \\ \partial _{p} c_2^2&=\frac{c_2^2 \left( c_2^4-1\right) \left( 2 c_1^6+3 c_2^2 c_1^4-c_2^2\right) }{\left( \left( 3 c_2^4-1\right) c_1^6+3 c_2^6 c_1^4-c_2^6\right) p}, \end{aligned}$$
(171)

where \(\partial s_1^2 = \partial c_1^2\) and \(\partial s_2^2 = \partial c_2^2\). As we learned about the first law from the previous examples having dynamic dilaton field, here we have the same consequence. The form of the first law of

$$\begin{aligned} \mathrm{{d}}E = T_{\text {R}} \mathrm{{d}} S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}} Q_{\text {m}} \end{aligned}$$
(172)

is only valid up to the order of 1/R for the variation on \(\mu , q,\) and p and up to the order of \(1/R^2\) for the variation on R when expanding on large R. Then as we did in the previous examples we use the dilaton field and its conjugate potential, which is obtained from (43),

$$\begin{aligned} \phi _{\text {R}}&= \frac{\sqrt{3}}{2 \kappa } \log \frac{H_{1}(R)}{H_{2}(R)}, \end{aligned}$$
(173)
$$\begin{aligned} \Pi _{\text {R}}&= \frac{2\sqrt{3}\pi }{\kappa } \bigg [ (s_{1}^{2} - s_{2}^{2}) \mu + (H_{1}(R) H_{2}(R))^{1/4} \nonumber \\&\quad \sqrt{1-\frac{\mu }{R}} \bigg (\frac{2 R+ \mu s_1^2}{H_1(R)} - \frac{2 R+ \mu s_2^2}{H_2(R)}\bigg ) \bigg ], \end{aligned}$$
(174)

and plug these into the first law as follows:

$$\begin{aligned} \mathrm{{d}}E = T_{\text {R}} \mathrm{{d}} S + P \mathrm{{d}}A + \Phi _{\text {R,e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {R,m}} \mathrm{{d}} Q_{\text {m}} + \Pi _{\text {R}} \mathrm{{d}}\phi _{\text {R}}. \end{aligned}$$
(175)

However, this dilaton potential only improves the variation of R up to the order of \(1/R^3\) in this case. They do not capture all the contributions of dilaton field in the bulk but have a remaining part as follows:

$$\begin{aligned}&d_{\mu }E -(T_{\text {R}} d_{\mu } S + P d_{\mu }A + \Phi _{\text {R,e}} d_{\mu } Q_{\text {e}} \nonumber \\&\quad + \Phi _{\text {R,m}} d_{\mu } Q_{\text {m}} + \Pi _{\text {R}} d_{\mu } \phi _{\text {R}}) \nonumber \\&\qquad \sim \frac{\pi \mu ^2 s_{1}^2 s_{2}^2 \left( c_{1}^2 + 1 \right) \left( c_{2}^2 + 1 \right) \left( c_{1}^2-c_{2}^2\right) ^2}{\kappa ^2 \left( c_1^2+c_2^2\right) \left( -3 c_2^4 c_1^4+c_1^4-c_2^2 c_1^2+c_2^4\right) R^{2}} + \cdots , \end{aligned}$$
(176)
$$\begin{aligned}&d_{q}E -(T_{\text {R}} d_{q} S + P d_{q}A + \Phi _{\text {R,e}} d_{q} Q_{\text {e}} \nonumber \\&\quad + \Phi _{\text {R,m}} d_{q} Q_{\text {m}} + \Pi _{\text {R}} d_{q} \phi _{\text {R}}) \nonumber \\&\qquad \sim \frac{\pi \mu ^2 c_{1} s_{1} s_{2}^2 \left( c_{2}^2+1\right) \left( c_{1}^2-c_{2}^2\right) \left( c_{1}^2 - c_{2}^2 - 2 c_{1}^2 c_{2}^4 \right) }{\kappa ^{2}\left( c_{1}^2+c_{2}^2\right) \left( c_{1}^4 \left( 3 c_{2}^4-1\right) +c_{1}^2 c_{2}^2-c_{2}^4\right) R^{2}} \nonumber \\&\qquad \sqrt{\frac{1+c_{1}^{2}}{c_{1}^{2} +c_{2}^{2}}} + \cdots , \end{aligned}$$
(177)
$$\begin{aligned}&d_{p}E -(T_{\text {R}} d_{p} S + P d_{p}A + \Phi _{\text {R,e}} d_{p} Q_{\text {e}} \nonumber \\&\quad + \Phi _{\text {R,m}} d_{p} Q_{\text {m}} + \Pi _{\text {R}} d_{p} \phi _{\text {R}}) \nonumber \\&\qquad \sim \frac{\pi \mu ^2 c_{2} s_{1}^2 s_{2}\left( c_{1}^2+1\right) \left( c_{1}^2-c_{2}^2\right) \left( c_{1}^2-c_{2}^2 + 2 c_{1}^4 c_{2}^2\right) }{\kappa ^2 \left( c_{1}^2+c_{2}^2\right) \left( c_{1}^4 \left( 3 c_{2}^4-1\right) +c_{1}^2 c_{2}^2-c_{2}^4\right) R^2} \nonumber \\&\qquad \sqrt{\frac{1+c_{2}^{2}}{c_{1}^{2} +c_{2}^{2}}} + \cdots , \end{aligned}$$
(178)
$$\begin{aligned}&d_{R}E -(T_{\text {R}} d_{R} S + P d_{R}A + \Phi _{\text {R,e}} d_{R} Q_{\text {e}}\nonumber \\&\quad + \Phi _{\text {R,m}} d_{R} Q_{\text {m}} + \Pi _{\text {R}} d_{R} \phi _{\text {R}}) \nonumber \\&\qquad \sim -\frac{\pi \mu ^4 s_{1}^2 s_{2}^2 \left( c_{1}^2+1\right) \left( c_{2}^2+1\right) \left( c_{1}^2-c_{2}^2\right) ^2}{\kappa ^2 \left( c_{1}^2+c_{2}^2\right) ^2 R^4 } + \cdots , \end{aligned}$$
(179)

where the dots indicate the higher order of 1/R. Then we might give up the definition of the dilaton potential (43) and see if another definition of \(\Pi _\mathrm{{R}}\) can make the first law satisfied. So we impose the first law (175) and then find \(\Pi _\mathrm{{R}}\) from each variation of the parameters. However, the values of \(\Pi _\mathrm{{R}}\) obtained from the first law are not consistent. Another possibility is to consider an unknown contribution such as XdY, but it also seems not to be the case. This is because XdY term should be effective from the order of \(1/R^2\) seen in (176)–(178) but then this will contribute to the order of \(1/R^3\) in (179), which should not be present. This indicates that we cannot find an XdY term to obey the first law. The only way to satisfy the first law for all orders of R is to set \(\delta _1 = \delta _2\), but this is nothing but the condition that turns off the dilaton field.

Taking \(R \rightarrow \infty \), the quasilocal energy and pressure take the values

$$\begin{aligned} E = \frac{4 \pi }{\kappa ^{2}} \mu (c_{1}^{2} + c_{2}^{2} ) = M, \qquad P = 0, \end{aligned}$$
(180)

which agree with ones in [33] and the following Smarr relation and the first law are satisfied:

$$\begin{aligned} M&= 2 T_{\text {H}} S + \Phi _{\text {e}} Q_{\text {e}} + \Phi _{\text {m}} Q_{\text {m}}, \end{aligned}$$
(181)
$$\begin{aligned} \mathrm{{d}}M&= T_{\text {H}} \mathrm{{d}}S + \Phi _{\text {e}} \mathrm{{d}}Q_{\text {e}} + \Phi _{\text {m}} \mathrm{{d}}Q_{\text {m}}. \end{aligned}$$
(182)

5 Summary and future work

We studied thermodynamics in a quasilocal frame for Einstein–Maxwell (-dilaton) theory in an asymptotically flat spacetime. In order to do so, we extended thermodynamic relations such as the thermodynamic potential, the Smarr relation and the first law to a quasilocal frame and checked them with various black hole solutions.

We firstly employed the Brown–York quasilocal method with a Mann–Marolf counterterm to obtain the quasilocal energy and the surface pressure from the renormalized action. We also showed the form of the electric and magnetic potential in a quasilocal frame. In four-dimensional spacetime, they make the same contribution to the Smarr relation due to the electromagnetic duality. Secondly we defined a quasilocal thermodynamic potential from the Euclidean on-shell action by applying the Tolman temperature and derived the entropy in a quasilocal frame. Here the quasilocal thermodynamic potential does not contain the surface pressure term and the entropy derived from the quasilocal thermodynamic potential agrees with the Bekenstein–Hawking entropy. Then we formulated a quasilocal Smarr relation from Euler’s theorem and found that the surface pressure term and its conjugate variables participate in the relation. When r goes infinity, the quasilocal energy approaches the conserved charge of the spacetime and the surface pressure vanishes and has no effect on the thermodynamic relations. Other quasilocal thermodynamic variables also restore the usual thermodynamic form at infinity.

Under this construction, we investigated the quasilocal thermodynamics for various black hole solutions of Einstein–Maxwell (-dilaton) theory and checked if these describe the quasilocal thermodynamics well. Apart from the importance of the surface pressure term, one should also notice the importance of the dilaton field in a quasilocal frame. For dyonic black hole solutions having a dynamic dilaton, while the quasilocal Smarr relation does not contain the dilaton term, there is an additional contribution of the dynamic dilaton field to the first law at finite R but the contribution dies out at infinity. Namely, when we expand the quasilocal first law on large R in the absence of the dilaton field and its conjugate potential term, the quasilocal first law is satisfied up to 1/R order for the variation with respect to the entropy and Maxwell charges and up to \(1/R^2\) order for the variation with respect to the quasilocal area due to the spread of the dilaton field in the bulk. This dilaton contribution can be taken into account by adding the dilaton terms to the first law and then the quasilocal first law is satisfied. However, we found the exceptional case which is the dilaton coupling constant \(a=\sqrt{3}\). In this case adding the dilaton terms does not capture all the contributions in the bulk and it seems not improved by modifying the dilaton potential or considering a new term such as XdY to the quasilocal first law. The only condition making the first law to be obeyed is to set the electric and magnetic charge equivalent, which induces turning off the dilaton field.

This work could be extended to find quasilocal Smarr relations for various spacetimes using different methods. The Smarr relation was firstly found in [10] by applying Euler’s theorem, but later the same form was derived from the Komar formula in [11]. In this paper, the quasilocal Smarr relation is obtained in the same way as in [10], but it is interesting to see whether the Komar formula can be modified to yield the same quasilocal Smarr relation as given here. Also, exploring the quasilocal Smarr relation for black hole spacetimes having a negative cosmological constant is very intriguing. The Smarr relation for the AdS black hole and Lifshitz black holes are studied by introducing a pressure term with a thermodynamic volume term in [34,35,36,37], respectively. Quasilocal thermodynamics for an AdS black hole is studied in [28, 38]. However, its extension to the quasilocal Smarr relation is non-trivial and should be pursued.