Introduction

Multiple clinical procedures require the correct orientation of bone fragments and implants to minimize intra- and postoperative complications. During joint replacement surgeries, flexion and extension gaps can change significantly after performing bone cuts or releasing soft tissue. Hence, the success of unicompartmental knee arthroplasty (UKA) depends on the prosthesis component alignment, and a tibial misalignment correlates with loosening risk, especially for varus angles larger than 5\(^\circ \) [1]. Likewise, successful total knee arthroplasty (TKA) greatly depends on the accurate implant position, and deviations as small as 3\(^\circ \) are associated with poor functional outcomes [2] and can lead to early loosening of the prosthesis [3,4,5]. Regarding total hip arthroplasty (THA), inaccurate placement of the acetabular cup often occurs when its orientation is based only on the surgeon’s visual assessment, causing early prosthesis failure due to decreased range of movement, impingement, or recurrent dislocation [6]. Similarly, orthognathic surgery requires repositioning the maxillomandibular complex (MMC) [7], and any deviation compromises the facial appearance and might influence chewing, speech, and respiration [8].

While intraoperative X-ray imaging usually provides only 2D images, surgical image-based navigation can be more practical. It is used routinely in orthopedic oncology for performing margin-safe osteotomies and allograft insertions [9]. However, when applied to femoral osteotomy, pose deviations within 10\(^\circ \) and 4 mm have been reported [10], stating the necessity of improved computer-assisted surgery (CAS) solutions, involving the tracking of the osteotomized fragments.

Image-less navigation, on the other hand, is used in TKA to guide osteotomies to match the implant interface and achieve adequate knee balance [2, 4, 5], in hip trauma surgery [11], and in THA for correct bone and prosthesis alignment [12, 13]. Although it enables precise angle measurements [14], pathological cases with significant variability in the anatomy of the distal femur can lead to flexion angles greater than 5\(^\circ \) [15]; even obesity can affect the inclination orientation precision during hip surgery [16]. Furthermore, while the number of TKA procedures is continuously increasing [4], optimal femoral component rotation is achieved in only about 75% of the cases [2]. Thus, CAS solutions are still open to improvement.

Although navigation was successfully applied to track zygomatic fractures [17], dental implants [18], and surgical drills [19], its use in maxillary reconstruction is rare and still far from satisfactory [8, 20]. Orthognathic surgery is associated with temporomandibular joint disorders (TMDs) due to changes in the placement of the condyles. In this regard, Li et al. [21] proposed the placement of one tracker in a skull post and another in the occlusion splint to track the MMC. Although their method does not require intraoperative registration, the CT images must be acquired with the splint and tracker in place. More recently, Chen et al. [22] introduced a navigation system capable of tracking the loosed bone graft and assessed its accuracy by measuring the distances between planning and execution (TRE \(1.03 \pm 0.10\) mm).

Despite being in the developing stage, real-time bone fragment tracking has shown promising results in hip surgery. Pflugi et al. [23] developed a cost-effective solution for periacetabular osteotomy (PAO) surgery using plastic bones. They attached one inertial measurement unit to the pelvis and one to the acetabular fragment and contrasted the measured relative angle between sensors against a custom optical navigation system. However, they only measured angles, no translation, and obtained mean deviations of up to 2.9\(^\circ \). Chen et al. [24] tracked a fragment of the pelvis in a plastic phantom and compared the TRE error between navigated (\(0.75 \pm 0.18\) mm) and non-navigated (\(3.13\pm 1.28\) mm) placements, but did not report the registration error of the implant. Liu et al. [25] presented a system for PAO surgery that tracks the acetabular fragment and gives real-time orientation feedback. They performed navigation in four sawbones models and obtained average inclination and anteversion angles of \(0.9^\circ \pm 0.3^\circ \) and \(0.9^\circ \pm 0.7^\circ \), respectively, concluding that their fragment navigation helps to emulate the virtual plan. More recently, Strazar et al. [26] introduced their electromagnetic navigation system for hip preservation, with a mean accuracy of 1 mm, capable of tracking multiple bone pieces and instruments. Mihalic et al. [27] combined this navigator with patient-specific templates to reorient the acetabular fragment during PAO surgery, concluding that this novel technique is significantly more accurate than the fluoroscope.

Fig. 1
figure 1

Printed two-piece models designed for the experiments, and their corresponding optimal registrations

