useful discussions. The authors would also like to thank Prof. Andrzej Swiech
from Georgia Institute of Technology, USA for his valuable comments and
suggestions.

## References

  * [1]
  * [2] S. Agmon.  Lectures on elliptic boundary value problems.  AMS Chelsea Publishing, Providence, RI, 2010.  Prepared for publication by B. Frank Jones, Jr. with the assistance of George W. Batten, Jr., Revised edition of the 1965 original.
  * [3] M. Bardi and I. Capuzzo-Dolcetta.  Optimal control and viscosity solutions of Hamilton-Jacobi-Bellman equations.  Springer Science & Business Media, 2008.
  * [4] T Biswas, S Dharmatti, and M. T. Mohan.  Maximum principle for some optimal control problems governed by 2D nonlocal Cahn-Hillard-Navier-Stokes equations.  J. Math. Fluid Mech., 22(3):Art. 34, 42, 2020.
  * [5] T. Biswas, S. Dharmatti, L. N. M. Perisetti, and M. T Mohan.  On the stationary nonlocal Cahn-Hilliard-Navier-Stokes system: Existence, uniqueness and exponential stability.  arXiv preprint arXiv:1811.00437, 2018.
  * [6] F. Boyer.  Mathematical study of multi-phase flow under shear through order parameter formulation.  Asymptotic analysis, 20(2):175–212, 1999.
  * [7] H. Brezis.  Functional analysis, Sobolev spaces and partial differential equations.  Universitext. Springer, New York, 2011.
  * [8] J. W. Cahn.  On spinodal decomposition.  Acta Metallurgica, 9(9):795 – 801, 1961.
  * [9] J. W. Cahn and J.E. Hilliard.  Free energy of a nonuniform system. i. interfacial free energy.  The Journal of Chemical Physics, 28(2):258–267, 1958.
  * [10] P Cannarsa and G Da Prato.  Second-order Hamilton-Jacobi equations in infinite dimensions.  SIAM J. Control Optim., 29(2):474–492, 1991.
  * [11] P. Colli, S. Frigeri, and M Grasselli.  Global existence of weak solutions to a nonlocal Cahn–Hilliard–Navier–Stokes system.  Journal of Mathematical Analysis and Applications, 386(1):428–444, 2012.
  * [12] P. Constantin, C. Foiaş, and R. Temam.  Attractors representing turbulent flows, volume 314.  American Mathematical Soc., 1985.
  * [13] M. G. Crandall and P. L. Lions.  Viscosity solutions of Hamilton-Jacobi equations.  Transactions of the American mathematical society, 277(1):1–42, 1983.
  * [14] M. G. Crandall and P. L. Lions.  Hamilton-Jacobi equations in infinite dimensions. I. Uniqueness of viscosity solutions.  J. Funct. Anal., 62(3):379–396, 1985.
  * [15] M. G. Crandall and P. L. Lions.  Hamilton-Jacobi equations in infinite dimensions. II. Existence of viscosity solutions.  J. Funct. Anal., 65(3):368–405, 1986.
  * [16] M. G. Crandall and P. L. Lions.  Hamilton-Jacobi equations in infinite dimensions. III.  J. Funct. Anal., 68(2):214–247, 1986.
  * [17] M. G. Crandall and P. L. Lions.  Viscosity solutions of Hamilton-Jacobi equations in infinite dimensions. IV. Hamiltonians with unbounded linear terms.  J. Funct. Anal., 90(2):237–283, 1990.
  * [18] M. G. Crandall and P. L. Lions.  Viscosity solutions of Hamilton-Jacobi equations in infinite dimensions. V. Unbounded linear terms and $B$-continuous solutions.  J. Funct. Anal., 97(2):417–465, 1991.
  * [19] M. G. Crandall and P. L. Lions.  Hamilton-Jacobi equations in infinite dimensions. VI. Nonlinear $A$ and Tataru’s method refined.  In Evolution equations, control theory, and biomathematics (Han sur Lesse, 1991), volume 155 of Lecture Notes in Pure and Appl. Math., pages 51–89. Dekker, New York, 1994.
  * [20] M. G. Crandall and P. L. Lions.  Viscosity solutions of Hamilton-Jacobi equations in infinite dimensions. VII. The HJB equation is not always satisfied.  J. Funct. Anal., 125(1):111–148, 1994.
  * [21] G Da Prato and A Debussche.  Dynamic programming for the stochastic Navier-Stokes equations.  volume 34, pages 459–475. 2000.  Special issue for R. Temam’s 60th birthday.
  * [22] G Fabbri, F Gozzi, and A Swiech.  Stochastic optimal control in infinite dimension, volume 82 of Probability Theory and Stochastic Modelling.  Springer, Cham, 2017.  Dynamic programming and HJB equations, With a contribution by Marco Fuhrman and Gianmario Tessitore.
  * [23] C. Foias, O. Manley, R. Rosa, and R. Temam.  Navier-Stokes equations and turbulence, volume 83.  Cambridge University Press, 2001.
  * [24] S. Frigeri, C. G. Gal, and M. Grasselli.  On nonlocal Cahn–Hilliard–Navier–Stokes systems in two dimensions.  Journal of Nonlinear Science, 26(4):847–893, 2016.
  * [25] S. Frigeri, C. G. Gal, M. Grasselli, and J. Sprekels.  Two-dimensional nonlocal Cahn-Hilliard-Navier-Stokes systems with variable viscosity, degenerate mobility and singular potential.  Nonlinearity, 32(2):678–727, 2019.
  * [26] S. Frigeri and M. Grasselli.  Nonlocal Cahn-Hilliard-Navier-Stokes systems with singular potentials.  Dyn. Partial Differ. Equ., 9(4):273–304, 2012.
  * [27] S. Frigeri, M. Grasselli, and P. Krej$\check{\mathrm{c}}$í.  Strong solutions for two-dimensional nonlocal Cahn–Hilliard–Navier–Stokes systems.  Journal of Differential Equations, 255(9):2587–2614, 2013.
  * [28] S. Frigeri, M. Grasselli, and J. Sprekels.  Optimal distributed control of two-dimensional nonlocal Cahn–Hilliard–Navier–Stokes systems with degenerate mobility and singular potential.  Applied Mathematics & Optimization, 81(3):899–931, 2020.
  * [29] S. Frigeri, E. Rocca, and J. Sprekels.  Optimal distributed control of a nonlocal Cahn–Hilliard/Navier–Stokes system in two dimensions.  SIAM Journal on Control and Optimization, 54(1):221–250, 2016.
  * [30] C. G. Gal and M. Grasselli.  Asymptotic behavior of a Cahn-Hilliard-Navier-Stokes system in 2d.  In Annales de l’IHP Analyse non linéaire, volume 27, pages 401–436, 2010.
  * [31] G. Giacomin and J. L. Lebowitz.  Phase segregation dynamics in particle systems with long range interactions. I. Macroscopic limits.  J. Statist. Phys., 87(1-2):37–61, 1997.
  * [32] G. Giacomin and J. L. Lebowitz.  Phase segregation dynamics in particle systems with long range interactions. II. Interface motion.  SIAM J. Appl. Math., 58(6):1707–1729, 1998.
  * [33] B. Goldys and F. Gozzi.  Second order parabolic Hamilton-Jacobi-Bellman equations in Hilbert spaces and stochastic control: $L_{\mu}^{2}$ approach.  Stochastic Process. Appl., 116(12):1932–1963, 2006.
  * [34] F Gozzi.  Regularity of solutions of a second order Hamilton-Jacobi equation and application to a control problem.  Comm. Partial Differential Equations, 20(5-6):775–826, 1995.
  * [35] F Gozzi.  Second order Hamilton-Jacobi equations in Hilbert spaces and stochastic optimal control.  In Stochastic partial differential equations and applications (Trento, 2002), volume 227 of Lecture Notes in Pure and Appl. Math., pages 255–285. Dekker, New York, 2002.
  * [36] F Gozzi, E Rouy, and A Świȩch.  Second order Hamilton-Jacobi equations in Hilbert spaces and stochastic boundary control.  SIAM J. Control Optim., 38(2):400–430, 2000.
  * [37] F Gozzi, S. S. Sritharan, and A Świȩch.  Viscosity solutions of dynamic-programming equations for the optimal control of the two-dimensional Navier-Stokes equations.  Arch. Ration. Mech. Anal., 163(4):295–327, 2002.
  * [38] F Gozzi, S. S. Sritharan, and A Świȩch.  Bellman equations associated to the optimal feedback control of stochastic Navier-Stokes equations.  Comm. Pure Appl. Math., 58(5):671–700, 2005.
  * [39] F Gozzi and A Świȩch.  Hamilton-Jacobi-Bellman equations for the optimal control of the Duncan-Mortensen-Zakai equation.  J. Funct. Anal., 172(2):466–510, 2000.
  * [40] M. Hintermüller, M. Hinze, C. Kahle, and T. Keil.  A goal-oriented dual-weighted adaptive finite element approach for the optimal control of a nonsmooth Cahn–Hilliard–Navier–Stokes system.  Optimization and Engineering, 19(3):629–662, 2018.
  * [41] M Hintermuller and D. Wegner.  Optimal control of a semidiscrete Cahn–Hilliard–Navier–Stokes system.  SIAM Journal on Control and Optimization, 52(1):747–772, 2014.
  * [42] M Hintermüller and D Wegner.  Distributed and boundary control problems for the semidiscrete Cahn–Hilliard/Navier–Stokes system with nonsmooth ginzburg–landau energies.  Topological Optimization and Optimal Transport, Radon Series on Computational and Applied Mathematics, 17:40–63, 2017.
  * [43] P. C. Hohenberg and B. I. Halperin.  Theory of dynamic critical phenomena.  Reviews of Modern Physics, 49(3):435, 1977.
  * [44] H. Ishii.  Viscosity solutions for a class of Hamilton-Jacobi equations in Hilbert spaces.  J. Funct. Anal., 105(2):301–341, 1992.
  * [45] H Ishii.  Viscosity solutions of nonlinear second-order partial differential equations in Hilbert spaces.  Comm. Partial Differential Equations, 18(3-4):601–650, 1993.
  * [46] O. A. Ladyzhenskaya.  A dynamical system generated by the Navier-Stokes equations.  Journal of Soviet Mathematics, 3(4):458–479, 1975.
  * [47] You B Li, F.  Optimal distributed control for a model of homogeneous incompressible two-phase flows.  J Dyn Control Syst, 2020.
  * [48] P.-L. Lions.  Viscosity solutions of fully nonlinear second-order equations and optimal stochastic control in infinite dimensions. I. The case of bounded stochastic evolutions.  Acta Math., 161(3-4):243–278, 1988.
  * [49] P.-L. Lions and P. E. Souganidis.  Viscosity solutions of second-order equations, stochastic control and stochastic differential games.  In Stochastic differential systems, stochastic control theory and applications (Minneapolis, Minn., 1986), volume 10 of IMA Vol. Math. Appl., pages 293–309. Springer, New York, 1988.
  * [50] T. T. Medjo.  Optimal control of a Cahn–Hilliard–Navier–Stokes model with state constraints.  J. Convex Anal, 22:1135–1172, 2015.
  * [51] T. T. Medjo.  Robust control of a Cahn-Hilliard-Navier-Stokes model.  Communications on Pure & Applied Analysis, 15(6):2075, 2016.
  * [52] L. Nirenberg.  On elliptic partial differential equations.  In Il principio di minimo e sue applicazioni alle equazioni funzionali, pages 1–48. Springer, 2011.
  * [53] S. S. Sritharan.  Dynamic programming of the Navier-Stokes equations.  Systems Control Lett., 16(4):299–307, 1991.
  * [54] A. Swiech.  Viscosity solutions of fully nonlinear partial differential equations with unbounded terms in infinite dimensions.  ProQuest LLC, Ann Arbor, MI, 1993.  Thesis (Ph.D.)–University of California, Santa Barbara.
  * [55] A Swiech.  “Unbounded” second order partial differential equations in infinite-dimensional Hilbert spaces.  Comm. Partial Differential Equations, 19(11-12):1999–2036, 1994\.
  * [56] D. Tataru.  Viscosity solutions of Hamilton-Jacobi equations with unbounded nonlinear terms.  Journal of Mathematical Analysis and Applications, 163(2):345–392, 1992.
  * [57] D. Tataru.  Viscosity solutions for Hamilton-Jacobi equations with unbounded nonlinear term: a simplified approach.  Journal of differential equations, 111(1):123–146, 1994.
  * [58] R. Temam.  Navier-Stokes equations: theory and numerical analysis, volume 343\.  American Mathematical Soc., 2001.


# Residue Number System (RNS) based
Distributed Quantum Addition
††thanks: This research used resources of the Oak Ridge Leadership Computing
Facility, which is a DOE Office of Science User Facility supported under
Contract DE-AC05-00OR22725.

Bhaskar Gaur  University of Tennessee
Knoxville, TN, USA
<EMAIL_ADDRESS>Travis S. Humble  Oak Ridge National Laboratory
Oak Ridge, TN, USA
<EMAIL_ADDRESS>Himanshu Thapliyal  University of Tennessee
Knoxville, TN, USA
<EMAIL_ADDRESS>
###### Abstract

Quantum Arithmetic faces limitations such as noise and resource constraints in
the current Noisy Intermediate Scale Quantum (NISQ) era quantum computers. We
propose using Distributed Quantum Computing (DQC) to overcome these
limitations by substituting a higher depth quantum addition circuit with
Residue Number System (RNS) based quantum modulo adders. The RNS-based
distributed quantum addition circuits possess lower depth and are distributed
across multiple quantum computers/jobs, resulting in higher noise resilience.
We propose the Quantum Superior Modulo Addition based on RNS Tool (QSMART),
which can generate RNS sets of quantum adders based on multiple factors such
as depth, range, and efficiency. We also propose a novel design of Quantum
Diminished-1 Modulo (2n \+ 1) Adder (QDMA), which forms a crucial part of RNS-
based distributed quantum addition and the QSMART tool. We demonstrate the
higher noise resilience of the Residue Number System (RNS) based distributed
quantum addition by conducting simulations modeling Quantinuum’s H1 ion trap-
based quantum computer. Our simulations demonstrate that RNS-based distributed
quantum addition has 11.36% to 133.15% higher output probability over 6-bit to
10-bit non-distributed quantum full adders, indicating higher noise fidelity.
Furthermore, we present a scalable way of achieving distributed quantum
addition higher than limited otherwise by the 20-qubit range of Quantinuum H1.

