Comparative Analysis of Sound Response from Simple and Fuzzy Algorithm in Saron Virtual Reality

. Comparative Analysis of Sound Response from Simple and Fuzzy Algorithm in Saron Virtual Reality. Virtual reality games with musical instruments require a dynamic sound response because playing the instrument requires real human feelings. A good sound in a game depends on its suitability for the game situation. Time and place limitations are a problem in recording variations in sound sample recording. If the sound samples taken are limited and a simple algorithm is applied, it may sound repetitive and not match the dynamics of music according to real human life. Therefore, in this study, a comparison of a simple algorithm with the fuzzy algorithm was carried out in the Gamelan Saron game. The data processing method used is a comparative analysis obtained from the experimental results of the respondents. On the agreement scale of one to five, most respondents agree that there is a better significant change after being given a fuzzy algorithm described by a mean value of 4.1.


Introduction
This project was carried out to create a gamelan metaverse game.In this gamelan metaverse project, there is a division of teams.Our team focused on developing Gamelan Saron.The processes that have been done include surveys at gamelan playing venues with experts to increase knowledge about gamelan, creating product requirement documents, making 3D gamelan assets, taking sound samples of several types of gamelan, implementing assets that have been obtained into programming until doing the continuous tests.
Each team encountered the same problem in the sound programming process: a repetitive and flat sound response.We did audio recordings in this way, and each Gamelan Saron tone blade is sampled five times, three for the normal sound of the slow, medium, and hard-hitting, and two for the sound of hitting when the blade is held, resulting in a short sustain sound with slow and loud strokes.This recording method was done due to time and place limitations.Also, other types of gamelan were recorded, so it took much time to take every variation of sound samples for each gamelan.The recording is one of the most time-consuming tasks to avoid perceived repetition.This recording time limitation made the voice response variation limited and less varied.Therefore, this study applied the procedurally driven audio called the Fuzzy Tsukamoto algorithm.The sound designer has the potential to generate automatic or generative scrambling of sounds in real-time with dynamic sound models from fuzzy computations.
This research was conducted to prove that fuzzy algorithms can make sound response dynamics better.A good sound response is a good response with dynamics like in real human life, which means realistic.The fuzzification process can map dynamic volume response rules based on the user's hand movement speed has a wider range.The research objective is to provide an alternative solution, namely a fuzzy algorithm for a more realistic and dynamic sound response experience.Based on our problems, the research being studied is the user experience of Gamelan Saron VR towards the sound experience given after implementing the fuzzy algorithm.

Literature Review 2.1. Virtual Reality and Gaming Industry
Virtual reality (VR) has become more attractive, with graphics, sensor technology, and processor development happening rapidly.Due to this potential, Oculus, a well-known VR company since 2014, was taken over by Facebook.They knew that VR technology would be necessary for the future.Wall Street experts also predicted that the future of VR would be one of the most significant advances in the human technology [1].The increasing appeal of VR is driven by immersive experiences that come at an affordable price [2].In addition, the entertainment model of games is increasingly being accepted by people of all ages.More people love to play games and are motivated to create their games on platforms [3].Virtual reality can also be discovered in several colleges and universities in individual, group, and online learning activities.Delivery of material using simulations in VR is effective enough to replace direct activities [4].
Many elements, such as images, sound, and gameplay, must be considered in developing a VR game.A good synergy between these elements is needed to produce a successful game.Among these elements, the sound element is important in presenting the game's atmosphere.The player's subconscious can be touched through the sound experience given in the game, both from the music and sound effects [5].Special attention given to developing the best experience from a game makes the development process involve cross-functional teams such as software developers, musicians, designers, and scriptwriters [3].

Music and Gamelan Saron
Each musical instrument can produce a unique sound character.The uniqueness of the sound character can occur because of the frequency, sound pressure, and duration of the sound propagation [6].In Indonesia, there is a unique set of traditional musical instruments born from the traditions of the Javanese people called gamelan.Gamelan works as a means of education, entertainment, rituals, or religious ceremonies [7].Gamelan instruments are made of metal and played by being beaten.One of them is Saron.Saron can be played using two hands.First, the Wilahan is hit using a wooden mallet at a certain angle and speed to produce a good and clear sound.So that the resonance and frequency can be controlled and sound comfortable, the musicians can then muffle the sound by touching the area with the index finger and thumb.At the same time, the musicians can also hit other notes.Each pair of Saron consists of two barrels: slendro and pelog barrels.The two barrels are a system of scales in gamelan, so they have a fundamental difference in the arrangement of the tones.The slendro barrel is a six-tone system, and the pelog barrel is a seven-tone system [7].