In this work, we introduce a custom navigation system based on multi-registration that can track dissociated objects relative to a preoperative virtual plan. We derive a mathematical error analysis of the multi-registration method and conduct phantom experiments to measure its accuracy. Moreover, we provide a detailed workflow of the complete process needed to perform a navigation trial and evaluate its feasibility in a real clinical case using plastic bones.

Materials and methods

Navigation system and workflow

The navigation system application was developed based on The Medical Imaging Interaction Toolkit (MITK),Footnote 1 which is an open-source software suitable for surgical navigation [28], and using the Atracsys spyTrack180Footnote 2 infrared camera. Its general workflow is as follows:

  1. 1.

    Preoperative planning: The target virtual plan scenario can be imported from any CAD virtual planning tool, i.e., MITK or 3D Slicer,Footnote 3 using conventional 3D mesh formats.

  2. 2.

    Navigation planning: One mesh is marked as the main surface, which will stay fixed within the preoperative plan that may include any other objects such as osteotomy planes, segmentations, or volume images. On the contrary, the dynamic meshes will freely move and may have control points associated. At least three primary registration points must be selected per tracked entity.

  3. 3.

    System setup: A unique-geometry passive marker is attached and assigned to each tracked entity, and the pointer geometry is adjusted using the pivot calibration method [29].

  4. 4.

    Registration: Each entity is registered separately using paired points and an optional surface refining step that uses the iterative closest point method [30].

  5. 5.

    Navigation: The system displays the main mesh as in the virtual plan, allowing the use of the probe for guidance. Each dissociated dynamic mesh is tracked in real time, displaying its misalignment error (offset and angle) relative to the plan, depicting the estimated localization error using a colormap, and informing the deviation of every control point.

Phantom plates experiment preparation

To verify the accuracy and precision of the system, we carried out a phantom experiment using two plastic parts. We registered the models separately, fused them into a known position (preoperative plan), and measured the reported error. The models were designed to fit into a single structure (Fig. 1) and fabricated using an FDM CreateBot 3D printer (0.1 mm resolution). Each model has a 6x6 grid of 1-mm-diameter cavities for the probe tip.

Fig. 2
figure 2

Phantom experiment error representation showing the real physical models (solid lines) and their virtual representations (dotted)

We loaded the models into a CAD application based on MITK, virtually coupled them, yielding the desired preoperative plan, and assigned one registration point to every cavity. The experiment proceeded as follows:

  1. 1.

    With parts A and B decoupled, perform paired-points registration of model A using \(M_A\) as the reference marker.

  2. 2.

    Repeat for model B, using \(M_B\).

  3. 3.

    Export every acquired point relative to its corresponding marker’s coordinate system.

  4. 4.

    Switch to navigation mode and have model A be the main surface, while model B freely moves in the virtual space.

  5. 5.

    Couple the models together and store the transformation of \(M_B\) relative to \(M_A\), \(M_{nav}^t\).

Alignment error analysis

Figure 2 evidences that aligning the pieces by following the virtual scene leads to an unknown physical error. Instead, we physically couple the parts and measure the difference between virtual models, which yields the same offset and angle absolute values.

Working in world coordinates, we denote \(\varvec{v_A^{t}}\) as any point of the virtual model A, for an arbitrary time t. Premultiplying any of these points by the registration matrix of model A, \(R_A\), we obtain its corresponding point of the real model of A, \(\varvec{r_A^{t}}\). Equations (1) and (2) show the inverse operations, specifically at the static preoperative plan time \(t_0\).

$$\begin{aligned} \varvec{v_A}^{t_0}= & {} {R_A}^{-1} \varvec{r_A}^{t_0} \end{aligned}$$
(1)
$$\begin{aligned} \varvec{v_B}^{t_0}= & {} {R_B}^{-1} \varvec{r_B}^{t_0} \end{aligned}$$
(2)

Since model A is the main surface, all its points remain constant in time, while the real and virtual points of model B are transformed according to (4) and (5), respectively. Combining (2) into (5) yields (6), which represents the transformation from the ideal plan pose of the real model B and its virtual representation.

$$\begin{aligned} \varvec{v_A}^{t}= & {} \varvec{v_A}^{t_0} \end{aligned}$$
(3)
$$\begin{aligned} \varvec{r_B}^{t}= & {} M_{nav}^t \varvec{r_B}^{t_0} \end{aligned}$$
(4)
$$\begin{aligned} \varvec{v_B}^{t}= & {} M_{nav}^t \varvec{v_B}^{t_0} \end{aligned}$$
(5)
$$\begin{aligned} \varvec{v_B}^t= & {} (M_{nav}^t {R_B}^{-1}) \varvec{r_B}^{t_0} \end{aligned}$$
(6)