###### Index Terms:

Quantum circuit, quantum computing, quantum adder, quantum modulo adder, NISQ,
FTQ

##  I Introduction

Quantum computing is an emerging field that promises considerable advantage
over classical computing owing to quantum algorithms such as Shor’s algorithm,
quantum phase estimation, amplitude amplification, variational quantum
algorithms, quantum approximate optimization algorithms, HHL algorithm, and
quantum convolution neural networks (QCNN) [1, 2, 3, 4]. The quantum
algorithms rely on quantum arithmetic circuits for representation and
optimization. Quantum adders play an essential role among quantum arithmetic
circuits by forming building blocks for quantum multiplication, quantum image
processing, and quantum cryptanalysis [5, 6, 7, 8]. Hence, optimizing quantum
adders and increasing their noise resilience is a critical objective.

Recent advancements have been made in quantum computing, particularly by ion
trap quantum computers, to achieve higher gate fidelity. Although more
reliable, ion trap quantum computers offer fewer qubits than their
superconducting counterparts, resulting in quantum circuit size limitations.
Also, noise accumulation with increasing depth of quantum circuits results in
lower output probability, limiting the scaling potential. Distributed Quantum
Computing (DQC) is an emerging computing paradigm that builds upon the
existing individual quantum systems to significantly increase computing power
and help scale quantum algorithms to larger sizes [9, 10].

This work aims to achieve scalability for quantum adders using a hybrid
distributed quantum computing scheme. We use classical computing to distribute
quantum addition across multiple quantum circuits using Residue Number Systems
(RNS). RNS represents numbers in the form of residues or remainders left after
division with a set of relatively prime moduli. The representation is unique
as long as the numbers lie within the range of the moduli product. Each of the
residues can be added individually without any carry dependency upon other
residues in the RNS set. This provides the capability to distribute the
addition for residues across multiple quantum computers or jobs. Apart from
addition, RNS can also accomplish closure for arithmetic operations such as
subtraction and multiplication.

The choice of moduli selection for RNS is an active research area in classical
computing. We select a set of three moduli: 2n-1, 2n, and 2n+1 to construct
RNS sets in this work. The addition achieved by this RNS set can nearly
substitute the range achievable by a quantum full adder of input size ’3n’
[6]. These moduli can help construct scalable RNS sets with optimized quantum
addition implementations that use lower quantum resources. While designs exist
for quantum modulo adders for the moduli (2n-1) and 2n, the quantum modulo
(2n+1) adder lacked an implementation optimized specifically for it. Hence, we
propose a Quantum Diminished-1 Modulo (2n+1) Adder (QDMA) that can perform
(A+B) modulo (2n+1) addition efficiently.

Ultimately, we propose a novel Quantum Superior Modulo Addition based on RNS
Tool (QSMART) that automates the moduli selection and generation of RNS based
quantum modulo adder circuits for a given range of inputs. The QSMART Tool’s
approach of using Residue Number System (RNS) for quantum addition: i) splits
the quantum addition operation in multiple circuits independently executable
in a Distributed Quantum Computing (DQC) system, ii) reduces the overall
depth, and iii) achieves higher output probability resulting from superior
noise resilience. The proposed QSMART Tool can help achieve higher noise
resilience in NISQ computing, and scale quantum addition in NISQ as well as
Fault Tolerant Quantum (FTQ) era quantum computers. We list the contributions
of this work below:

  * •

We propose Quantum Diminished-1 Modulo (2n+1) Adder (QDMA) that addresses a
crucial gap in the creation of Residue Number System (RNS) based quantum
addition.

  * •

We propose the QSMART Tool, which generates RNS-based quantum modulo adders,
leveraging Distributed Quantum Computing (DQC) to execute quantum addition
independently.

  * •

We demonstrate that the proposed QSMART Tool’s reduction in overall depth
translates into higher noise resilience by conducting simulations that model
the system noise in Quantinuum’s H1 ion trap-based quantum computer on PyTKET
[11].

This paper is organized as follows: Section II provides the background
information and relevant works utilized in this paper. Section III proposes
the novel Quantum Diminished-1 Modulo (2n+1) Adder (QDMA). Section IV explains
the QSMART Tool and its algorithm. Section V shows the Quantinuum H1-based
simulation results for quantum modulo adders and the noise-resilience of
QSMART Tool. Section VI discusses the resource and output probability
comparison between the quantum full adder and distributed quantum addition.
Finally, Section VII concludes this work.

##  II Background

###  II-A Quantum Modulo Addition

Modulo, or modular addition, is an addition operation performed within a
modulo arithmetic system in which the output does not exceed the modulo.
Equation 1 shows the modulo addition for a given modulo ’M’, where the sum of
inputs A and B is divided by the moduli M, and a reminder is provided as a
result.

$\displaystyle Modulo\,Sum=\begin{cases}A+B,&\text{if}\;{(A+B)}<{M}\\\
0,&\text{if}\;{(A+B)}={M}\\\ (A+B)mod(M),&\text{if}\;{(A+B)}>{M}\end{cases}$
(1) $\displaystyle\text{where }\;0\leq{A,B,Modulo\,Sum}<{M}$

Quantum modulo adders are quantum arithmetic circuits optimized especially for
modulo addition. They help create quantum modulo circuits of higher
complexity, such as subtraction and multiplication, used in applications such
as quantum cryptanalysis, quantum image processing, and securing communication
[7, 8]. The prior work on quantum modulo adders for generic modulo M has a
high overhead regarding quantum gates and depth, limiting their usefulness on
the quantum computers available today. The quantum modulo M adders proposed by
Vedral et al. and Beauregard et al. have five quantum full adder stages [12,
13]. Van Meter and Itoh proposed a more efficient modulo adder with three
quantum full adder stages [14]. In this work, we focus on the moduli that are
powers of 2 as: i) they are efficient as they represent the maximum numbers
possible in n-bits, and ii) they require fewer quantum resources than quantum
modulo M adders. Modulo 2n adders require at most one quantum full adder
stage, as any addition without carryout is modulo 2n addition. This is evident
from Figure 1 in which modulo 8 adder is optimized version of a quantum full
adder with 4-qubit output, and modulo 4 adder uses only two CNOT and a Toffoli
gates. Modulo (2n-1) adder by Kim et al., on the other hand, requires up to
two full adder stages [15]. We propose modulo (2n+1) adder in this work that
needs one full and a half adder stage. Figure 2 provides a comparison between
modulo 3 adders achieved by Kim et al.’s modulo (2n-1) adder and the modulo
(2n+1) adder proposed in this work. Ultimately, these three quantum modulo
adders help us achieve RNS based arithmetic in the following Section.

(a)

(b)

Figure 1: Quantum Modulo 2n adders used in this work: (a) Mod 4 Adder. (b) Mod
8 Adder. The inputs are A and B. The output M is Modulo Sum, while input B is
passed unchanged.

(a)

(b)

Figure 2: Comparison of Quantum Modulo 3 adders used in this work: (a) Quantum
Modulo (2n \- 1) adder for n = 2 configuration [15]. (b) Quantum Modulo (2n \+
1) adder for n = 1 configuration. The inputs are A (A0:A1) and B (B0:B1),
while the output is Modulo Sum M (M0:M1). Input A is passed without
modification. Quantum Modulo (2n \+ 1) adder’s Toffoli count and CNOT count
are lower by 3 and 6 respectively. Also, its Toffoli depth and CNOT depth are
lower by 3 and 5 respectively, showcasing its better design. Figure 3:
Proposed Quantum Superior Modulo Addition based on RNS Tool (QSMART) uses a
hybrid classical-quantum flow to achieve Distributed Quantum Computing (DQC)
for quantum addition. QSMART accepts the range of addition, planned efficiency
of representation, and inputs to deliver multiple independent Residue Number
System (RNS) based quantum modulo adders that can be distributed across
multiple quantum computers or jobs.

###  II-B Residue Number System

The Residue Number System (RNS) is a numerical system where integers are
represented by their residues taken with respect to a set of relatively prime
integers called moduli. RNS allows for fast arithmetic operations,
particularly addition, subtraction, and multiplication, due to parallel and
autonomous processing of residues without carry dependency [6]. RNS can be
scaled to higher ranges efficiently by carefully selecting moduli that are
large enough to cover the desired range while ensuring they remain relatively
prime. Commonly used moduli in RNS include small primes and powers of two. The
modulo set used in this work is (2n-1, 2n, 2n+1), that can represent
conventional numbers almost up to 23n. Equation 2 establishes the Range of the
RNS system as the product of the moduli set, where M represents the moduli
count, and the moduli set is R0, R1….. RM. We define Efficiency of the RNS
set, as the ratio of Range and the highest intended number (K), shown in
Equation 3. Efficiency can help compare and choose among various RNS sets.

$\displaystyle Range=\prod_{1}^{M}R$ (2) $\displaystyle
Efficiency=\frac{Range}{K}$ $\displaystyle\text{where }Range\leq K$ (3)

In classical computing, RNS finds applications in various fields, such as
digital image processing, digital signal processing, cryptography, neural
systems, and fault-tolerant computing systems [6]. In quantum computing, RNS
can facilitate larger and faster arithmetic operations, overcoming limitations
such as qubit count and coherence time of quantum computers. Redundancy in RNS
introduces additional control residues to detect and correct errors [16]. By
expanding the code combination with redundant residues, RNS can improve the
reliability of quantum computers.

###  II-C Distributed Quantum Computing

Distributed Quantum Computing (DQC) is an emerging paradigm of performing
quantum computations across multiple interconnected quantum computing devices
or nodes, also known as Quantum Processing Units (QPU). The goal is to
leverage the collective power of multiple QPU’s to solve complex computational
problems that cannot be efficiently solved by a single QPU. DQC aims to
overcome the limitations of individual quantum devices, such as limited qubit
counts and high error rates, and to enable the scaling of quantum computations
to larger problem sizes[10].

The pursuit of DQC involves various approaches, primarily categorized into
hardware and software solutions. Hardware solutions, like quantum
teleportation enabled using gate or qubit teleportation, necessitate efficient
quantum networking schemes for the transmission of quantum states across QPUs,
and are a vibrant area of research. On the other hand, software approaches,
such as circuit cutting, distribute parts of circuits among QPUs without the
need for a fully realized quantum network. However, circuit cutting faces
significant challenges, including the exponential increase in cost with the
entanglement between parts, the management of different noise profiles, and
the reconstruction of output [9].

Figure 3 shows our approach of using a Residue Number System (RNS) based
Distributed Quantum Computing (DQC), that converts quantum addition into
independent quantum modulo addition circuits across multiple QPUs or multiple
jobs on a single QPU. The QSMART Tool does not need complex networking
infrastructure, like in hardware-based DQC approaches. Also, unlike circuit
cutting, there is no dependency among different quantum modulo addition
circuits of initializing the input of one circuit based on the output of
another circuit.

##  III Proposed Quantum Diminished-1
Modulo (2n \+ 1) Adder

In order to achieve modulo (2n \+ 1) addition, we utilize Algorithm 1 to
construct the Quantum Diminished-1 Modulo (2n \+ 1) Adder (QDMA). The two
inputs, A = an an-1 … a0 and B = bn bn-1 … b0, are of size (n+1) qubits, while
their Sum is an (n+2) qubit integer Sum = A + B = Sn+1 Sn … S0. Algorithm 1
achieves optimized modulo (2n \+ 1) addition using different components of the
Sum.

In order to better handle the complexity introduced for handling 0 in modulo
(2n \+ 1) arithmetic, we utilize diminished-1 representation. In this
approach, we subtract one from the numbers in the range (1, 2n), while 0 is
represented by 2n. The Most Significant Bit (MSB) of the resulting
diminished-1 number is true only when representing 0, helping achieve a more
straightforward identification and handling of 0.

The algorithm reflects the advantage of using the diminished-1 approach. The
addition in Step 1 saves resources by having to add only (n-1) qubits, as it
handles the (1, 2n). Step 2 calculates the partial product
$\overline{A\textsubscript{n}}.\overline{B\textsubscript{n}}.\overline{Carry\textsubscript{n}}$
which is True only if both input’s MSB and Step1’s Carry are zero. To create
the three input quantum NAND gate, we utilize two Toffoli gates and six NOT
gates, one each for the inputs and later for the reversibility. The resulting
partial product is then placed at the Least Significant Bit (LSB) of the QDMA,
initialized with $|0$⟩. Step 3 utilizes a quantum half adder to ultimately add
the previous step’s partial product. The term An.Bn in Step 3 helps achieve
the addition when both inputs are zero. Figure 4 shows the proposed QDMA for
modulo 9, achieved when used in n=3 configuration.

Algorithm 1 : Calculation of $(A+B)mod(2^{n}+1)$

0: Inputs A, B are in diminished-1 format. $n\geq 1$

0: $0\leq{A,B}<{2^{n}+1}$

1\. Add the inputs except their most significant bits (MSB).
$Sum=A\textsubscript{n-1}A\textsubscript{n-2}...A\textsubscript{0}+B\textsubscript{n-1}B\textsubscript{n-2}...B\textsubscript{0}=Carry\textsubscript{n}S\textsubscript{n-1}...S\textsubscript{0}$

2\. Using the Carry from Step 2, compute:
$\overline{A\textsubscript{n}}.\overline{B\textsubscript{n}}.\overline{Carry\textsubscript{n}}$

