The Osaka High Court has upheld a lower court ruling sentencing a man to 30 years in prison for murdering a man and injuring his three children at their home in Osaka Prefecture in 2016.

The high court on Monday rejected appeals by prosecutors who had sought the death penalty and by the defense of 26-year-old Yuma Kobayashi, who argued he was mentally incompetent at the time of the slaying.

The court found that Kobayashi broke into the home of 43-year-old carpenter Yukinobu Kawakami, who he did not know, in Kadoma early on Oct. 19, 2016, before fatally stabbing the man, who was sleeping on the second floor, in the chest and back about 30 times, and injuring his daughters, aged 22 and 20, and his 18-year-old son.

In handing down the ruling, presiding Judge Hiroaki Murayama said Kobayashi did not entirely know what he was doing at the time of the murder, dismissing prosecutors' argument that he was capable of taking full criminal responsibility.

But Murayama also rejected the defense's claim, saying, "It's hard to recognize he was totally dominated by delusions" as he had cased the Kawakami house beforehand.

In April last year, the Osaka District Court handed down a 30-year prison term for Kobayashi, while acknowledging he lost self-control due to paranoid schizophrenia.