Premultiplying \(R_A\) to both sides of (1) and making use of (3) align the virtual model A to its physical position. Applying the same transform to (6) leads to (7), aligning the entire scene to the preoperative plan.

$$\begin{aligned} R_A \varvec{v_B}^t= & {} \left( R_A M_{nav}^t {R_B}^{-1} \right) \varvec{r_B}^{t_0} \end{aligned}$$
(7)
$$\begin{aligned} M_{error}^t= & {} R_A M_{nav}^t {R_B}^{-1} \end{aligned}$$
(8)

From (7), it is determined that (8) transforms the desired model B plan position into its actual virtual representation and hence is the error matrix.

Variables extraction

Considering that the alignment error is null when the models are coupled, we seek to measure the system’s reported error for several trials, extract registration variables, and evaluate their relationship with the error. We use all the fiducials to obtain an optimal registration and afterward simulate 360,000 new registrations for clusters from 3 to 8 points to contrast the results against the former. The considered registration variables are the number of points, the volume covered when decomposed in their principal axes, and the fiducial registration error (FRE), while the error metrics are the norm of the translation vector of \(M_{error}\) (offset) and the rotation along its eigenvector (angle), and the target registration error (TRE) of the mesh points of model B.

Analysis of data

We study two registration schemes: fiducial points (FPR) and surface matching (SMR). In the former, where fiduciary points are marked or detected from the surface, we used the models’ cavities for paired points registration. Since these are easily locatable, the dominant error is the fiducial localization error (FLE), of 0.19 to 0.29 mm RMS, as reported by the camera manufacturer. In the latter, the points must be placed by the operator using geometrical or anatomical features for guidance. To account for the error in localizing the targets, we added Gaussian noise to our simulations, with zero mean and standard deviations of 0.5, 1.0, 1.5, and 2.0 mm. We trained one logistic regression classification model for each scheme to determine whether the registrations are adequate for navigation by whether they have deviations lower than 2\(^\circ \) and 2 mm or not. Our dataset consists of 160,000 trials, split into 80% for training and 20% for testing.

Phantom knee

In order to have a more realistic representation, we fabricated a plastic model consisting of the distal and proximal portions of a femur and tibia, respectively, simulating a knee in a fixed virtual plan position (Fig. 1). We applied the variables extraction and analysis already described by adding 32 fiduciary points to each fragment. Additionally, to demonstrate the accuracy and robustness of the navigation system, a surface-based experiment was performed by ignoring the fiduciary points and registering both fragments separately using paired points and surface refinement on bounded regions of the bones.

Case study: femur reconstruction

We conducted a phantom experiment based on a real case to demonstrate the feasibility of the navigation workflow. The subject is a 37-year-old male patient diagnosed with fibrous dysplasia and misalignment of the femur and tibia (Fig. 3). The femur was segmented from the CT scans, and a group of specialized surgeons decided on an appropriate surgical plan to restore the limb’s anatomical alignment by performing the necessary osteotomies and adequately orienting the bone fragments (Fig. 3). We applied our workflow by employing two 3D-printed polylactic acid models (Fig.  4). Moreover, we performed another surface-based experiment by printing a coupled version of both femur fragments in the desired preoperative plan position and registering them separately (Fig. 8).

Fig. 3
figure 3

Clinical case and the preoperative virtual plan

Fig. 4
figure 4

Navigation of dissociated parts

Compliance with ethics guidelines

This study was performed in line with the principles of the Declaration of Helsinki. Approval was granted by the Ethics Committee of Investigation Protocols of the Hospital Italiano de Buenos Aires, No. 2753.

Results

Fiducials-based experiments

The plates optimal registration resulted in an FRE of 0.473 mm for model A and 0.350 mmm for model B, alignment errors of 0.210 mm and 0.205\(^\circ \) after coupling the models, and a TRE of model B relative to the virtual plan of \(0.16\pm 0.06\) mm (Fig. 1). Considering all the FPR combinations, the angular and offset errors averaged \(0.43 \pm 0.39^\circ \) and \(0.53 \pm 0.34\) mm, with the variation against the point cloud volumes shown in Fig. 5, while the SMR combinations averaged \(3.83 \pm 5.04 ^\circ \) and \(3.35 \pm 4.28\) mm, respectively.