3\.
$ModuloSum=(A\textsubscript{n}.B\textsubscript{n},S\textsubscript{n-1}...S\textsubscript{0})+\overline{A\textsubscript{n}}.\overline{B\textsubscript{n}}.\overline{Carry\textsubscript{n}}$

Figure 4: Proposed Quantum Modulo (2n \+ 1) Adder for n = 3 configuration
yielding Quantum Modulo 9 Adder. The inputs are A (A0:A3) and B (B0:B3), while
the output is Modulo Sum M (M0:M3). Input B (B0:B3) and MSB of A (A3) are
passed unchanged. The Sum (S0:S2:Carry3) represents the sum of (n-1) qubits of
inputs A and B. As shown in Algorithm 1, first the Sum is calculated, with the
Carry3 used to compute
$\overline{A\textsubscript{3}}.\overline{B\textsubscript{3}}.\overline{Carry\textsubscript{3}}$.
Finally, quantum half adder stage calculates the Modulo Sum M after adding
(A3.B3, S2 … S0) +
$\overline{A\textsubscript{3}}.\overline{B\textsubscript{3}}.\overline{Carry\textsubscript{3}}$

As the output or Modulo Sum M cannot exceed the modulus, its size is limited
to (n+1)-bits and is represented as M = Mn … M0. We use a quantum full adder
called TPL13 without input carry for: i) to save quantum resources, and ii)
its double inverted structure reduces the gap between qubit operations,
preventing coherence time issues and reducing noise [17, 18].

##  IV Proposed QSMART Tool

In this Section, we propose the QSMART Tool that generates Residue Number
System (RNS) based quantum modulo adders given input constraints such as the
range of numbers to be represented (0, K-1) and the desired minimum efficiency
of the RNS set (E). As shown in Algorithm 2, we start with a default moduli
count (C) three, as it corresponds to our starting RNS moduli set of (2n-1,
2n, 2n+1). The advantage of this set is the scaling it provides in
representing the range of numbers up to 23n. For instance, n = 2 yields a
moduli set (3, 4, 5) that can represent a range up to (3x4x5) 60, close to
(23x2) 64. Since the last four numbers cannot be represented, the efficiency
of this RNS moduli set is 93.75%. However, the tool can be pushed to limits by
choosing E = 1.0, leading to the choice of a moduli set that yields higher
ranges.

Algorithm 2 : QSMART Tool

0: 1\. Number K to be represented (K $\geq 50$).2. Moduli count C (default
value 3).3. RNS efficiency E (default value 0.9).4. Quantum modulo adder set:
(2n-1, 2n, 2n+1)

0: RNS set (R1, R2, R3) to be created.

1\. If K $\approx$ 23h, where h $\geq$ 2\. Select R where: R = (2h-1, 2h,
2h+1)

2\. Return R if $R_{1}\ast R_{2}\ast R_{3}\geq E\ast K$ . Else go to Step 3.

3\. Select lowest moduli from the moduli set such that: $\prod_{1}^{C}R\geq
E\ast K$

4\. If cannot satisfy Step 1, increment C and repeat Step 1.

5\. Determine the Toffoli depth for quantum adders for each moduli in set R.

6\. For moduli with maximum Toffoli depth, check alternate moduli with lower
Toffoli depth that meets constraint E.

7\. Return R once cannot optimize any further in Step 3.

For the range of numbers that do not correspond to 23n, we select other moduli
created using one of the moduli from 2n-1, 2n or 2n+1. For instance, when
representing (28) 256, we choose the set (5, 8, 9) as it can provide us with
the desired range using relatively prime moduli although derived using
different values of ’n.’ Moduli (22+1) 5, (23) 8, and (23+1) 9 can represent a
range up to (5x8x9) 360, that is much higher than the needed 256. Although we
could have chosen moduli 7 instead of 9, as the set (5x8x7) would have
fulfilled all requirements, we avoided it as the depth of quantum modulo 7
adder is higher than quantum modulo 9 adder by three Toffoli gates.

##  V Results

We conduct simulations using an emulator provided by Quantinuum to simulate
their 20-qubit H1 quantum computer. We perform these simulations for
TPL13-based quantum full adder from 6-bit to 10-bit output and quantum modulo
adders between 2 and 9 for the moduli set (2n-1, 2n, 2n+1). We initialize
circuits for these designs in $|0$⟩ and $|1$⟩ basis states on the PyTKET
platform. We simulate quantum modulo adders with a frequency of a hundred
shots, whereas the TPL13-based quantum full adders are simulated with two
hundred shots. To calculate the output probability, we take the ratio of the
correct output’s frequency with total frequency and take an average across all
the input combinations.

###  V-A Quantum Modulo Adders

Table I shows the output probability and quantum resource usage for the
quantum modulo adders. These include moduli (2n-1, 2n, 2n+1), which helps
perform RNS based quantum addition in this work. The primary observation is
the direct correlation of output probability to Toffoli depth. The output
probability gradually falls as the Toffoli depth increases from modulo 2 to
modulo 9. However, this effect is seen at different rates among adders of the
three types.

TABLE I: Comparison of Quantum Moduli Adders based on
Quantum Resource Usage and Output Probability.

Modulo Adder Qubit Depth Count Output Prob. Mod Type Toffoli CNOT Toffoli CNOT
2 2n 2 0 1 0 1 0.995 3 2n-1 7 6 7 8 8 0.912 3 2n+1 8 4 2 5 2 0.964 4 2n 4 1 1
1 2 0.985 5 2n+1 11 6 5 8 7 0.931 7 2n-1 10 12 10 14 12 0.865 8 2n 6 3 4 3 6
0.966 9 2n+1 14 9 7 11 13 0.893

Quantum modulo 2n adders have the highest output probability among all the
moduli because of their optimal design. For a modulo 2 quantum adder, only a
single CNOT gate is needed. As evident from Figure 1, for a modulo 4 quantum
adder only one Toffoli with two CNOT gates are needed, and for the modulo 8
quantum adder, we utilize the TPL13 quantum full adder by removing the gates
and qubits associated with carry generation. Our optimization for modulo 2n
conversion reduces Toffoli count and depth from five to three, a reduction of
40%. Similarly, the CNOT gate count reduces from ten to six, a drop of 40%,
and the CNOT depth reduces from seven to four, a drop of 42.85%.

The Quantum Diminished-1 Modulo (2n \+ 1) Adders (QDMA) are the next best
performing in Table I. They utilize fewer Toffoli and CNOT gates compared to
Quantum Modulo (2n \- 1) Adders (QMA) albeit with higher qubit count, leading
to lesser depth and higher output probability. This is evident from the
quantum modulo 3 adder, depicted in Figure 2, whose QDMA-based design has 33%
lower Toffoli depth and 71.4% lower CNOT depth compared to the QMA-based
design, leading to 5.7% higher output probability. For n=3, the QDMA-based
modulo 9 adder has 25% lower Toffoli depth and 30% lower CNOT depth relative
to the QMA-based modulo 7 adder, maintaining 3.27% higher output probability.

TABLE II: Comparison of TPL13 based Quantum Full Adders with QSMART Tool’s RNS based distributed quantum addition. Adder Size | Non-Distributed Quantum Addition (TPL13) | Distributed Quantum Addition (RNS)
---|---|---
Qubit Count | Depth |  Output Prob. | RNS Set |  Efficiency (in %) |  Max. Qubits | Max. Depth |  Output Prob. |  Gain w.r.t TPL13 (%)
Toffoli | CNOT | Toffoli | CNOT
6 | 11 | 9 | 13 | 0.836 | (3, 4, 5) | 93.75 | 11 | 6 | 5 | 0.931 | 11.36
7 | 13 | 11 | 16 | 0.702 | (4, 5, 9) | 100 | 14 | 9 | 7 | 0.893 | 27.21
8 | 15 | 13 | 19 | 0.595 | (5, 8, 9) | 100 | 14 | 9 | 7 | 0.893 | 50.08
9 | 17 | 15 | 22 | 0.481 | (7, 8, 9) | 98.44 | 14 | 12 | 10 | 0.862 | 79.21
10 | 19 | 17 | 25 | 0.371 | (4, 5, 7, 9) | 100 | 14 | 12 | 10 | 0.865 | 133.15
11 | 21 | 19 | 28 | N.A. | (5, 7, 8, 9) | 100 | 14 | 12 | 10 | 0.865 | N.A.

###  V-B Noise-Resilience of QSMART Tool

Table II compares quantum addition attained via TPL13 quantum full adder and
the QSMART tool’s RNS based distributed quantum addition on Quantinuum H1
quantum computer’s noise-based simulations. For each adder size of TPL13, the
equivalent RNS set computed by QSMART Tool (with a default efficiency setting
of 90%) is shown. In Table II, RNS efficiency denotes the percentage of the
range covered by the RNS moduli set. For RNS, the maximum qubits or depth are
the maximum qubit count or depth, respectively, among the quantum modulo adder
circuits of the RNS set. Similarly, the output probability of the RNS set is
the minimum output probability across the quantum modulo adder circuits
comprising the RNS set. Ultimately, we list the percentage gain in output
probability achieved by the RNS set over the corresponding TPL13-based adder.

Table II shows a clear trend of rising output probability gain in favor of
distributed quantum addition (based on RNS) compared to non-distributed
quantum addition (based on TPL13). Compared to the TPL13 adder of 5 qubits
input size, the equivalent RNS set (3, 4, 5) has Toffoli depth reduced by
three gates, and CNOT depth reduced to less than half, leading to 11.36%
higher output probability. However, as the effective range of the RNS set is
60 compared to 64 of TPL13, the RNS efficiency is 93.75%.

##  VI Discussion

Figure 5: Comparison of Output Probability between TPL13 based quantum full
adders and QSMART Tool’s RNS based distributed quantum addition for output
sizes 6 to 10 qubit.

As we scale the adder output size from 6 to 10 qubits, the output probability
drops from 0.836 to 0.371. However, for the corresponding RNS sets, the output
probability declines from 0.931 to 0.865. The lower rate of decline for the
RNS set demonstrates its noise resilience on the Quantinuum H1 quantum
computer’s noise-based simulations. Using a higher efficiency of 1.0 in the
QSMART Tool creates an RNS set (3, 5, 8) with twice the effective range than
before. Quantum modulo 8 adder consumes higher resources than quantum modulo 4
adder. However, since the quantum modulo 8 adder consumes fewer resources than
the other two moduli in the RNS set, there is no change in the maximum qubit
count, depth, or output probability. Hence, as shown in Figure 5, the
advantage of RNS to run three independent quantum jobs, helps Distributed
Quantum Computing (DQC) to limit the loss of output probability.

As shown in the last entry of Table II, we can achieve addition equivalent to
a quantum full adder of output size 11 or (211) 2048 by using the RNS set (5,
7, 8, 9). Since this requires 21 qubits, it cannot be performed on
Quantinuum’s H1 quantum computer. This shows the potential for scaling by
QSMART Tool to achieve addition beyond the range of NISQ-era quantum
computers. For achieving higher ranges, we can scale the tool with the moduli
set (2n-1, 2n, 2n+1) and also use the prime moduli described in Table I to
help keep quantum resource consumption in check.

##  VII Conclusion

We conclude that Residue Number Systems (RNS) have great potential to achieve
Distributed Quantum Computing (DQC) in the current NISQ era quantum computers
by increasing noise-resilience and also in the Fault Tolerant Quantum (FTQ)
computers by helping run smaller depth quantum arithmetic circuits
independently across machines or jobs. The proposed QSMART Tool has shown
potential in achieving these objectives by demonstrating a gain in output
probability of 11.36% to 133.15% compared to non-distributed quantum addition
of output sized six to ten qubits on Quantinuum H1 noise simulator.
Furthermore, we show the possibility of achieving quantum addition for larger
sizes unachievable by the Quantinuum H1 quantum computer. In the future,
quantum multiplication, quantum image, and signal processing tasks could
benefit from the speed and parallelism offered by RNS.

## References

  * [1] P. W. Shor, “Algorithms for quantum computation: discrete logarithms and factoring,” in _Proceedings 35th annual symposium on foundations of computer science_. Ieee, 1994, pp. 124–134.
  * [2] B. Duan, J. Yuan, C.-H. Yu, J. Huang, and C.-Y. Hsieh, “A survey on hhl algorithm: From theory to application in quantum machine learning,” _Physics Letters A_ , vol. 384, no. 24, p. 126595, 2020.
  * [3] T. Hur _et al._ , “Quantum convolutional neural network for classical data classification,” _Quantum Machine Intelligence_ , vol. 4, no. 1, p. 3, 2022\.
  * [4] Y. Lee, J. Joo, and S. Lee, “Hybrid quantum linear equation algorithm and its experimental test on ibm quantum experience,” _Scientific reports_ , vol. 9, no. 1, p. 4778, 2019.
  * [5] E. Muñoz-Coreas and H. Thapliyal, “Quantum circuit design of a t-count optimized integer multiplier,” _IEEE Transactions on Computers_ , vol. 68, no. 5, pp. 729–739, 2018.
  * [6] P. A. Mohan, _Residue Number Systems_. Springer, 2016.
  * [7] M. Roetteler, M. Naehrig, K. M. Svore, and K. Lauter, “Quantum resource estimates for computing elliptic curve discrete logarithms,” in _Advances in Cryptology–ASIACRYPT 2017_.
  * [8] D. S. C. Putranto, R. W. Wardhani, H. T. Larasati, and H. Kim, “Another concrete quantum cryptanalysis of binary elliptic curves,” _Cryptology ePrint Archive_ , 2022.
  * [9] W. Tang and M. Martonosi, “Distributed quantum computing via integrating quantum and classical computing,” _Computer_ , vol. 57, no. 4, pp. 131–136, 2024.
  * [10] D. Barral, F. J. Cardama, G. Díaz, D. Faílde, I. F. Llovo, M. M. Juane, J. Vázquez-Pérez, J. Villasuso, C. Piñeiro, N. Costas _et al._ , “Review of distributed quantum computing. from single qpu to high performance quantum computing,” _arXiv preprint arXiv:2404.01265_ , 2024\.
  * [11] S. Sivarajah, S. Dilkes, A. Cowtan, W. Simmons, A. Edgington, and R. Duncan, “t—ket⟩: a retargetable compiler for nisq devices,” _Quantum Science and Technology_ , vol. 6, no. 1, p. 014003, nov 2020. [Online]. Available: https://dx.doi.org/10.1088/2058-9565/ab8e92
  * [12] V. Vedral, A. Barenco, and A. Ekert, “Quantum networks for elementary arithmetic operations,” _Physical Review A_ , vol. 54, no. 1, p. 147, 1996\.
  * [13] S. Beauregard, G. Brassard, and J. M. Fernandez, “Quantum arithmetic on galois fields,” _arXiv preprint quant-ph/0301163_ , 2003.
  * [14] R. Van Meter and K. M. Itoh, “Fast quantum modular exponentiation,” _Phys. Rev. A_ , vol. 71, p. 052320, May 2005.
  * [15] A. Kim, S.-M. Cho, C.-B. Seo, S. Lee, and S.-H. Seo, “Quantum modular adder over gf (2 n- 1) without saving the final carry,” _Applied Sciences_ , vol. 11, no. 7, p. 2949, 2021.
  * [16] I. A. Kalmykov, V. P. Pashintsev, K. T. Tyncherov, A. A. Olenev, and N. K. Chistousov, “Error-correction coding using polynomial residue number system,” _Applied Sciences_ , vol. 12, no. 7, p. 3365, 2022.
  * [17] H. Thapliyal and N. Ranganathan, “Design of efficient reversible logic-based binary and bcd adder circuits,” _ACM Journal on Emerging Technologies in Computing Systems (JETC)_ , vol. 9, no. 3.
  * [18] B. Gaur, T. Humble, and H. Thapliyal, “Noise-resilient and reduced depth approximate adders for nisq quantum computing,” in _Proceedings of the Great Lakes Symposium on VLSI 2023_ , 2023, pp. 427–431.