Fuzzy Logic
Prof. Lotfi A. Zadeh first introduced fuzzy logic in 1965.He stated that fuzzy logic is associated with formal reasoning principles on unconditional things or approximate reasoning [8].In fuzzy set theory, the role of membership degree as a determinant of the presence of elements in a set is crucial.Membership value is the main feature of reasoning with the fuzzy set theory [9].Fuzzy set theory has also attracted attention and interest in production engineering, modern information technology, pattern recognition, diagnostics, decision-making, and data analysis [10].This theory is widely used in decision-making in various fields, such as finance, sales, biotechnology, and management [11].Fuzzy logic is an appropriate tool for dealing with dynamic behaviour problems.That is, fuzzy logic has the power to provide accurate solutions to problems involving the manipulation of several variables [10].The fuzzy logic approach originates from unlimited conceptual knowledge carried out by human logic.Several fuzzy logic concepts include linguistic variables, fuzzy sets, probability distributions, and if-then fuzzy rules.The successful application of fuzzy sets and logic can be attributed to the fact that fuzzy theory describes actual dynamic situations from the real world because the logic of approximate reasoning dominates human thinking.

Method
The method applied in designing the algorithm and collecting data is as follows:

Literature Study
This process searched for or collected various journal references, articles, and other media to support theories and provide essential information for this research.

Implementing Fuzzy Logic
Based on the current problem, this research only uses the fuzzy algorithm to generate sound.The results will be discussed immediately in this section.The fuzzy logic model was obtained from Tsukamoto's fuzzy inference system and was developed using C# scripts in the Unity application.The three basic phases involved in a fuzzy logic model are as follows [12]: (a) Fuzzification forms the appropriate membership function [12] to convert solid or firm input variables into linguistic ones [13].(b) The selection of the suitable form and definition of linguistic statements are called fuzzy rules [12].The evaluation process in the Fuzzy Tsukamoto inference system applies the MIN or MAX implication function to obtain the α-predicate value of each rule (1, 2, 3, …, ) based on the (AND) or (OR) operator.Each α-predicate value is used to calculate the crisp results of each rule (z1, z2, z3,.... zn) [13].The following equations are shown in numbers (1) and (2).
(c) The process of converting fuzzy data into numeric data as a final decision is the definition of the defuzzification [14].The defuzzification process in Fuzzy Tsukamoto uses the average calculation [13], which is represented by this equation number (3).
The input variable used was the average movement speed of the user's hand on the VR controller taken from the function in the Velocity Estimator script in Unity and audio samples obtained when recording live gamelan.The Velocity Estimator script was obtained from GitHub open-source code [15].This script has two types of velocity: linear velocity and angular velocity.This study used linear velocity.The output value of the velocity function was obtained by calculating the average number of frames received in a specific time to produce a speed value without the rotation effect.This number of frames was taken from the change in 3D position (named Vector3 in Unity) from the starting point to the last point when it touches the Gamelan Saron bar and then divided by the time it takes to reach it (delta time).Based on testing the values obtained from the Velocity Estimator script, the user's hand movement speed has a value range of zero to the most optimal maximum value of twelve (0-12), and the rest of the hand movements needed are too fast.The three types of sound samples are defined: low (Audio 1), medium (Audio 2), and high (Audio 3).
In this study, two algorithms were used, the simple and fuzzy algorithms.This aspect is necessary for comparing sound dynamics in experimental validation to questionnaires on respondents in the next process.

Simple Algorithm
This simple algorithm gets the dynamics of the sound based on the different types of sound samples taken from soft to hard-hitting.In the simple algorithm, three audio samples will be sounded according to a simple algorithm's hand movement speed range.Each audio is sounded at the same volume, which is one.This value is adjusted to Unity's standard that the optimal maximum volume is valued at one.So, more than that can damage the quality of the sound source.The following Figure 1 is the flowchart of a simple algorithm.

Fuzzy Tsukamoto Algorithm
In the Fuzzy Tsukamoto algorithm, each fuzzy value limit is determined based on the researcher's initial estimate based on the existing input variables.Better values can be obtained after the respondent participates in the test and then provides input at the end of the questionnaire column.The following Figure 2 is the flowchart of the fuzzy algorithm.The design process for testing the fuzzy algorithm applied to Gamelan Saron VR is as follows in Figure 3, Figure 4, and Figure 5.The following is the equation for determining slow, normal, and fast velocity shown in equations number (4), (5), and (6).