Fig. 5
figure 5

Plates phantom mean and deviation (\(2\sigma \)) of the alignment errors against the volume

Fig. 6
figure 6

Knee phantom mean and deviation (\(2\sigma \)) of the alignment errors against the volume

Fig. 7
figure 7

Receiver operating characteristic (ROC) curves of the FPR (blue) and SMR (red) classification models trained for the knee phantom

Fig. 8
figure 8

Coupled femur and coupled knee experiments disposition, the surface refinement points distribution, and the estimated TRE

Regarding the knee phantom, the optimal registration derived in FRE values of 0.723 mm and 0.695 mm, alignment errors of 0.58 mm and 0.58\(^\circ \) of the tibia fragment, and a TRE of \(0.51\pm 0.10\) mm (Fig. 1). The FPR alignment errors averaged \(1.51 \pm 1.26^\circ \) and \(1.11 \pm 0.73\) mm, while the SMR averaged \(2.94 \pm 3.53 ^\circ \) and \(2.00 \pm 1.90\) mm (Fig. 6).

The proportion of adequate/non-adequate for the FPR experiment resulted in 76.7%/23.3% and in 38.2%/61.8% for the SMR experiment. Their binary classification models obtained accuracies of 0.725 and 0.731, and areas under the curve (AUC) of 0.803 and 0.809, correspondingly (Fig. 7).

Surface-based experiments

The system achieved to track the motion of the dissociated models relative to the preoperative plan and inform its alignment error in real time (Fig. 4). The results for the coupled-femur experiment (Fig. 8) are shown in Table 1, where the angular and offset errors averaged in \(1.77 \pm 1.09 ^\circ \) and \(1.03 \pm 0.49\) mm, respectively. The point distribution areas for the proximal (A) and distal (B) femur fragments are the trochanters (T), the shaft (S), the condyles (C), and the supracondylar and subtrochanteric diaphysis (D). Concerning the coupled-knee experiment (Fig. 8), the alignment errors from Table 2 averaged in \(1.21 \pm 1.25 ^\circ \) and \(1.14 \pm 0.84 \) mm, where the point distribution areas for the femur (A) and tibia (B) fragments are the epiphysis (E), the metaphysis (M), and the diaphysis (S). Together, both anatomical models represent a measured error of \(1.49 \pm 1.19 ^\circ \) and \(1.08 \pm 0.68 \) mm.

Table 1 Coupled femur experiment results
Table 2 Coupled knee experiment results

Discussion

The developed navigation system accomplished to track the motion of multiple fragments relative to a preoperative plan, indicating the total translation and rotation errors and the estimated TRE. The presented workflow is compatible with commercial and free CAD programs, and its source code is available for research purposes at https://github.com/amancino/navCAS.

System accuracy

The measured accuracy in the plates phantom of \(0.43 \pm 0.39^\circ \) and \(0.53 \pm 0.34\) mm for the FPR scheme demonstrates the system’s reliability in representing the virtual scenario. When using the knee model, the measured error in the FPR scheme averaged \(1.51 \pm 1.26^\circ \) and \(1.11 \pm 0.73\) mm, showing a consistent improvement with higher volumes (Fig. 6). Moreover, 76.7% of the randomly picked trials resulted apt for navigation, and the trained classifier predicts with an accuracy of 0.725 the system’s reliability. On the contrary, the SMR scheme based only on paired points was unacceptable. Nevertheless, its classifier with an accuracy of 0.731 could enhance information during the registration process and possibly help obtain more precise primary registrations.

The results of Tables 1, 2 indicate that the system can represent the clinical scene with an acceptable error [1, 2]. Nonetheless, this highly depends on a suitable registration of both fragments, particularly on the surface refinement outcomes. Attempts to only use paired points resulted in remarkably large angular and offset errors, indicating that the refinement step is essential. Furthermore, as expected, more satisfactory results are achieved on wider surfaces. Unfortunately, this cannot be guaranteed during surgery due to the usual limited exposed bone surface.

Clinical applications