# On sets of discontinuities of functions continuous on all lines

Luděk Zajíček<EMAIL_ADDRESS>Charles University, Faculty of
Mathematics and Physics, Sokolovská 83, 186 75 Praha 8-Karlín, Czech Republic

###### Abstract.

Answering a question asked by K.C. Ciesielski and T. Glatzer in 2013, we
construct a $C^{1}$-smooth function $f$ on $[0,1]$ and a set
$M\subset\operatorname{graph}f$ nowhere dense in $\operatorname{graph}f$ such
that there does not exist any linearly continuous function on
${\mathbb{R}}^{2}$ (i.e. function continuous on all lines) which is
discontinuous at each point of $M$. We substantially use a recent full
characterization of sets of discontinuity points of linearly continuous
functions on ${\mathbb{R}}^{n}$ proved by T. Banakh and O. Maslyuchenko in
2020. As an easy consequence of our result, we prove that the necessary
condition for such sets of discontinuities proved by S.G. Slobodnik in 1976 is
not sufficient. We also prove an analogon of this Slobodnik’s result in
separable Banach spaces.

###### Key words and phrases:

linear continuity, discontinuity sets, Banach space

###### 2010 Mathematics Subject Classification:

Primary: 26B05; Secondary: 46B99.

##  1\. Introduction

Separately continuous functions on ${\mathbb{R}}^{n}$ (i.e. functions
continuous on all lines parallel to an coordinate axis) and also linearly
continuous functions (i.e. functions continuous on all lines) were
investigated in a number of articles, see the survey [5]. Note that linearly
continuous functions are well-defined in any linear space and recent articles
[13] and [2] investigate them also in Banach (and even more general) spaces.

It appears that linearly continuous functions are much “more close to
continuous functions” than separately continuous functions. First note that,
by Lebesgue’s result of [9],

(1.1) each separately continuous function on ${\mathbb{R}}^{n}$ belongs to the
$(n-1)$-th Baire class

(and that the number $n-1$ is optimal, cf. [5]). On the other hand, it was
proved independently (answering a question posed in [5]) in [13] and [2] that
each linearly continuous function on ${\mathbb{R}}^{n}$ belongs to the first
Baire class.

A natural question how small must be members of the families (where $D(f)$
denotes the set of discontinuity points of $f$)

$\cal D_{s}^{n}:=\\{D(f):\ f\ \text{is a separately continuous function on}\
{\mathbb{R}}^{n}\\}$

and

$\cal D_{l}^{n}:=\\{D(f):\ f\ \text{is a linearly continuous function on}\
{\mathbb{R}}^{n}\\}$

was considered in several works, see [5]. Clearly, $D_{l}^{n}\subset\cal
D_{s}^{n}$ and each set from $\cal D_{s}^{n}$ is an $F_{\sigma}$ set. It
appears that the sets from $D_{l}^{n}$ “must be essentially smaller” than
those from $\cal D_{s}^{n}$.

The following complete characterization of sets from $\cal D_{s}^{n}$ was
given in [7] (and was proved independently by another method in [11]).

######  Theorem 1.1.

(R. Kershner, 1943)

A set $M\subset{\mathbb{R}}^{n}$ belongs to $\cal D_{s}^{n}$ if and only if
$M$ is an $F_{\sigma}$ set and the orthogonal projection of $M$ onto each
$(n-1)$-dimensional coordinate hyperplane is a first category (= meager) set.

This characterization shows that each member of $\cal D_{s}^{n}$ is a first
category set, but it can have positive Lebesgue measure (even its complement
can be Lebesgue null, cf. [5]). On the other hand (see Remark 1.3 (a) below)
all members of $D_{l}^{n}$ are Lebesgue null.

Probably the first result concerning the system $D_{l}^{n}$ was published in
1910 by W.H Young and G.C. Young [12]; they constructed a linearly continuous
function on $[0,1]^{2}$ for which $D(f)$ is uncountable in every nonempty open
set.

A.S. Kronrod in 1945 (see [10, p. 268], [5, p. 28]) considered the natural
problem to find a complete characterization of sets from the system
$D_{l}^{2}$.

As a partial solution of ($n$-dimensional) Kronrod’s problem, Slobodnik proved
a theorem ([11, Theorem 6]) whose obvious reformulation reads as follows.

######  Theorem 1.2.

(Slobodnik, 1976) Let $M\in D_{l}^{n}$. Then we can write
$M=\bigcup_{k=1}^{\infty}B_{k}$, where each $B_{k}$ has the following
properies.

  1. (i)

$B_{k}$ is a compact subset of a Lipschitz hypersurface $L_{k}$.

  2. (ii)

The orthogonal projection of $B_{k}$ onto each $(n-1)$-dimensional hyperplane
$H\subset{\mathbb{R}}^{n}$ is nowhere dense in $H$.

  3. (iii)

For each $c\in{\mathbb{R}}^{n}\setminus B_{k}$, the set
$\\{\frac{x-c}{\|x-c\|}:\ x\in B_{k}\\}$ is nowhere dense in the unite sphere
$S_{{\mathbb{R}}^{n}}$.

######  Remark 1.3.

  1. (a)

For the definition of a Lipschitz hypersurface see Definition 2.1. Property
(i) clearly implies that $M\subset{\mathbb{R}}^{n}$ is Lebesgue null.

  2. (b)

The article [10] (written independently on [11]) contains results which are
very close to Theorem 1.2 with $n=2$.

  3. (c)

Conditions (i) and (ii) clearly imply that in (i) we can write that $B_{k}$ is
nowhere dense in $L_{k}$.

  4. (d)

An equivalent reformulation of (iii) (used in [11]) is the following:

(iii)* For each $c\in{\mathbb{R}}^{n}\setminus B_{k}$ and each hyperplane
$H\subset{\mathbb{R}}^{n}\setminus\\{c\\}$, the central projection from $c$ of
$B_{k}$ onto $H$ is nowhere dense in $H$.

Further interesting contributions to Kronrod’s problem were proved in [3] and
[4]. Main results of [3] read as follows.

######  Theorem 1.4.

(K.Ch. Ciesielski and T. Glatzer, 2012)

  1. (i)

If $n\geq 2$ and $f:{\mathbb{R}}^{n-1}\to{\mathbb{R}}$ is convex and
$M\subset\operatorname{graph}f$ is nowhere dense in $\operatorname{graph}f$,
then there exists a linearly continuous function $g$ on ${\mathbb{R}}^{n}$
such that $M\subset D(g)$.

  2. (ii)

If $f:{\mathbb{R}}\to{\mathbb{R}}$ is $C^{2}$ smooth and
$M\subset\operatorname{graph}f$ is nowhere dense in $\operatorname{graph}f$,
then there exists a linearly continuous function $g$ on ${\mathbb{R}}^{2}$
such that $M\subset D(g)$.

  3. (iii)

There exists $f:{\mathbb{R}}\to{\mathbb{R}}$ having bounded derivative and
$M\subset\operatorname{graph}f$ which is nowhere dense in
$\operatorname{graph}f$ such that there does not exist any linearly continuous
function $g$ on ${\mathbb{R}}^{2}$ such that $M\subset D(g)$.

The article [4] contains a full characterization of sets from $D_{l}^{2}$.
However, this solution of Kronrod’s problem (in ${\mathbb{R}}^{2}$) is not
quite satisfactory (cf. [5, p. 29]) since it uses the topology on the set of
all lines in ${\mathbb{R}}^{2}$ (and its applicability is unclear).

A nice applicable solution of Kronrod’s problem in ${\mathbb{R}}^{n}$ was
proved by T. Banakh and O. Maslyuchenko in [2]. It asserts that a subset of
${\mathbb{R}}^{n}$ belongs to $D_{l}^{n}$ if and only if it is
“$\overline{\sigma}$-$l$-miserable” (see Subsection 2.3 for details). In [2],
several applications of this characterization are shown and other two
applications are contained in the present article.

In Section 3 we use the Banakh-Maslyuchenko characterization as the main
ingredience in the proof of the main result of the present article (Theorem
3.4) which shows, answering a question from [3], that the function $f$ from
Theorem 1.4 (iii) can be even $C^{1}$-smooth. More precisely, we use this
characterization in the proof ot the basic Lemma 3.1. It seems that any proof
of Theorem 3.4 based on Lemma 3.1 needs a nontrivial inductive construction.
The idea of our construction based on Lemma 2.3 and Lemma 3.2 is not
difficult, but the detailed proof is unfortunately rather long and slightly
technical.

As an easy but interesting consequence of our Theorem 3.4, we obtain in
Section 4 that Slobodnik’s necessary condition for sets from $D_{l}^{n}$ is
not sufficient (which supports the opinion that there exists no
characterization of sets from $\cal D_{l}^{n}$ similar to Kershner’s
characterization of sets from $\cal D_{s}^{n}$).

In Section 5, we prove an analogon of Slobodnik’s result in separable Banach
spaces for functions having the Baire property (which improves [13, Corollary
4.2]). This result (Proposition 5.1) which easily implies Slobodnik’s theorem
in ${\mathbb{R}}^{n}$ is an easy consequence of [13, Corollary 4.2] and the
Banakh-Maslyuchenko characterization.

##  2\. Preliminaries

###  2.1. Basic notation

In the following, by a Banach space we mean a real Banach space with a norm
$\|\cdot\|$. If $X$ is a Banach space, we set $S_{X}:=\\{x\in X:\|x\|=1\\}$.
By $C[0,1]$ and $C^{1}[0,1]$ we denote the set of all continuous and
$C^{1}$-smooth functions on $[0,1]$, respectively. If $f\in C[0,1]$, then
$\|f\|$ always denotes the supremum norm of $f$.

The symbol $B(x,r)$ will denote the open ball with center $x$ and radius $r$.
We say that a set $Q$ is an $\varepsilon$-net of a subset $A$ of a metric
space, if $Q\subset A\subset\bigcup_{x\in Q}B(x,\varepsilon)$.

The oscillation of a function $f$ on a set $M$ will be denoted by
$\operatorname{osc}(f,M)$. By $\operatorname{graph}f$, $\operatorname{supp}f$
and $D(f)$, we denote the graph, the closed support $\overline{\\{x:f(x)\neq
0\\}}$ and the set of discontinuity points of $f$, respectively. We will write
$f_{n}\rightrightarrows f$ if the sequence $(f_{n})$ uniformly converges to
$f$. The Lebesgue measure on ${\mathbb{R}}$ is denoted by $\lambda$.

In a metric space $X$, the system of all sets with the Baire property is the
smallest $\sigma$-algebra containing all open sets and all first category
sets. We say that a function $f$ on $X$ has the Baire property if $f^{-1}(B)$
has the Baire property for all Borel sets $B\subset Y$ (see [8, $\S$ 32]). We
will use the following definition.

######  Definition 2.1.

Let $X$ be a Banach space. We say that $A\subset X$ is a Lipschitz
hypersurface if there exists a $1$-dimensional linear space $V\subset X$, its
topological complement $Y$ and a Lipschitz mapping $\varphi:Y\to V$ such that
$A=\\{y+\varphi(y):\ y\in Y\\}$.

It is easy to see that each Lipschitz hypersurface is a closed set and that,
if $X={\mathbb{R}}^{n}$, then we can demand that $Y$ is an orthogonal
complement of $V$.

###  2.2. Notation and two lemmas concerning tangent lines

If $f\in C^{1}[0,1]$, $z\in[0,1]$ and $Z\subset[0,1]$, then we use the
following notation.

  1. (i)

By $A_{f,z}$ we denote the affine function

$A_{f,z}(x)=f(z)+f^{\prime}(z)(x-z),\ x\in{\mathbb{R}}.$

  2. (ii)

By $T_{f,z}$ we denote the tangent line to $\operatorname{graph}f$ at the
point $(z,f(z))$, i.e.

$T_{f,z}:=\operatorname{graph}(A_{f,z}).$

  3. (iii)

We set

$T_{f,Z}:=\bigcup_{z\in Z}T_{f,z}.$

We will need the following easy lemma.