Figure 4. Audio Sample variable membership function
The following is the equation for determining which audio to be activated, shown in equations number (7), (8), and (9).
Q 0;  ≤ 2.5   ≥ 7.5 1; 2.5 <  < 7.5  The following is an equation for determining the low or high of the sound shown in equations number (10) and (11).
This study's input variable for hand movement speed (velocity) ranged between zero and twelve (0-12).The input variable of the audio sample in this study had a membership function of one when it was in a certain speed range.The value of this membership function will be useful for the comparison process in α.Predicate to find z values (final result of Fuzzy Tsukamoto).Each audio input variable from Audio 1, Audio 2, and Audio 3 is useful for determining whether the audio will sound, so the value is only one or zero (1 or 0).Meanwhile, the output variable was the volume given to each audio sample.Fuzzy rules are based on the volume priority when the audio is played.
Three audio samples are sounded together in this algorithm concept, but the fuzzy algorithm's volume calculations determine the sound.Several experiments have shown they have different volume ranges when two audio samples are simultaneously sounded.It is necessary smoother movement of sound samples as in the fuzzy concept, which applies each boundary uncertainly.This means that a specific range describes an uncertain situation, so a combination of two audio samples occurs.Here are some volume output data values for each audio during testing in Table 1.

Testing Environment
The test was designed with the same two Gamelan Saron 3D assets but with different blade response processing scripts and simple and fuzzy algorithms.The Gamelan Saron with a simple algorithm is below the stage, while the one with a fuzzy algorithm is above the stage.The environmental design is based on a project plan with impenetrable walls surrounding the stage space.In addition, there are several lighting models so that users can see around the environment, even in a closed room.

Experiment and Questionnaire Validation
The process needed to prove this research's initial goal is applying fuzzy logic to sound dynamics in the Gamelan Saron Virtual Reality game.This study's examiners and respondents are Paskawijaya University Student Activity Unit (UKM) members at Universitas Atma Jaya Yogyakarta (UAJY).The activities of this UKM are weekly gamelan practice, sharing sessions about gamelan, and collaboration with other parties regarding stage performances.UKM Paskawijaya has 29 members.Every member of UKM Paskawijaya understands the dynamics of gamelan sound in the real world so that they can provide a reasonably accurate assessment.Based on Slovin's formula, with a 5% of margin of error, this research needs 28 respondents.In the game environment designed in Unity, two Gamelan Saron with simple and fuzzy algorithms were on respondents.At the end of the simulation, respondents filled out questionnaires related to personal experience (to validate interest in music or gamelan), simulation questions showing differences in the dynamics and realistic scale of gamelan sound, and questions validating experimental results as criticism and suggestions.

Data Processing
Data processing used comparative analysis methods and descriptive statistics.The comparative analysis of this study used the T-test, a statistical test used to compare the averages of the two groups.This statistical test will compare dynamic and realistic scale data using simple and fuzzy algorithms.Descriptive statistics are used to validate personal experience backgrounds and validate experimental results.The data analysed with descriptive statistics is needed to support the respondents' dynamic and realistic scale assessment results.

Personal Experience Validation
The data in this questionnaire was needed to validate whether the respondent had real credibility regarding their general experiences with sound and music.The range of values for this questionnaire is one to five (1-5), indicating agreement (strongly disagree, disagree, neutral, agree, strongly agree).The data analysis used in this personal experience validation was descriptive statistics.The following is a descriptive statistic validating personal experience shown in Table 2.The first statement shows the respondent's sensitivity to sounds around them.Respondents tend to agree based on the average value (mean) of 4.25.Other values obtained from the standard error to the confidence level have a small distribution value.Hence, most respondents are sensitive to every sound that occurs, such as sound dynamics, noise pollution or sound distraction, and harmonisation.The second statement shows the respondents' interest in music in general.Based on the mean value of 4.64, respondents tend to agree and approach the value of strongly agree.The value from the standard error to the confidence level has a small distribution value.It has decreased compared to the previous statement, so there is an increase in approval confidence in this statement, and most respondents are interested in music.The third statement shows the respondent's interest in the dynamics that occur in music.Respondents tend to answer in agreement based on the mean value of 4.42.Even though the average agreement is smaller than the second statement, the other values obtained from the standard error to the confidence level have a smaller distribution value, so there is an increase in approval confidence in this statement.The majority of respondents are interested in dynamic music playing.The fourth statement shows agreement with the importance of playing music with feeling.Based on the mean value of 4.75, respondents tend to agree and approach the value of strongly agree.The distribution value from the standard error to the confidence level shows a significant decrease compared to other statements.Hence, there is an increase in approval confidence in this statement compared to other statements.Most respondents agree that they understand the importance of playing music with feelings.
Based on data analysis on each personal experience statement, most respondents proved to be people who are used to recognising sounds, such as attention to sounds happening around them, interest in music, and like the dynamics of sounds that occur in music and involving feelings.The direction of this data is quite clear because the respondents were members of karawitan, so they understood.They can support the data provided in the experimental results question section because it relates to the credibility of respondents who have attention to the details of the sound that is happening.The data analysis in this section is needed for validation.