The main advantage of our multi-registration approach is that it allows the tracking of independent entities like bones, prostheses, and medical instruments. Although still in the development stage, our system covers various potential clinical applications. In hip and knee arthroplasty, it could assist the prosthesis navigation for optimal replication of the preoperative plan. Regarding maxillofacial surgery, it can track the condyles’ location and monitor the mandible mechanics during dental implant collocation and reconstructive surgery. It may also be employed to track image-generating sensors such as ultrasonic transducers [31] or electromagnetic stimulators like coils for transcranial magnetic stimulators [32]. Moreover, the method serves as a safeguard for cases of intraoperative registration loss due to a shift in the markers. As long as there is enough exposed bone surface, it permits changing the markers’ positions and repeating the registration. In addition, while incorporating new modules in commercial navigators usually requires investments in expensive application-specific packs, our work freely provides the source code of flexible tools with versatile use in the applications described.

Medical instruments have been tracked before. Chen et al. [19] tracked a surgical drill and attached a metal grid with grooves and cylindrical targets to a printed model to assess the location and angular error. Nevertheless, the method only applies to pointing instruments and thus is incompatible with tracking arbitrary objects like a saw, a transducer, or a prosthesis. On the other hand, our approach allows the registration of any rigid object as long as a precise 3D model can be acquired and does not require the fabrication of a specific calibration device.

Regarding the tracking of bones and implants, although the navigation method for orthognathic surgery proposed by Li et al. [21] does not require intraoperative registration, it relies on acquiring the CT images of the patient with the splint. On the contrary, our system demands at least one registration for both the skull and MMC before loosening and allows a second registration local to the MMC at any time. While Wang et al. [33] measured the error in the position of the condyles after orthognathic surgery in 23 patients by comparing using postsurgical CT images, our system could directly inform the translation error in each condyle by enabling the control points functionality. Moreover, the studies that tracked the loosed graft [22] and the pelvic fragment [24] compare the alignments obtained when using or not the virtual information provided by their navigation system, neglecting the registration error immersed in the represented virtual scene. Even though the latter was applied to a real patient, the authors did not inform surgical placement errors besides stating that the sections were tumor-free and that the patient evolved well. On the other hand, we designed a controlled experiment where we set the real physical scenario and directly measured the navigator’s error. In addition, we reported the corresponding FRE of each trial and fragment, both for the primary and secondary registrations, and estimated the TRE throughout the tracked body. Hence, our experiment is more suitable for measuring the system’s accuracy than comparing navigated and non-navigated trials. One relevant remark is that tracking a manufactured implant allows freely placing marks on it to perform FPR alone, which has been supported by our results of Fig. 6.

Limitations and future work

The plates phantom experiment allowed us to illustrate the error analysis and determine the system’s accuracy and precision. However, when measuring the coupled knee and femur models, the obtained errors were significantly higher. One major drawback of our study is that we only evaluated these two anatomical models. It would be convenient to test additional cases, use more realistic phantoms, or even conduct cadaveric experiments. Future investigations could include working on more sophisticated classification models taking into account the morphology of the bones and the specific regions chosen for the refinement and be potentially trained on simulated data directly.

Previous studies have developed prediction models for the TRE, highlighting the importance of overestimating the error [34]. In this regard, the classifier’s sensitivity can be adjusted using the ROC curves (Fig. 7). We decided to maximize the accuracy, which is the ratio between the number of correct classifications and the total amount of cases, but more restrictive models could favor the true-positive rate. Also, the angular and offset classification thresholds could be adapted to the specific application, as long as the models are pretrained using a balanced training set.

Respecting the adopted technology, while recent works used magnetic sensors to track the acetabular fragment [26, 27], our system was based on optical navigation. Nevertheless, the main software modules are independent of the tracking technology and can be easily adapted to use magnetic sensors. These have the advantage of being smaller, might be more practical to attach, are not occluded by the surgeon or patient anatomy, nor require to point towards a camera. On the other hand, they generally require wiring, are less accurate than optical trackers [35], and their electromagnetic field can suffer from distortions in the vicinity of metallic objects.

Lastly, one disadvantage of our system is that it requires images. Although these might be acquired nonetheless for the diagnosis, there could be cases where the available modalities may not be appropriate for the virtual plan preparation, possibly implying ionizing radiation to the patient. Nevertheless, modern CAS tools could directly benefit from technologies that improve bone segmentation from MRI [36] or low dose CT [37].

Conclusion

The developed system performed more accurately in the phantom experiments testing the FPR scheme, turning our method into a reliable tool for tracking fabricated parts with physical marks. On the other hand, the SMR experiments showed that the surface refinement process is mandatory. Hence, the technique might be impractical for cases where the exposed bone surface is limited. Overall, we believe that our navigation system and workflow could bring significant advantages to the personalized treatment of complex surgical cases and that it could complement existing CAS tools.