######  Lemma 2.2.

Let functions $f$ and $f_{1},f_{2},\dots$ belong to $C^{1}[0,1]$. Suppose that
$z$ and $z_{1},z_{2}\dots$ belong to $[0,1]$, $(x,y)\in{\mathbb{R}}^{2}$ and

$f_{n}\rightrightarrows f,\ \ \ f^{\prime}_{n}\rightrightarrows f^{\prime},\ \
\ z_{n}\to z.$

Then the conditions $(x,y)\in T_{f_{n},z_{n}}$, $n=1,2,\dots$, imply $(x,y)\in
T_{f,z}$.

###### Proof.

By the assumptions, we have $f_{n}(z_{n})+f^{\prime}_{n}(z_{n})(x-z_{n})=y$,
$n\in{\mathbb{N}}$. Since $f_{n}(z_{n})\to f(z)$ and $f^{\prime}_{n}(z_{n})\to
f^{\prime}(z)$ (see, e.g., [6, Theorem 7.5, p. 268]), we obtain
$f(z)+f^{\prime}(z)(x-z)=y$. ∎

The following lemma is also rather easy but is an important ingredient in our
proof of Theorem 3.4.

######  Lemma 2.3.

Suppose that $f\in C^{1}[0,1]$ and $f^{\prime}$ has infinite variation on an
interval $[\alpha,\beta]\subset[0,1]$. Then there exist numbers $e$, $w$ such
that $\alpha<e<w<\beta$ and $(w,f(w))\in T_{f,e}$.

###### Proof.

First observe that there exist numbers $e_{0}$, $w_{0}$, $e_{1}$, $w_{1}$ such
that $\alpha<e_{0}<w_{0}<\beta$, $\alpha<e_{1}<w_{1}<\beta$ and

(2.1) $f(w_{0})<f(e_{0})+f^{\prime}(e_{0})(w_{0}-e_{0}),\ \ \
f(w_{1})>f(e_{1})+f^{\prime}(e_{1})(w_{1}-e_{1}).$

To construct $e_{0}$ and $w_{0}$, note that $f^{\prime}$ is not nondecreasing
on $(\alpha,\beta)$ and thus we can choose numbers $\alpha<e^{*}<w_{0}<\beta$
with $f^{\prime}(e^{*})>f^{\prime}(w_{0})$. Set
$e_{0}:=\max\\{x\in[e^{*},w_{0}]:\ f^{\prime}(x)=f^{\prime}(e^{*})\\}$. Then
we have

$f(w_{0})=f(e_{0})+\int_{e_{0}}^{w_{0}}f^{\prime}<f(e_{0})+f^{\prime}(e_{0})(w_{0}-e_{0})$

and so $e_{0}$ and $w_{0}$ satisfy (2.1). The existence of $e_{1}$ and $w_{1}$
follows quite analogously.

Now set

$e(t):=te_{1}+(1-t)e_{0},\ \ w(t):=tw_{1}+(1-t)w_{0},\ \ \ t\in[0,1].$

Then clearly $e(0)=e_{0},\ w(0)=w_{0},\ e(1)=e_{1},\ w(1)=w_{1}$ and
$e(t)<w(t),\ t\in[0,1]$. The function
$g(t):=f(w(t))-f(e(t))-f^{\prime}(e(t))(w(t)-e(t)),\ t\in[0,1],$ is clearly
continuous, $g(0)<0$ and $g(1)>0$. Consequently there exists $t^{*}\in(0,1)$
such that $g(t^{*})=0$ and so $e:=e(t^{*})$ and $w:=w(t^{*})$ have the
required property. ∎

###  2.3. Banakh-Maslyuchenko characterization

The authors of [2] work in “Baire cosmic vector spaces” but we work in the
present article in the more special context of separable Banach spaces; so we
present basic definitions from [2] in Banach spaces only.

######  Definition 2.4.

Let $X$ be a Banach space and $A\subset X$.

  1. (i)

A set $V\subset X$ is called an $l$-neighborhood of $A$ if for any $a\in A$
and $v\in X$ there exists $\varepsilon>0$ such that $a+[0,\varepsilon)\cdot
v\subset V$.

  2. (ii)

$A$ is called $l$-miserable if $A\subset\overline{X\setminus L}$ for some
closed $l$-neighborhood $L$ of $A$.

  3. (iii)

$A$ is called $\overline{\sigma}$-$l$-miserable if $A$ is a countable union of
closed $l$-miserable sets.

An immediate consequence of [2, Theorem 1.5.] is the following result.

######  Theorem 2.5.

( T. Banakh and O. Maslyuchenko, 2020)

Let $X$ be a separable Banach space and $M\subset X$. Then the following
conditions are equivalent.

  1. (i)

$M=D(f)$ for some linearly continuous function $f$ on $X$ which has the Baire
property.

  2. (ii)

$M$ is $\overline{\sigma}$-$l$-miserable.

Note that if $X={\mathbb{R}}^{n}$, then each linearly continuous function on
$X$ has the Baire property by (1.1) and so Theorem 2.5 gives a full
characterization of sets of discontinuities of linearly continuous functions
on ${\mathbb{R}}^{n}$.

##  3\. Main result

In this section we prove our main Theorem 3.4 using the following basic lemma,
whose rather easy proof is based on the Banakh-Maslyuchenko characterization
(Theorem 2.5).

######  Lemma 3.1.

Let $f\in C^{1}[0,1]$, let $\emptyset\neq P\subset(0,1)$ be a perfect nowhere
dense set and let $D\subset P$ be a countable dense subset of $P$. Let, for
each $d\in D$, two points $u_{d},v_{d}\in(0,1)$ be given such that
$u_{d}<v_{d}<d$,

(3.1) $(d,f(d))\in\operatorname{int}T_{f,[u_{d},v_{d}]\cap P}$

and

(3.2) the set $D_{\varepsilon}:=\\{d\in D:d-u_{d}>\varepsilon\\}$ is finite
for each $\varepsilon>0$.

Then there does not exist any linearly continuous function $g$ on
${\mathbb{R}}^{2}$ which is discontinuous at each point of the set
$\operatorname{graph}(f|_{P})$.

###### Proof.

Suppose to the contrary that such a function $g$ exists. By Theorem 2.5 there
exists a $\overline{\sigma}$-$l$-miserable set $A\subset{\mathbb{R}}^{2}$ such
that $\operatorname{graph}(f|_{P})\subset A$. Let $A_{1},A_{2},\dots$ be
closed $l$-miserable subsets of ${\mathbb{R}}^{2}$ such that
$A=\bigcup_{n=1}^{\infty}A_{n}$. Since the set $\operatorname{graph}(f|_{P})$
is closed in ${\mathbb{R}}^{2}$, by the Baire theorem there exists
$k\in{\mathbb{N}}$ such that the closed set
$A_{k}\cap\operatorname{graph}(f|_{P})$ is not nowhere dense in
$\operatorname{graph}(f|_{P})$ and so there exists an interval
$(a,b)\subset[0,1]$ such that $P\cap(a,b)\neq\emptyset$ and
$\operatorname{graph}(f|_{P\cap(a,b)})\subset A_{k}$. Since $A_{k}$ is
$l$-miserable, we can choose a closed $l$-neighbourhood $L$ of $A_{k}$ such
that $A_{k}\subset\overline{H}$, where $H:={\mathbb{R}}^{2}\setminus L$.
Further choose $K>0$ such that $\|f^{\prime}\|\leq K$.

Now we will construct inductively a sequence of intervals $[a_{n},b_{n}]$,
$n=0,1,\dots$, such that for each $n\geq 0$ the following two conditions hold.

(C1) $[a_{n},b_{n}]\subset(a,b)$, $(a_{n},b_{n})\cap P\neq\emptyset$ and
$n(b_{n}-a_{n})<1$.

(C2) If $n\geq 1$, then $[a_{n},b_{n}]\subset(a_{n-1},b_{n-1})$ and for each
$x\in[a_{n},b_{n}]$ there exists a point $z_{x}^{n}\in T_{f,x}\cap H$ such
that $\|z_{x}^{n}-(x,f(x))\|<3(K+1)/n$.

We can clearly choose $[a_{0},b_{0}]$ such that condition (C1) holds for
$n=0$.

Further suppose that $n\geq 1$ and we have defined $[a_{n-1},b_{n-1}]$ such
that condition (C1) holds for “$n=n-1$”. Choose $p_{n}\in
P\cap(a_{n-1},b_{n-1})$ and $\delta_{n}>0$ such that
$[p_{n}-\delta_{n},p_{n}+\delta_{n}]\subset(a_{n-1},b_{n-1})$. Since $P$ is
perfect, the set $D\cap(p_{n}-\delta_{n},p_{n}+\delta_{n})$ is infinite and so
by (3.2) we can choose $d_{n}\in D\cap(p_{n}-\delta_{n},p_{n}+\delta_{n})$
such that $[u_{d_{n}},v_{d_{n}}]\subset(a_{n-1},b_{n-1})$ and
$d_{n}-u_{d_{n}}<1/n$.

We know that $(d_{n},f(d_{n}))\in\operatorname{graph}f|_{P\cap(a,b)}\subset
A_{k}\subset\overline{H}$. Thus, since
$(d_{n},f(d_{n}))\in\operatorname{int}T_{f,[u_{d_{n}},v_{d_{n}}]\cap P}$ by
(3.1) and $H$ is open, we can choose an open set $W\neq\emptyset$ such that

(3.3) $W\subset B((d_{n},f(d_{n})),1/n)\cap H\cap
T_{f,[u_{d_{n}},v_{d_{n}}]\cap P}.$

Consequently we can choose $x_{n}\in[u_{d_{n}},v_{d_{n}}]\cap P$ for which
$T_{f,x_{n}}\cap W\neq\emptyset$. Since $f\in C^{1}[0,1]$ and $W$ is open, it
is easy to see that there exists an open neighbourhood $(a_{n},b_{n})$ of
$x_{n}$ such that $[a_{n},b_{n}]\subset(a_{n-1},b_{n-1})$, $b_{n}-a_{n}<1/n$
and $T_{f,x}\cap W\neq\emptyset$ for each $x\in[a_{n},b_{n}]$. So we can
choose for each $x\in[a_{n},b_{n}]$ a point
$z_{x}^{n}=(\alpha_{x}^{n},\beta_{x}^{n})\in T_{f,x_{n}}\cap W$. Obviously
(C1) holds and $[a_{n},b_{n}]\subset(a_{n-1},b_{n-1})$ and thus it is
sufficient to check that $\|z_{x}^{n}-(x,f(x))\|<3(K+1)/n$. To this end first
observe that $|x-\alpha_{x}^{n}|<3/n$ since we easily see that
$|d_{n}-\alpha_{x}^{n}|<1/n$, $|d_{n}-x_{n}|<1/n$ and $|x_{n}-x|<1/n$. Since
the absolute value of the slope of the tangent $T_{f,x}$ is at most $K$, we
obtain that

$\|z_{x}^{n}-(x,f(x))\|\leq\sqrt{|x-\alpha_{x}^{n}|^{2}+(K|x-\alpha_{x}^{n}|)^{2}}\leq(1+K)|x-\alpha_{x}^{n}|<3(K+1)/n.$

So we have finished our inductive costruction.

Now observe that the closedness of $P$ and condition (C1) imply that
$\bigcap_{n=0}^{\infty}[a_{n},b_{n}]=\\{p\\}$ for some $p\in P\cap(a,b)$.
Applying (C2) to $p$ for ech $n\geq 1$ we obtain points $z_{p}^{n}\in
T_{f,p}\cap H$, $n\geq 1$, such that $z_{p}^{n}\to(p,f(p))\in A_{k}$.
Consequently $L={\mathbb{R}}^{2}\setminus H$ is not an $l$-neigbourhood of
$A_{k}$, which is a contradiction. ∎

We will need also the following technical lemma.

######  Lemma 3.2.

Let $G$ and $\tilde{G}$ be functions from $C^{1}[0,1]$ and $g:=G^{\prime}$,
$\tilde{g}:=(\tilde{G})^{\prime}$. Let numbers $0<u<z<v<x<1$,
$y\in{\mathbb{R}}$ and $\varepsilon>0$, $\delta>0$, $\eta>0$ have the
following properties:

(3.4) $v+\delta+\eta<x,\ \ v-u<\eta\ \ \text{and}\ \
6\eta<\varepsilon\,\delta,$ (3.5) $(x,y)\in T_{G,z},$ (3.6)
$\|G-\tilde{G}\|\leq\eta,$ (3.7) $\|g\|\leq 1\ \ \ \text{and}\ \ \
\operatorname{osc}(g,[u,v])\leq\eta,$ (3.8) $\text{ there exist
$u<s_{1}<s_{2}<v$ such that $\tilde{g}(s_{1})=g(s_{1})-\varepsilon$ and
$\tilde{g}(s_{2})=g(s_{2})+\varepsilon$}.$

Then

(3.9) $B((x,y),\eta)\subset T_{\tilde{G},(u,v)}.$

###### Proof.

Consider an arbitrary point $(\overline{x},\overline{y})\in B((x,y),\eta)$.
Then $x-\eta<\overline{x}<x+\eta$ and $y-\eta<\overline{y}<y+\eta$. Let
$s_{1}$, $s_{2}$ be as in (3.8). Set

$h(s):=A_{\tilde{G},s}(\overline{x})=\tilde{G}(s)+\tilde{g}(s)\cdot(\overline{x}-s),\
\ \ s\in[s_{1},s_{2}].$

It is sufficient to prove that

(3.10) $h(s_{1})\leq y-\eta\ \ \ \ \text{and}\ \ \ h(s_{2})\geq y+\eta.$

Indeed, (3.10) and the continuity of the function $h$ imply that there exists
$\overline{s}\in(s_{1},s_{2})$ such that $h(\overline{s})=\overline{y}$;
consequently $(\overline{x},\overline{y})\in T_{\tilde{G},(u,v)}$ and (3.9)
follows.