Dynamics and Realistic Scale
The data in this questionnaire is used to determine whether there is a significant difference in the dynamics and natural sound response between the simple and fuzzy algorithms.The data analysis used was the paired (dependent) t-test.The following are paired t-tests of the dynamic and realistic scales shown in Table 3 and Table 4.The score interval is one to five (1)(2)(3)(4)(5), indicating a bad to good scale (very bad, bad, average, good, very good).The data has changed significantly.Based on the T-test results obtained on the dynamics scale, the mean value has increased from 3.57 (between normal and good) to 4.3 (between good and very good).The variance value has decreased a lot, which means that the average value is accurate, and there is an increasing tendency for answers in the average area.The value of the Pearson correlation (0 < 0.21 < 1) indicates a slight positive correlation between the two data.The two-tailed t Critical value compared to the absolute value of tStat |tStat| shows a smaller value (2.051 < 3.065).In addition, the P(T<=t) value is smaller when compared to the significant alpha determination (0.004 <0.05), so this value can also support that the data underwent substantial changes.The data has changed significantly.Based on the T-test results obtained on a realistic scale, the mean value has increased from 3.78 (between normal and good) to 4.14 (between good and very good).The variance value has decreased slightly, so the average value is more accurate.The value of the Pearson correlation (0 < 0.761 < 1) indicates many positive correlations between the two data.The two-tailed tCritical value compared to the absolute value of tStat |tStat| shows a smaller value (2.051 <2.785).In addition, the two-tailed P(T<=t) value is smaller when compared to the significant alpha determination (0.009 <0.05), so this value can also support that the data has a significant change.
The results of each dynamic scale and realistic scale T-Test show that each analysis scale of the fuzzy algorithm has improved.On the dynamics scale, the changes that occur are significant, as demonstrated by the long range of the mean and a large decrease in the variance value.On a realistic scale, the changes that occur are also significant, but the difference in the mean of a real scale is farther than the dynamics scale and the decrease in variance.Based on the analysis, the fuzzy algorithm significantly changes the dynamics and realistic audio in a better direction.

Experimental Results Validation
The data in this questionnaire was used to validate changes felt by respondents when using the fuzzy algorithm.The given questionnaire's value intervals are one to five (1-5), indicating agreement (strongly disagree, disagree, neutral, agree, strongly agree).The following is a descriptive statistic validating the experimental result in Table 5.Based on the value of the descriptive statistical analysis obtained from the three statements, there is the same mean tendency of 4.1, which tends to agree.Every other variability value shows a fairly small distribution value, so most respondents agree that the fuzzy algorithm provides a significant change in the dynamics and realistic sound for the better.
A text entry is at the end of the questionnaire, so respondents provide input through comments, criticisms, or suggestions.Most of the respondents felt quite satisfied and good with the dynamics and natural sound response due to the application of the fuzzy algorithm in Gamelan Saron Virtual Reality.

Conclusions and Recommendations
This statement is based on the discussion we did.Implementing the Tsukamoto Fuzzy algorithm on the sound dynamics of the Gamelan Saron VR game is quite effective and helpful.Most respondents were experienced in understanding the dynamics of gamelan music or music, defined by the mean value of all personal experience validation statements above four, which means a good agreement.This finding can support dynamic scale data and realistic scale because most respondents can assess the sound of gamelan properly and accurately.Dynamic and realistic scale comparative analysis showed a significant change for the better when using fuzzy algorithms defined by increasing mean value and both of the P(T<=t) two-tail values being below alpha value 0.05.In addition, the validation of the experimental results also showed that most respondents agreed with a significant difference for the better regarding the dynamics and realistic sound, which is defined by the value of all statements being above four.
In addition, some comments at the end of the questionnaire are helpful for future research to determine a more realistic speed limit because some respondents feel that at a slow speed hand, it should generate such a larger volume and have long sustained does not require that fast speed hand.This recommendation relates to the determination of boundaries in the previous fuzzification process.

Acknowledgement
The author would like to thank all parties who supported this research, from every supporting lecturer who was so enthusiastic in providing direction, supportive project partners, and UKM Paskawijaya who took the time to become experimental respondents.The author also thanked the Ministry of Education, Culture, Research and Technology (Kemendikbudristek) for the Kedaireka Matching Fund grant number SK 0540/E/KS.06.02/2022, which supports this project.

Figure 5 .
Figure 5. Volume variable membership function