Recall that
$h(s_{1})=\tilde{G}(s_{1})+\tilde{g}(s_{1})\cdot(\overline{x}-s_{1})$,
$h(s_{2})=\tilde{G}(s_{2})+\tilde{g}(s_{2})\cdot(\overline{x}-s_{2})$. By
(3.5),

$y=G(z)+g(z)(x-z)=G(z)+g(s_{1})(x-z)+(g(z)-g(s_{1}))(x-z)\\\
=G(z)+g(s_{1})((\overline{x}-s_{1})+(x-\overline{x})+(s_{1}-z))+(g(z)-g(s_{1}))(x-z).$

Using these equalities, $\eqref{cisla}$, $\eqref{ggt}$, $\eqref{og}$, the
choice of $s_{1}$, $s_{2}$ and the inequality $|G(z)-G(s_{1})|<\eta$ which
follows from (3.7) and $|z-s_{1}|<\eta$ by the mean value theorem, we obtain

$y-h(s_{1})=(G(z)-G(s_{1}))+(G(s_{1})-\tilde{G}(s_{1}))+(g(s_{1})-\tilde{g}(s_{1}))(\overline{x}-s_{1})+g(s_{1})(x-\overline{x})\\\
+g(s_{1})(s_{1}-z)+(g(z)-g(s_{1}))(x-z)\geq-\eta-\eta+\varepsilon\delta-\eta-\eta-\eta\geq\eta.$

Quite analogously we obtain $y-h(s_{2})\leq-\eta$ and $\eqref{hzjd}$ follows.
∎

The proof of our main Theorem 3.4 is based on the construction of $f\in
C^{1}[0,1]$, $P\subset[0,1]$ (and also $D$ and $u_{d}$, $v_{d}$) which satisfy
assumptions of Lemma 3.1. We will set $f:=\lim_{n\to\infty}f_{n}$ and
$P:=\bigcap_{n=1}^{\infty}P_{n}$, where $(f_{n})$ and $(P_{n})$ are defined by
a nontrivial inductive construction, in which each $P_{n}$ is a finite union
of compact intervals. For sets $P_{n}$ we will use the following notation.

######  Definition 3.3.

If $\emptyset\neq P\subset{\mathbb{R}}$ is a finite union of nondegenerate
compact intervals, we

  1. (i)

denote by $\cal C(P)$ the set of all components of $P$, and set

  2. (ii)

$R(P):=\\{d\in{\mathbb{R}}:\ d\ \text{is a right endpoint of some}\ I\in\cal
C(P)\\}$,

  3. (iii)

$\nu(P):=\max\\{\lambda(I):\ I\in\cal C(P)\\}.$

######  Theorem 3.4.

There exist $f\in C^{1}[0,1]$ and a closed set $M\subset\operatorname{graph}f$
which is nowhere dense in $\operatorname{graph}f$ such that there does not
exist any linearly continuous $g$ on ${\mathbb{R}}^{2}$ which is discontinuous
at each point of $M$.

###### Proof.

We will define sequences $(\eta_{k})_{k=1}^{\infty}$,
$(P_{k})_{k=1}^{\infty}$, $(f_{k})_{k=1}^{\infty}$ such that the following
seven conditions hold for each $k\in{\mathbb{N}}$.

(3.11) $\eta_{1}=1\ \ \text{and}\ \ 0<\eta_{k}<\frac{\eta_{k-1}}{2},\ \ k\geq
2.$ (3.12) $\emptyset\neq P_{k}\subset(0,1)\ \ \text{is a finite union of
nondegenerate compact intervals}.$ (3.13) $\nu(P_{k})\leq\frac{1}{k},\
P_{k}\subset P_{k-1}\ \ \text{and}\ \ R(P_{k-1})\subset R(P_{k})\ \ \text{if}\
\ k\geq 2.$ (3.14) $\text{Each}\ \ I\in\cal C(P_{k-1})\ \ \text{contains at
least two elements of}\ \ \cal C(P_{k})\ \ \text{if}\ \ k\geq 2.$ (3.15)
$f_{k}\in C^{1}[0,1]\ \ \text{and}\ \ f^{\prime}_{k}\ \ \text{has infinite
variation on each interval}\ \ [\alpha,\beta]\subset[0,1].$ (3.16)
$f_{k}(0)=0\ \ \text{and}\ \ \|f_{1}^{\prime}\|\leq\frac{1}{2}.$ (3.17)
$\|f_{k}-f_{k-1}\|<\frac{\eta_{k}}{2}\ \ \text{and}\ \
\|f^{\prime}_{k}-f^{\prime}_{k-1}\|=2^{-k}\ \ \text{if}\ \ k\geq 2.$

Moreover, for each $k\in{\mathbb{N}}$ and and each point $d$ from the set
$R^{*}_{k}$, where

(3.18) $R^{*}_{1}:=R(P_{1})\ \ \text{and}\ \ R^{*}_{k}:=R(P_{k})\setminus
R(P_{k-1})\ \ \text{for}\ \ k\geq 2,$

we will define an interval $[u_{d},v_{d}]$ such that the following two
conditions hold:

(3.19) $0<u_{d}<v_{d}<d,\ \ [u_{d},d]\subset P_{k}\ \ \ \text{and}\ \ \
3\eta_{k+1}<d-v_{d}.$ (3.20) $\text{If}\ k<l,\ \text{then}\ \ \ \ \
T_{f_{l},(u_{d},v_{d})\cap\operatorname{int}P_{l}}\supset
B((d,f_{k}(d)),\eta_{k+1}).$

In the formulation of (3.19) and (3.20) we have used that
$R_{1}^{*},R_{2}^{*},\dots$ are pairwise disjoint by (3.13) and so $k$ is
uniquely determined by $d$.

In our inductive construction we will have defined, after the $n$ th step
($n\in{\mathbb{N}}$) of the construction, the numbers
$\eta_{1},\dots,\eta_{n}$, the sets $P_{1},\dots,P_{n}$, the functions
$f_{1},\dots,f_{n}$ and, if $n\geq 2$, for each $1\leq k\leq n-1$ and $d\in
R_{k}^{*}$ (see (3.18)), we will have defined an interval $[u_{d},v_{d}]$,
such that

(3.21) $\text{seven conditions}\ \eqref{eta}-\eqref{fkvl}\ \ \text{hold
whenever}\ \ 1\leq k\leq n,$ (3.22) $\text{conditions}\ \eqref{uvpr}\
\text{and}\ \eqref{uvdr}\ \ \text{hold whenever}\ \ 1\leq k\leq n-1,\ d\in
R^{*}_{k}\ \text{and}\ l\leq n$

and

(3.23) $\text{for any point}\ d\in R^{*}_{n}\ \text{there exists}\ 0<e<d\\\
\text{such that}\ [e,d]\subset P_{n},\ e\in\operatorname{int}P_{n}\
\text{and}\ (d,f_{n}(d))\in T_{f_{n},e}.$

The first step.

We set $\eta_{1}:=1$. Choose (using e.g. [1, Corollary 22, p. 143]) a nowhere
differentiable function $g\in C[0,1]$ with $\|g\|\leq 1/2$ and set
$f_{1}(x):=\int_{0}^{x}g,\ x\in[0,1]$. Then $f^{\prime}_{1}=g$ has infinite
variation on each interval $[\alpha,\beta]\subset[0,1]$. Using Lemma 2.3 with
$f:=f_{1}$, $\alpha:=0$ and $\beta:=1$, we can choose $0<e<w<1$ such that
$(w,f_{1}(w))\in T_{f_{1},e}$ and set $P_{1}:=[e/2,w]$. It is easy to check
that conditions (3.21), (3.22) and (3.23) hold for $n=1$.

The inductive step.

We suppose that $m\geq 2$ and the $(m-1)$ th step of the construction was
accomplished. In particular, we know that conditions (3.21), (3.22) and (3.23)
hold for $n=m-1$.

Our aim is to construct $\eta_{m}$, $P_{m}$, $f_{m}$ and an interval
$[u_{d},v_{d}]$ for each $d\in R_{m-1}^{*}$ such that (3.21), (3.22) and
(3.23) hold for $n=m$.

First we choose, by the validity of (3.23) for $n=m-1$, for each $d\in
R^{*}_{m-1}$ a point $e=:z_{d}$ such that

(3.24) $0<z_{d}<d,\ [z_{d},d]\subset P_{m-1},\
z_{d}\in\operatorname{int}P_{m-1}\ \ \text{and}\ \ (d,f_{m-1}(d))\in
T_{f_{m-1},z_{d}}$

and set

$Z^{m}_{1}:=\\{z_{d}:\ d\in R^{*}_{m-1}\\}.$

Further choose $\delta_{m}>0$ so small, that

(3.25) $\delta_{m}<\frac{d-z_{d}}{3}\ \ \text{for each}\ \ d\in R_{m-1}^{*}\
\text{and}\ \delta_{m}<\min\left(\frac{1}{2m},\eta_{m-1}\right).$

Now we set $Z^{m}_{2}:=\emptyset$ if $m=2$ and, if $m\geq 3$, we define
$Z^{m}_{2}$ as follows. In this case $R^{*}_{k}\neq\emptyset$ for each $1\leq
k\leq m-2$ (see (3.21) and (3.14)) and for such $k$ and $d\in R^{*}_{k}$ we
have defined an interval $(u_{d},v_{d})$ such that, by the validity (3.22) for
$n=m-1$, (3.19) holds and

(3.26) $T_{f_{m-1},(u_{d},v_{d})\cap\operatorname{int}P_{m-1}}\supset
B((d,f_{k}(d)),\eta_{k+1}).$

Choose $\eta_{m}>0$ so small that

(3.27) $6\eta_{m}<2^{-m}\delta_{m},\ \ \eta_{m}<\frac{\eta_{m-1}}{2}\ \
\text{and}\ \ $ (3.28) $6\eta_{m}<2^{-m}\frac{d-v_{d}}{3},\ \ \text{whenever}\
\ 1\leq k\leq m-2\ \ \text{and}\ \ d\in R^{*}_{k}.$

Further, for every fixed $1\leq k\leq m-2$ and $d\in R^{*}_{k}$, we choose a
finite $\eta_{m}$-net $Q_{d}$ of the ball $B((d,f_{k}(d)),\eta_{k+1})$ and for
each $q\in Q_{d}$ choose by (3.26) a point
$z_{q,d}\in(u_{d},v_{d})\cap\operatorname{int}P_{m-1}$ such that $q\in
T_{f_{m-1},z_{q,d}}$. Now we define $Z^{m}_{2}:=\\{z_{q,d}:\ 1\leq k\leq m-2,\
d\in R^{*}_{k},\ q\in Q_{d}\\}.$

(Note that, as above, $k$ is uniquely determined by $d$; however our
construction alows cases when $(q_{1},d_{1})\neq(q_{2},d_{2})$ and
$z_{q_{1},d_{1}}=z_{q_{2},d_{2}}$.)

Further choose $Z^{m}_{3}$ as an arbitrary finite set
$Z^{m}_{3}\subset\operatorname{int}P_{m-1}$ such that

(3.29) $Z^{m}_{3}\cap\operatorname{int}I\neq\emptyset\ \ \text{for each}\ \
I\in\cal C(P_{m-1})$

and set $Z^{m}:=Z^{m}_{1}\cup Z^{m}_{2}\cup Z^{m}_{3}$.

Choose $0<\delta_{m}^{*}<\delta_{m}$ so small that

(3.30) $[z_{q,d}-\delta_{m}^{*},z_{q,d}+\delta_{m}^{*}]\subset(u_{d},v_{d})\ \
\text{whenever}\ \ 1\leq k\leq m-2,\ d\in R^{*}_{k}\ \ \text{and}\ \ q\in
Q_{d},$ (3.31) $\text{the intervals}\ \\{[z-\delta_{m}^{*},z+\delta_{m}^{*}]:\
z\in Z^{m}\\}\ \text{ are pairwise disjoint subsets of}\
\operatorname{int}P_{m-1},$ (3.32) $\lambda\left(\bigcup_{z\in
Z^{m}}[z-\delta_{m}^{*},z+\delta_{m}^{*}]\right)<\frac{\eta_{m}}{2},\ \
\text{and}$ (3.33)
$\operatorname{osc}(f^{\prime}_{m-1},[z-\delta_{m}^{*},z+\delta_{m}^{*}])\leq\eta_{m}\
\ \text{for each}\ \ z\in Z^{m}.$

Further choose a piecewise linear function $h_{m}\in C[0,1]$ such that

(3.34) $\|h_{m}\|=2^{-m},\ \ \operatorname{supp}h_{m}\subset\bigcup_{z\in
Z^{m}}[z-\delta_{m}^{*},z+\delta_{m}^{*}]\ \ \text{ and}$ (3.35) $\text{for
every}\ z\in Z^{m}\ \text{ there exist}\
z-\delta_{m}^{*}<s_{1}^{z}<s_{2}^{z}<z\\\ \text{with}\ \
h_{m}(s_{1}^{z})=-2^{-m},\ h_{m}(s_{2}^{z})=2^{-m}.$

Now we define $f_{m}$ by

(3.36) $f_{m}(x)=f_{m-1}(x)+\int_{0}^{x}h_{m},\ \ x\in[0,1].$

Then clearly $f_{m}\in C^{1}[0,1]$ and, using (3.15) for $k=m-1$, it is easy
to see that $f^{\prime}_{m}\textasciiacute=f^{\prime}_{m-1}+h_{m}$ has
infinite variation on each interval $[\alpha,\beta]\subset[0,1]$.

So by Lemma 2.3 we can find for each $z\in Z^{m}$ points
$z<e_{z}<w_{z}<z+\delta_{m}^{*}$ such that

(3.37) $(w_{z},f_{m}(w_{z}))\in T_{f_{m},e_{z}}.$

For each $d\in R^{*}_{m-1}$, set

(3.38) $u_{d}:=z_{d}-\delta_{m}^{*},\ \ v_{d}:=w_{z_{d}}.$

To define $P_{m}$, assign to each $d\in R(P_{m-1})$ a point $c_{d}<d$ such
that $c_{d}\in\operatorname{int}P_{m-1}$, $[c_{d},d]\subset P_{m-1}$,
$d-c_{d}<1/m$ and $[c_{d},d]\cap\bigcup_{z\in
Z^{m}}[z-\delta_{m}^{*},z+\delta_{m}^{*}]=\emptyset$, and define

(3.39) $P_{m}:=\bigcup_{z\in Z^{m}}[z-\delta_{m}^{*},w_{z}]\cup\bigcup_{d\in
R(P_{m-1})}[c_{d},d].$

Thus we have constructed $\eta_{m}$, $f_{m}$, $P_{m}$, and an interval
$[u_{d},v_{d}]$ for each $d\in R^{*}_{m-1}$.

Our aim is now to prove that properties (3.21), (3.22) and (3.23) hold for
$n=m$.

First note that, by the above construction,

(3.40) $\eqref{defpm}\ \text{gives the decomposition of}\ P_{m}\ \text{into
its components}.$

So, using (3.25), $\delta_{m}^{*}<\delta_{m}$ and $d-c_{d}<1/m$ ($d\in
R(P_{m-1})$), we obtain

(3.41) $\nu(P_{m})\leq 1/m.$

To prove that (3.21) holds for $n=m$, it is sufficient (since we know that
(3.21) holds for $n=m-1$) to verify that conditions (3.11)-(3.17) hold for
$k=m$. These facts easily follow from the construction:

Conditions (3.11) and (3.12) follow from (3.27) and (3.39), respectively.
Condition (3.13) follows from (3.41), (3.40) and (3.31). Condition (3.14)
follows from (3.40) and (3.29). Condition (3.15) is stated just after (3.36).
Condition (3.16) follows from (3.36) and the validity of (3.16) for $k=m-1$.

To prove (3.17), observe that by (3.36) and (3.34) we have
$\|f^{\prime}_{m}-f^{\prime}_{m-1}\|=\|h_{m}\|=2^{-m}$ and, using also (3.34)
and (3.32), we obtain

$|(f_{m}-f_{m-1})(x)|=\left|\int_{0}^{x}h_{m}\right|\leq\left|\int_{\operatorname{supp}h_{m}}|h_{m}|\right|<\frac{\eta_{m}}{2},\
\ \ x\in[0,1],$

and so $\|f_{m}-f_{m-1}\|<\eta_{m}/2$.

Now we will show that (3.22) holds for $n=m$. Since we know that (3.22) holds
for $n=m-1$, it is sufficient to verify that

(3.42) $\eqref{uvpr}\ \text{holds if}\ k=m-1\ \text{and}\ d\in R_{k}^{*}$

and

(3.43) $\eqref{uvdr}\ \ \text{holds if}\ \ 1\leq k\leq m-1,\ \ l=m\ \
\text{and}\ \ d\in R_{k}^{*}.$

To prove (3.42), consider an arbitrary $d\in R_{m-1}^{*}$ and recall that
$z_{d}\in Z^{m}_{1}\subset Z^{m}$ and $u_{d}=z_{d}-\delta_{m}^{*}$,
$v_{d}=w_{z_{d}}$ (see (3.38). By (3.24) we have $[z_{d},d]\subset P_{m-1}$
and so (3.31) and $z_{d}<w_{z_{d}}<z_{d}+\delta_{m}^{*}$ imply
$0<u_{d}<v_{d}<d$ and $[u_{d},d]\subset P_{m-1}$. To prove
$3\eta_{m}<d-v_{d}$, observe that (3.25) gives $d-z_{d}>3\delta_{m}$ and so,
using also $\delta_{m}^{*}<\delta_{m}$ and (3.27), we obtain

$d-v_{d}>d-z_{d}-\delta_{m}^{*}>3\delta_{m}-\delta_{m}>3\eta_{m}.$

So (3.42) is proved.

To prove (3.43), we will distinguish cases a) $k=m-1$ and b) $1\leq k<m-1$.

a) Consider an arbitrary $d\in R_{m-1}^{*}$. Then $z_{d}\in Z^{m}_{1}$ and
$u_{d}=z_{d}-\delta_{m}^{*}$, $v_{d}=w_{z_{d}}$. By (3.24) we have

(3.44) $(d,f_{m-1}(d))\in T_{f_{m-1},z_{d}}.$

Now we will show that the assumptions of Lemma 3.2 are satisfied for

$G=f_{m-1},\ \tilde{G}=f_{m},\ u=u_{d},\ z=z_{d},\ v=v_{d},\ x=d,\
y=f_{m-1}(d),\ \varepsilon=2^{-m},\ \delta=\delta_{m},\ \eta=\eta_{m}.$

First we show that inequalities (3.4) hold:

Using (3.27) and (3.25) we obtain

$v_{d}+\delta_{m}+\eta_{m}<(z_{d}+\delta_{m}^{*})+\delta_{m}+\frac{\delta_{m}}{6}<z_{d}+3\delta_{m}<d.$

Further we obtain $v_{d}-u_{d}<2\delta_{m}^{*}<\eta_{m}$ by (3.32) and
$6\eta_{m}<2^{-m}\delta_{m}$ by (3.27).

Condition (3.5) coincides with (3.44) and (3.6) holds since we know that
(3.17) is valid for $k=m$. Condition (3.7) follows from (3.33) and the
validity of (3.16) and (3.17) for each $k\leq m-1$. Finally, condition (3.8)
follows from (3.35) since $\tilde{g}-g=h_{m}$.

Thus conclusion (3.9) of Lemma 3.2 holds, i.e.
$B((d,f_{m-1}(d)),\eta_{m})\subset T_{f_{m},(u_{d},v_{d})}$. Since
$(u_{d},v_{d})\subset\operatorname{int}P_{m}$ by (3.38) and (3.39), we obtain
that (3.20) holds for $k=m-1$, $l=m$ and our $d$.

b) Consider arbitrary $1\leq k<m-1$ and $d\in R_{k}^{*}$. Then we have defined
a finite $\eta_{m}$-net $Q_{d}$ of the ball $B((d,f_{k}(d)),\eta_{k+1})$ and
for each $q\in Q_{d}$ we have defined a point
$z_{q,d}\in(u_{d},v_{d})\cap\operatorname{int}P_{m-1}$ such that $q\in
T_{f_{m-1},z_{q,d}}$.

Now we will show that, for an arbitrary $q=:(x_{q},y_{q})\in Q_{d}$, the
assumptions of Lemma 3.2 are satisfied for

$G=f_{m-1},\ \tilde{G}=f_{m},\ u=z_{q,d}-\delta_{m}^{*},\ z=z_{q,d},\
v=w_{z_{q,d}},\\\ x=x_{q},\ y=y_{q},\ \varepsilon=2^{-m},\
\delta=\frac{d-v_{d}}{3},\eta=\eta_{m}.$

First we show that inequalities (3.4) hold:

Using (3.30), (3.28) and (3.19) we obtain

$v+\delta+\eta=w_{z_{q,d}}+\frac{d-v_{d}}{3}+\eta_{m}<v_{d}+\frac{d-v_{d}}{3}+\frac{d-v_{d}}{3}\\\
=d-\frac{d-v_{d}}{3}<d-\eta_{k+1}<x_{q}=x.$

Further we obtain the inequalities
$v-u=w_{z_{q,d}}-(z_{q,d}-\delta_{m}^{*})<2\delta_{m}^{*}<\eta_{m}=\eta$ by
(3.32) and $6\eta=6\eta_{m}<2^{-m}\frac{d-v_{d}}{3}=\varepsilon\delta$ by
(3.28).

Condition (3.5) holds since $q\in T_{f_{m-1},z_{q,d}}$ and (3.6) holds since
we know that (3.17) is valid for $k=m$. Condition (3.7) follows from (3.33)
and the validity of (3.16) and (3.17) for each $k\leq m-1$. Finally, condition
(3.8) follows from (3.35) since $\tilde{g}-g=h_{m}$.

Thus assertion (3.9) of Lemma 3.2 holds, i.e. $B(q,\eta_{m})\subset
T_{f_{m},(z_{q,d}-\delta_{m}^{*},w_{z_{q,d}})}$. Note that $z_{q,d}\in
Z_{2}^{m}\subset Z^{m}$ and so
$(z_{q,d}-\delta_{m}^{*},w_{z_{q,d}})\subset(u_{d},v_{d})\cap\operatorname{int}P_{m}$
by (3.30) and (3.39).

Since $Q_{d}$ is a $\eta_{m}$-net of $B((d,f_{k}(d)),\eta_{k+1})$ we obtain
that (3.20) holds for $l=m$ and our $k$ and $d$.

So we have proved (3.43). It remains to prove that (3.23) holds for $n=m$. So
consider an arbitrary $d\in R_{m}^{*}$. By (3.40) we obtain that there exists
$z_{d}\in Z^{m}$ such that $d=w_{z_{d}}$ and (3.37) shows that (3.23) holds
for $n=m$ (since the choice $e:=e_{z_{d}}$ works for our $d$).

So we have finished our inductive construction. It is easy to see that we have
defined the sequences $(\eta_{k})_{k=1}^{\infty}$, $(P_{k})_{k=1}^{\infty}$,
$(f_{k})_{k=1}^{\infty}$ and intervals $[u_{d},v_{d}]$ ($d\in R^{*}_{k}$,
$k=1,\dots$) such that all nine properties (3.11) - (3.20) hold for each
$k\in{\mathbb{N}}$.

Using these properties only, we will show that $f:=\lim_{n\to\infty}f_{n}$,
$P:=\bigcap_{n=1}^{\infty}P_{n}$ and
$D:=\bigcup_{k=1}^{\infty}R_{k}^{*}=\bigcup_{k=1}^{\infty}R(P_{k})$ satisfy
the assumptions of Lemma 3.1.

By (3.17) we obtain that $\|f_{m}^{\prime}-f_{l}^{\prime}\|\leq 2^{-l}$
whenever $1\leq l<m$ and therefore the sequence $(f_{k}^{\prime})$ uniformly
converges to a function $\varphi\in C[0,1]$. Since
$f_{k}(x)=\int_{0}^{x}f_{k}^{\prime},\ x\in[0,1],$ by (3.16), we obtain
$f_{k}\rightrightarrows f$, where $f(x):=\int_{0}^{x}\varphi,\ x\in[0,1].$
Clearly $f\in C^{1}[0,1]$ and $f^{\prime}_{k}\rightrightarrows
f^{\prime}=\varphi$.

By (3.12) and (3.13), $P=\bigcap_{n=1}^{\infty}P_{n}$ is a nonempty closed set
and (3.13) with (3.14) easily imply that $P$ is perfect and nowhere dense.

By (3.13) we easily obtain that the countable set $D\subset P$ is dense in
$P$.

Now consider an arbitrary $d\in D$. Then there exists $k\in{\mathbb{N}}$ such
that $d\in R_{k}^{*}$ and so we have defined $u_{d},v_{d}\in(0,1)$ such that
$u_{d}<v_{d}<d$ and (3.19) and (3.20) hold. Now consider an arbitrary point
$(x,y)\in B((d,f_{k}(d)),\eta_{k+1})$. By (3.20) we can choose, for each
$l>k$, a point $p_{l}\in[u_{d},v_{d}]\cap P_{l}$ such that $(x,y)\in
T_{f_{l},p_{l}}$. Choose a convergent subsequence $(p_{l_{i}})_{i=1}^{\infty}$
of $(p_{l})_{l=k+1}^{\infty}$ with $p_{l_{i}}\to p$. Then $p\in
P\cap[u_{d},v_{d}]$ and Lemma 2.2 gives $(x,y)\in T_{f,p}$. Thus we have
proved that

(3.45) $B((d,f_{k}(d)),\eta_{k+1})\subset T_{f,P\cap[u_{d},v_{d}]}.$

Using (3.17) and (3.11), we obtain

$|f(d)-f_{k}(d)|\leq\|f_{k+1}-f_{k}\|+\|f_{k+2}-f_{k+1}\|+\dots{\\\
}<\eta_{k+1}/2+\eta_{k+2}/2+\eta_{k+3}/2+\dots\leq(1/2)(\eta_{k+1}+\eta_{k+1}/2+\eta_{k+1}/4+\dots)=\eta_{k+1}.$

So (3.45) gives

$(d,f(d))\in
B((d,f_{k}(d)),\eta_{k+1})\subset\operatorname{int}T_{f,P\cap[u_{d},v_{d}]}$

and (3.1) is proved.

Finally, condition (3.2) holds since each $R_{k}^{*}$ is finite and
$d-u_{d}<1/k$ for $d\in R_{k}^{*}$ by (3.13) and (3.19).

So the assertion of our theorem holds for $M:=\operatorname{graph}f|_{P}$ by
Lemma 3.1. ∎

##  4\. Slobodnik’s necessary condition is not sufficient

As an easy consequence of Theorem 3.4, we will prove the following result
which shows that Slobodnik’s necessary condition (for sets from $\cal
D_{l}^{n}$) is not suficient.

######  Proposition 4.1.

There exists a set $M\subset{\mathbb{R}}^{2}$ such that
$M=\bigcup_{k=1}^{\infty}B_{k}$, where $B_{k}$ have properties (i), (ii) and
(iii) from Theorem 1.2 for $n=2$, but $M\notin\cal D_{l}^{2}$.

###### Proof.

Let $M$ and $f$ be as in Theorem 3.4. So we have $M\notin\cal D_{l}^{2}$ and
we have $M=\\{(x,f(x)):\ x\in P\\}$ where $P\subset[0,1]$ is nowhere dense.
Set $B_{k}:=M,\ k\in{\mathbb{N}}$; we will show that then properties (i),
(ii), (iii) hold.

The property (i) is almost obvious, since we can extend $f$ to a Lipschitz
function $f^{*}$ on ${\mathbb{R}}$ and thus $M$ is a compact subset of
$\operatorname{graph}f^{*}$ which is a Lipschitz hypersurface in
${\mathbb{R}}^{2}$.

To prove (ii), consider a hyperplane $H$ in ${\mathbb{R}}^{2}$. Then $H$ is a
line and we can suppose that it contains the origin. Then the projection onto
$H$ is a linear mapping and so it is clearly sufficient to prove that, for
each $a,b\in{\mathbb{R}}$, $Z:=\\{ax+bf(x):\ x\in P\\}$ is nowhere dense in
${\mathbb{R}}$. Since $Z=g(P)$, where $g(x):=ax+f(x),\ x\in[0,1],$ is
$C^{1}$-smooth and $P$ is nowhere dense, we obtain (see [3, Lemma 4.1]) that
$Z=g(P)$ is nowhere dense.

To prove (iii), consider an arbitrary point
$c=(c_{1},c_{2})\in{\mathbb{R}}^{2}\setminus M$. To prove that the set

$E:=\left\\{\frac{(x,y)-c}{\|(x,y)-c\|}:\ (x,y)\in M\right\\}\\\
=\left\\{\left(\frac{x-c_{1}}{\sqrt{(x-c_{1})^{2}+(f(x)-c_{2})^{2}}},\frac{f(x)-c_{2}}{\sqrt{(x-c_{1})^{2}+(f(x)-c_{2})^{2}}}\right),\
x\in P\right\\}$

is nowhere dense in $S_{{\mathbb{R}}^{2}}$, it is clearly sufficient to show
that (its “projection”)

$F:=\left\\{\frac{x-c_{1}}{\sqrt{(x-c_{1})^{2}+(f(x)-c_{2})^{2}}},\ x\in
P\right\\}$

is nowhere dense in ${\mathbb{R}}$. Set

$h(x):=\frac{x-c_{1}}{\sqrt{(x-c_{1})^{2}+(f(x)-c_{2})^{2}}}\ \ \ \text{ if}\
\ \ (x,f(x))\neq c.$

If $c_{1}\in P$ or $c_{1}\notin[0,1]$, then $h$ is clearly $C^{1}$-smooth on
$[0,1]$ and therefore $F=h(P)$ is nowhere dense by [3, Lemma 4.1].

If $c_{1}\in[0,1]\setminus P$, then $h$ can be undefined for $x=c_{1}$.
However, then there exist points $0<t_{1}<t_{2}<1$ such that
$F=h(P\cap[0,t_{1}])\cup h(P\cap[t_{2},1])$ and $h$ is $C^{1}$-smooth on
$[0,t_{1}]$ (resp. $[t_{2},1]$) whenever $P\cap[0,t_{1}]\neq\emptyset$ (resp.
$P\cap[t_{2},1]\neq\emptyset$). So [3, Lemma 4.1] gives again that $F$ is
nowhere dense. ∎

######  Remark 4.2.

In the above proposition, we can state that sets $B_{k}$ satisfy the following
condition (more general than (iii)):

(iii)* For each $c\in{\mathbb{R}}^{2}$, the set $\\{\frac{x-c}{\|x-c\|}:\ x\in
B_{k}\setminus\\{c\\}\\}$ is nowhere dense in the unite sphere
$S_{{\mathbb{R}}^{2}}$.

The proof is only a slight refinement of the proof of (iii).

##  5\. An analogon of Slobodnik’s necessary condition in separabůe Banach
spaces

In this section we will prove the following analogon of Slobodnik’s Theorem
1.2.

######  Proposition 5.1.

Let $X$ be a separable Banach space ($\dim X\geq 2$) and let
$f:X\to{\mathbb{R}}$ be a linearly continuous function having the Baire
property. Then the set $D(f)$ of all discontinuity points of $f$ can be
written as $D(f)=\bigcup_{k=1}^{\infty}B_{k}$ where each $B_{k}$ has the
following properties.

  1. (i)

$B_{k}$ is a bounded closed subset of a Lipschitz hypersurface $L_{k}\subset
X$ which is nowhere dense in $L_{k}$.

  2. (ii)

Any linear projection of $B_{k}$ onto any hyperplane $0\in H\subset X$ is a
first category subset of $H$.

  3. (iii)

For each $c\in X\setminus B_{k}$, the set $\\{\frac{x-c}{\|x-c\|}:\ x\in
B_{k}\\}$ is a first category set in $S_{X}$.

This result improves [13, Corollary 4.2] which only asserts that $D(f)$ can be
covered by countably many Lipschitz hypersurfaces (and implies that $D(f)$ is
a null subset of $X$ in any usual sense).

We infer Proposition 5.1 easily from [13, Corollary 4.2], the Banakh-
Maslyuchenko characterization (Theorem 2.5) and simple Lemma 5.2 below.

Although our Proposition 5.1 is not a direct generalization of Slobodnik’s
Theorem 1.2, it easily implies Slobodnik’s result. Indeed, if
$X={\mathbb{R}}^{n}$, then each linearly continuous $f$ has the Baire property
by (1.1) and all $B_{k}$ and their projections (in (ii) and (iii)) are
compact. So it is sufficient to use the fact that each closed first category
subset of a complete metric space is nowhere dense.

######  Lemma 5.2.

Let $X$ be a separable Banach space with $\dim X\geq 2$, $v\in S_{X}$ and let
$Y$ be a topological complement of $V:=\operatorname{span}\\{v\\}$. Let
$A\subset X$ be an $l$-miserable set. Then

  1. (i)

the projection $\pi_{Y}(A)$ of $A$ onto $Y$ in the direction of $V$ is of the
first category in $Y$, and

  2. (ii)

for each $c\in X\setminus A$, the set $\\{\frac{x-c}{\|x-c\|}:\ x\in A\\}$ is
of the first category in $S_{X}$.

###### Proof.

Choose a closed $l$-neighbourhood $L$ of $A$ such that
$A\subset\overline{X\setminus L}$. The proofs of (i) and (ii) are quite
analogous.

(i) For each $n\in{\mathbb{N}}$, set $A_{n}:=\\{x\in A:\ \\{x+tv:\
t\in[-1/n,1/n]\\}\subset L\\}$. Since $L$ is an $l$-neighbourhood of $A$, we
have $A=\bigcup_{n\in{\mathbb{N}}}A_{n}$. Now choose, for each
$n\in{\mathbb{N}}$, a covering of $V$ by open sets $V_{n,1},V_{n,2},...$ such
that each $V_{n,k}\subset V$ is an open subset of $V$ with
$\operatorname{diam}(V_{n,k})<1/n$. Denote by $\pi_{V}$ the projection of $X$
onto $V$ in the direction of $Y$ and set
$A_{n,k}:=A_{n}\cap(\pi_{V})^{-1}(V_{n,k}),\ n,k\in{\mathbb{N}}$. Using the
definitions of sets $A_{n}$ and $V_{n,k}$, it is easy to see that

(5.1) $(\pi_{Y})^{-1}(\pi_{Y}(x))\cap(\pi_{V})^{-1}(V_{n,k})\subset L\ \
\text{whenever}\ \ n,k\in{\mathbb{N}},\ x\in A_{n,k}.$

Since $A=\bigcup_{n,k\in{\mathbb{N}}}A_{n,k}$, it is sufficient to prove that
each set $\pi_{Y}(A_{n,k})$ is nowhere dense in the space $Y$. So suppose, to
the contrary, that there exist $n$, $k$ and a nonempty set $G\subset Y$ which
is open in $Y$ and $\pi_{Y}(A_{n,k})\cap G$ is dense in $G$. Using (5.1) and
the closedness of $L$, we obtain
$(\pi_{Y})^{-1}(G)\cap(\pi_{V})^{-1}(V_{n,k})\subset L$. Since
$(\pi_{Y})^{-1}(G)\cap(\pi_{V})^{-1}(V_{n,k})$ is open and contains a point
$a\in A_{n,k}\subset A$, we obtain $a\notin\overline{X\setminus L}$ which
contradicts to $A\subset\overline{X\setminus L}$.

(ii) Fix a point $c\in X\setminus A$ and define the “projection”
$\pi_{S}:X\setminus\\{c\\}\to S_{X}$ by $\pi_{S}(x):=\frac{x-c}{\|x-c\|}$,
$x\in X\setminus\\{c\\}$. For each $n\in{\mathbb{N}}$, denote $A_{n}:=\\{x\in
A:\ \\{x+t\pi_{S}(x):\ t\in[-1/n,1/n]\\}\subset L\\}$. Since $L$ is an
$l$-neighbourhood of $A$, we have $A=\bigcup_{n\in{\mathbb{N}}}A_{n}$. Now
choose, for each $n\in{\mathbb{N}}$, a covering of $(0,\infty)$ by open
subsets $H_{n,1},H_{n,2},...$ with $\operatorname{diam}(H_{n,k})<1/n$. Set
$A_{n,k}:=A_{n}\cap\\{x\in X:\|x-c\|\in H_{n,k}\\},\ n,k\in{\mathbb{N}}$.
Using the definitions of sets $A_{n}$ and $H_{n,k}$, it is easy to see that

(5.2) $(\pi_{S})^{-1}(\pi_{S}(x))\cap\\{x\in X:\|x-c\|\in H_{n,k}\\}\subset L\
\ \text{whenever}\ \ n,k\in{\mathbb{N}},\ x\in A_{n,k}.$

Since $A=\bigcup_{n,k\in{\mathbb{N}}}A_{n,k}$, it is sufficient to prove that
each set $\pi_{S}(A_{n,k})$ is nowhere dense in the sphere $S$. So suppose, to
the contrary, that there exist $n$, $k$ and a nonempty set $G\subset S$ which
is open in $S$ and $\pi_{S}(A_{n,k})\cap G$ is dense in $G$. Using (5.2) and
the closedness of $L$, we obtain $(\pi_{S})^{-1}(G)\cap\\{x\in X:\|x-c\|\in
H_{n,k}\\}\subset L$. Since $(\pi_{S})^{-1}(G)\cap\\{x\in X:\|x-c\|\in
H_{n,k}\\}$ is open and contains a point $a\in A_{n,k}\subset A$, we obtain
$a\notin\overline{X\setminus L}$ which contradicts to
$A\subset\overline{X\setminus L}$. ∎

Proof of Proposition 5.1.

By Theorem 2.5 there exist closed $l$-miserable sets $F_{m}\subset X$,
$m\in{\mathbb{N}}$, such that $D(f)=\bigcup_{m\in{\mathbb{N}}}F_{m}$. By [13,
Corollary 4.2] there exist Lipschitz hypersurfaces $M_{n}$,
$n\in{\mathbb{N}}$, such that $D(f)\subset\bigcup_{n\in{\mathbb{N}}}M_{n}$.
Set

$Z_{m,n,p}:=F_{m}\cap M_{n}\cap\\{x\in X:\ \|x\|\leq p\\},\ \ \
m,n,p\in{\mathbb{N}},$

and let $(B_{k})_{k=1}^{\infty}$ be a sequence of all elements of the set
$\\{Z_{m,n,p}:\ m,n,p\in{\mathbb{N}}\\}$. Now consider an arbitrary
$k\in{\mathbb{N}}$. Obviously, $B_{k}$ is closed and bounded. It is also
$l$-miserable since it is a subset of an $l$-miserable set $F_{m}$ and so we
obtain by Lemma 5.2 that conditions (ii) and (iii) hold. Further $B_{k}$ is
contained in some Lipschitz hypersurface $M_{n}$. Let $V$ and $Y$ be linear
spaces corresponding to $M_{n}$ as in Definition 2.1 and denote by $\pi_{Y}$
the projection onto $Y$ in the direction of $V$. Since
$\pi_{Y}|_{M_{n}}:M_{n}\to Y$ is clearly a homeomorphism, we obtain that
$\pi_{Y}(B_{k})$ is a closed subset of the complete space $Y$ and so it is
nowhere dense in $Y$, because it is a first category set in $Y$ by condition
(ii). Consequently $B_{k}$ is nowhere dense in $M_{n}$ and thus condition (i)
holds (with $L_{k}:=M_{n}$).

## References

  * [1] A.M. Bruckner, Differentiation of real functions, 2nd ed., CRM Monograph Series, vol. 5, American Mathematical Society, Providence, RI, 1994.
  * [2] T. Banakh, O. Maslyuchenko, Linearly continuous functions and F-sigma-measurability, Eur. J. Math. 6 (2020), 37–52.
  * [3] K.Ch. Ciesielski, T. Glatzer, Sets of discontinuities of linearly continuous functions, Real Anal. Exchange 38 (2012/13), 377–389.
  * [4] K.Ch. Ciesielski, T. Glatzer, Sets of discontinuities for functions continuous on flats, Real Anal. Exchange 39 (2013/14), 117–138.
  * [5] K.C. Ciesielski, D. Miller, A continuous tale on continuous and separately continuous functions, Real Anal. Exchange 41 (2016), 19–54.
  * [6] J. Dugundji, Topology, Allyn and Bacon, Inc., Boston, Mass., 1966.
  * [7] R. Kershner, The continuity of functions of many variables, Trans. Amer. Math. Soc. 53 (1943), 83–100.
  * [8] K. Kuratowski, Topology, vol. I, Academic Press, New York, 1966.
  * [9] H. Lebesgue, Sur les fonctions représentable analytiquement, J. Math. Pure Appl. (6), 1 (1905), 139–212.
  * [10] E. E. Shnol, Functions of two variables continuous along straight lines, Mat. Zametki, 62 (1997), 306–311; translation in: Math. Notes 62 (1997), 255–259.
  * [11] S.G. Slobodnik, Expanding system of linearly closed sets, Mat. Zametki 19 (1976), 67–84; translation in Math. Notes 19 (1976), 39–48.
  * [12] W.H. Young, G.C. Young, Discontinuous functions continuous with respect to every straight line, Quart. J. Math. 41 (1910), 87–93.
  * [13] L. Zajíček,  A remark on functions continuous on all lines, Comment. Math. Univ. Carolin. 60 (2019), 211–218.