/*
 * chamber_music_hall.java
 */

import com.comsol.model.*;
import com.comsol.model.util.*;

/** Model exported on Nov 18 2025, 16:31 by COMSOL 6.4.0.293. */
public class chamber_music_hall {

  public static Model run() {
    Model model = ModelUtil.create("Model");

    model.component().create("comp1", true);

    model.component("comp1").geom().create("geom1", 3);
    model.component("comp1").geom("geom1").geomRep("comsol");

    model.component("comp1").mesh().create("mesh1");
    model.component("comp1").mesh("mesh1").contribute("geom/detail", true);

    model.component("comp1").physics().create("rac", "RayAcoustics", "geom1");

    model.study().create("std1");
    model.study("std1").create("rtrac", "RayTracing");

    model.param().label("Parameters 1 - Study setup");

//    To import content from file, use:
//    model.param().loadFile("FILENAME");
    model.param().set("rho0", "1.2[kg/m^3]", "Density");
    model.param().set("c0", "343[m/s]", "Speed of sound");
    model.param().set("f0", "500[Hz]", "Band center frequency");
    model.param().set("lam0", "c0/f0", "Wavelength at f0");
    model.param().set("P0", "0.12[W]", "Source power");
    model.param().set("Vol", "2350[m^3]", "Room volume");
    model.param().set("r_rec", "0.3[m]", "Receiver radius");
    model.param().set("dt", "0.01[s]", "Time interval");
    model.param().set("Nrays_min", "(4.34/r_rec)^2*Vol/pi/c0/dt", "Recommended minimum number of released rays");
    model.param().set("Nrays", "1000*ceil(Nrays_min/1000)", "Number of released rays");
    model.param().create("par2");
    model.param("par2").label("Parameters 2 - Source and receiver positions");

//    To import content from file, use:
//    model.param("par2").loadFile("FILENAME");
    model.param("par2").set("x_s1", "-2.02[m]", "Source 1 x-coordinate");
    model.param("par2").set("y_s1", "2[m]", "Source 1 y-coordinate");
    model.param("par2").set("z_s1", "2.38[m]", "Source 1 z-coordinate");
    model.param("par2").set("x_s2", "-3.32[m]", "Source 2 x-coordinate");
    model.param("par2").set("y_s2", "-2[m]", "Source 2 y-coordinate");
    model.param("par2").set("z_s2", "2.38[m]", "Source 2 z-coordinate");
    model.param("par2").set("x_r1", "7.84[m]", "Receiver 1 x-coordinate");
    model.param("par2").set("y_r1", "0[m]", "Receiver 1 y-coordinate");
    model.param("par2").set("z_r1", "1.23[m]", "Receiver 1 z-coordinate");
    model.param("par2").set("x_r2", "2.165[m]", "Receiver 2 x-coordinate");
    model.param("par2").set("y_r2", "3.441[m]", "Receiver 2 y-coordinate");
    model.param("par2").set("z_r2", "1.23[m]", "Receiver 2 z-coordinate");
    model.param("par2").set("x_r3", "9.227[m]", "Receiver 3 x-coordinate");
    model.param("par2").set("y_r3", "2.366[m]", "Receiver 3 y-coordinate");
    model.param("par2").set("z_r3", "1.23[m]", "Receiver 3 z-coordinate");
    model.param("par2").set("x_r4", "5.86[m]", "Receiver 4 x-coordinate");
    model.param("par2").set("y_r4", "-2.359[m]", "Receiver 4 y-coordinate");
    model.param("par2").set("z_r4", "1.23[m]", "Receiver 4 z-coordinate");
    model.param("par2").set("x_r5", "12.726[m]", "Receiver 5 x-coordinate");
    model.param("par2").set("y_r5", "-3.24[m]", "Receiver 5 y-coordinate");
    model.param("par2").set("z_r5", "1.23[m]", "Receiver 5 z-coordinate");
    model.param("par2")
         .set("ds1r1", "sqrt((x_s1-x_r1)^2+(y_s1-y_r1)^2+(z_s1-z_r1)^2)", "Distance source 1 to receiver 1");
    model.param("par2")
         .set("ds1r2", "sqrt((x_s1-x_r2)^2+(y_s1-y_r2)^2+(z_s1-z_r2)^2)", "Distance source 1 to receiver 2");
    model.param("par2")
         .set("ds1r3", "sqrt((x_s1-x_r3)^2+(y_s1-y_r3)^2+(z_s1-z_r3)^2)", "Distance source 1 to receiver 3");
    model.param("par2")
         .set("ds1r4", "sqrt((x_s1-x_r4)^2+(y_s1-y_r4)^2+(z_s1-z_r4)^2)", "Distance source 1 to receiver 4");
    model.param("par2")
         .set("ds1r5", "sqrt((x_s1-x_r5)^2+(y_s1-y_r5)^2+(z_s1-z_r5)^2)", "Distance source 1 to receiver 5");
    model.param("par2")
         .set("ds2r1", "sqrt((x_s2-x_r1)^2+(y_s2-y_r1)^2+(z_s2-z_r1)^2)", "Distance source 2 to receiver 1");
    model.param("par2")
         .set("ds2r2", "sqrt((x_s2-x_r2)^2+(y_s2-y_r2)^2+(z_s2-z_r2)^2)", "Distance source 2 to receiver 2");
    model.param("par2")
         .set("ds2r3", "sqrt((x_s2-x_r3)^2+(y_s2-y_r3)^2+(z_s2-z_r3)^2)", "Distance source 2 to receiver 3");
    model.param("par2")
         .set("ds2r4", "sqrt((x_s2-x_r4)^2+(y_s2-y_r4)^2+(z_s2-z_r4)^2)", "Distance source 2 to receiver 4");
    model.param("par2")
         .set("ds2r5", "sqrt((x_s2-x_r5)^2+(y_s2-y_r5)^2+(z_s2-z_r5)^2)", "Distance source 2 to receiver 5");

    model.func().create("int1", "Interpolation");
    model.func("int1").set("source", "file");
    model.func("int1").set("filename", "chamber_music_hall_air_attenuation.txt");
    model.func("int1").importData();
    model.func("int1").set("funcname", "a_air");
    model.func("int1").set("interp", "neighbor");
    model.func("int1").setIndex("fununit", "Np/m", 0);
    model.func("int1").setIndex("argunit", "Hz", 0);
    model.func().create("int2", "Interpolation");
    model.func("int2").set("source", "file");
    model.func("int2").set("filename", "chamber_music_hall_ceiling.csv");
    model.func("int2").setIndex("argunit", "Hz", 0);
    model.func("int2").setEntry("columnType", "col2", "value");
    model.func("int2").setEntry("funcnames", "col2", "a_ceiling");
    model.func("int2").setIndex("fununit", "1", 0);
    model.func("int2").setEntry("funcnames", "col3", "s_ceiling");
    model.func("int2").setIndex("fununit", "1", 1);
    model.func("int2").set("interp", "neighbor");
    model.func("int2").importData();
    model.func().create("int3", "Interpolation");
    model.func("int3").set("source", "file");
    model.func("int3").set("filename", "chamber_music_hall_floor.csv");
    model.func("int3").setIndex("argunit", "Hz", 0);
    model.func("int3").setEntry("columnType", "col2", "value");
    model.func("int3").setEntry("funcnames", "col2", "a_floor");
    model.func("int3").setIndex("fununit", "1", 0);
    model.func("int3").setEntry("funcnames", "col3", "s_floor");
    model.func("int3").setIndex("fununit", "1", 1);
    model.func("int3").set("interp", "neighbor");
    model.func("int3").importData();
    model.func().create("int4", "Interpolation");
    model.func("int4").set("source", "file");
    model.func("int4").set("filename", "chamber_music_hall_plaster.csv");
    model.func("int4").setIndex("argunit", "Hz", 0);
    model.func("int4").setEntry("columnType", "col2", "value");
    model.func("int4").setEntry("funcnames", "col2", "a_plaster");
    model.func("int4").setIndex("fununit", "1", 0);
    model.func("int4").setEntry("funcnames", "col3", "s_plaster");
    model.func("int4").setIndex("fununit", "1", 1);
    model.func("int4").set("interp", "neighbor");
    model.func("int4").importData();
    model.func().create("int5", "Interpolation");
    model.func("int5").set("source", "file");
    model.func("int5").set("filename", "chamber_music_hall_seating.csv");
    model.func("int5").setIndex("argunit", "Hz", 0);
    model.func("int5").setEntry("columnType", "col2", "value");
    model.func("int5").setEntry("funcnames", "col2", "a_seating");
    model.func("int5").setIndex("fununit", "1", 0);
    model.func("int5").setEntry("funcnames", "col3", "s_seating");
    model.func("int5").setIndex("fununit", "1", 1);
    model.func("int5").set("interp", "neighbor");
    model.func("int5").importData();
    model.func().create("int6", "Interpolation");
    model.func("int6").set("source", "file");
    model.func("int6").set("filename", "chamber_music_hall_stagepanels.csv");
    model.func("int6").setIndex("argunit", "Hz", 0);
    model.func("int6").setEntry("columnType", "col2", "value");
    model.func("int6").setEntry("funcnames", "col2", "a_stagepanels");
    model.func("int6").setIndex("fununit", "1", 0);
    model.func("int6").setEntry("funcnames", "col3", "s_stagepanels");
    model.func("int6").setIndex("fununit", "1", 1);
    model.func("int6").set("interp", "neighbor");
    model.func("int6").importData();
    model.func().create("int7", "Interpolation");
    model.func("int7").set("source", "file");
    model.func("int7").set("filename", "chamber_music_hall_structuredplaster.csv");
    model.func("int7").setIndex("argunit", "Hz", 0);
    model.func("int7").setEntry("columnType", "col2", "value");
    model.func("int7").setEntry("funcnames", "col2", "a_structuredplaster");
    model.func("int7").setIndex("fununit", "1", 0);
    model.func("int7").setEntry("funcnames", "col3", "s_structuredplaster");
    model.func("int7").setIndex("fununit", "1", 1);
    model.func("int7").set("interp", "neighbor");
    model.func("int7").importData();
    model.func().create("int8", "Interpolation");
    model.func("int8").set("source", "file");
    model.func("int8").set("filename", "chamber_music_hall_windows.csv");
    model.func("int8").setIndex("argunit", "Hz", 0);
    model.func("int8").setEntry("columnType", "col2", "value");
    model.func("int8").setEntry("funcnames", "col2", "a_windows");
    model.func("int8").setIndex("fununit", "1", 0);
    model.func("int8").setEntry("funcnames", "col3", "s_windows");
    model.func("int8").setIndex("fununit", "1", 1);
    model.func("int8").set("interp", "neighbor");
    model.func("int8").importData();
    model.func().create("int9", "Interpolation");
    model.func("int9").set("source", "file");
    model.func("int9").set("filename", "chamber_music_hall_EDT.txt");
    model.func("int9").importData();
    model.func("int9").set("funcname", "EDT_meas");
    model.func("int9").set("interp", "neighbor");
    model.func("int9").setIndex("fununit", "s", 0);
    model.func("int9").setIndex("argunit", "Hz", 0);
    model.func().create("int10", "Interpolation");
    model.func("int10").set("source", "file");
    model.func("int10").set("filename", "chamber_music_hall_T20.txt");
    model.func("int10").importData();
    model.func("int10").set("funcname", "T20_meas");
    model.func("int10").set("interp", "neighbor");
    model.func("int10").setIndex("fununit", "s", 0);
    model.func("int10").setIndex("argunit", "Hz", 0);
    model.func().create("int11", "Interpolation");
    model.func("int11").set("source", "file");
    model.func("int11").set("filename", "chamber_music_hall_C80.txt");
    model.func("int11").importData();
    model.func("int11").set("funcname", "C80_meas");
    model.func("int11").set("interp", "neighbor");
    model.func("int11").setIndex("fununit", "dB", 0);
    model.func("int11").setIndex("argunit", "Hz", 0);
    model.func().create("int12", "Interpolation");
    model.func("int12").set("source", "file");
    model.func("int12").set("filename", "chamber_music_hall_D50.txt");
    model.func("int12").importData();
    model.func("int12").set("funcname", "D50_meas");
    model.func("int12").set("interp", "neighbor");
    model.func("int12").setIndex("fununit", "%", 0);
    model.func("int12").setIndex("argunit", "Hz", 0);

    model.component("comp1").geom("geom1").insertFile("chamber_music_hall_geom_sequence.mph", "geom1");
    model.component("comp1").geom("geom1").run("fin");
    model.component("comp1").geom("geom1").run("difsel1");
    model.component("comp1").geom("geom1").create("sph1", "Sphere");
    model.component("comp1").geom("geom1").feature("sph1").set("type", "surface");
    model.component("comp1").geom("geom1").feature("sph1").set("r", "r_rec");
    model.component("comp1").geom("geom1").feature("sph1").set("pos", new String[]{"x_r1", "y_r1", "z_r1"});
    model.component("comp1").geom("geom1").feature("sph1").set("selresult", true);
    model.component("comp1").geom("geom1").feature("sph1").set("selresultshow", "bnd");
    model.component("comp1").geom("geom1").selection().create("csel1", "CumulativeSelection");
    model.component("comp1").geom("geom1").selection("csel1").label("All receivers");
    model.component("comp1").geom("geom1").feature("sph1").set("contributeto", "csel1");
    model.component("comp1").geom("geom1").feature().duplicate("sph2", "sph1");
    model.component("comp1").geom("geom1").feature("sph2").set("pos", new String[]{"x_r2", "y_r2", "z_r2"});
    model.component("comp1").geom("geom1").feature().duplicate("sph3", "sph2");
    model.component("comp1").geom("geom1").feature("sph3").set("pos", new String[]{"x_r3", "y_r3", "z_r3"});
    model.component("comp1").geom("geom1").feature().duplicate("sph4", "sph3");
    model.component("comp1").geom("geom1").feature("sph4").set("pos", new String[]{"x_r4", "y_r4", "z_r4"});
    model.component("comp1").geom("geom1").feature().duplicate("sph5", "sph4");
    model.component("comp1").geom("geom1").feature("sph5").set("pos", new String[]{"x_r5", "y_r5", "z_r5"});
    model.component("comp1").geom("geom1").run("fin");

    model.component("comp1").physics("rac").prop("cext").setIndex("cext", "c0", 0);
    model.component("comp1").physics("rac").prop("rhoext").setIndex("rhoext", "rho0", 0);
    model.component("comp1").physics("rac").prop("alphaext").setIndex("alphaext", "a_air(f0)", 0);
    model.component("comp1").physics("rac").feature("op1").set("f", "f0");
    model.component("comp1").physics("rac").create("wall2", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall2").label("Wall - Plaster");
    model.component("comp1").physics("rac").feature("wall2").selection().named("geom1_difsel1");
    model.component("comp1").physics("rac").feature("wall2").set("s", "s_plaster(f0)");
    model.component("comp1").physics("rac").feature("wall2").set("alpha", "a_plaster(f0)");
    model.component("comp1").physics("rac").create("wall3", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall3").label("Wall - Stage Panels");
    model.component("comp1").physics("rac").feature("wall3").selection().named("geom1_sel1");
    model.component("comp1").physics("rac").feature("wall3").set("s", "s_stagepanels(f0)");
    model.component("comp1").physics("rac").feature("wall3").set("alpha", "a_stagepanels(f0)");
    model.component("comp1").physics("rac").create("wall4", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall4").label("Wall - Windows");
    model.component("comp1").physics("rac").feature("wall4").selection().named("geom1_sel2");
    model.component("comp1").physics("rac").feature("wall4").set("s", "s_windows(f0)");
    model.component("comp1").physics("rac").feature("wall4").set("alpha", "a_windows(f0)");
    model.component("comp1").physics("rac").create("wall5", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall5").label("Wall - Seating");
    model.component("comp1").physics("rac").feature("wall5").selection().named("geom1_sel3");
    model.component("comp1").physics("rac").feature("wall5").set("s", "s_seating(f0)");
    model.component("comp1").physics("rac").feature("wall5").set("alpha", "a_seating(f0)");
    model.component("comp1").physics("rac").create("wall6", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall6").label("Wall - Floor");
    model.component("comp1").physics("rac").feature("wall6").selection().named("geom1_sel4");
    model.component("comp1").physics("rac").feature("wall6").set("s", "s_floor(f0)");
    model.component("comp1").physics("rac").feature("wall6").set("alpha", "a_floor(f0)");
    model.component("comp1").physics("rac").create("wall7", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall7").label("Wall - Ceiling");
    model.component("comp1").physics("rac").feature("wall7").selection().named("geom1_sel5");
    model.component("comp1").physics("rac").feature("wall7").set("s", "s_ceiling(f0)");
    model.component("comp1").physics("rac").feature("wall7").set("alpha", "a_ceiling(f0)");
    model.component("comp1").physics("rac").create("wall8", "RayAcousticsWall", 2);
    model.component("comp1").physics("rac").feature("wall8").label("Wall - Structured Plaster");
    model.component("comp1").physics("rac").feature("wall8").selection().named("geom1_sel6");
    model.component("comp1").physics("rac").feature("wall8").set("s", "s_structuredplaster(f0)");
    model.component("comp1").physics("rac").feature("wall8").set("alpha", "a_structuredplaster(f0)");
    model.component("comp1").physics("rac").create("swd1", "SourceWithDirectivity", -1);
    model.component("comp1").physics("rac").feature("swd1").set("q0", new String[]{"x_s1", "y_s1", "z_s1"});
    model.component("comp1").physics("rac").feature("swd1").setIndex("Nw", "Nrays", 0);
    model.component("comp1").physics("rac").feature("swd1").set("Directivity", "SpecifyTotalSourcePower");
    model.component("comp1").physics("rac").feature("swd1").set("Psrc", "P0");
    model.component("comp1").physics("rac").feature().duplicate("swd2", "swd1");
    model.component("comp1").physics("rac").feature("swd2").set("q0", new String[]{"x_s2", "y_s2", "z_s2"});
    model.component("comp1").physics("rac").create("rt1", "RayTermination", -1);
    model.component("comp1").physics("rac").feature("rt1")
         .set("SpatialExtentsOfRayPropagation", "BoundingBoxFromGeometry");
    model.component("comp1").physics("rac").feature("rt1").set("AdditionalTerminationCriteria", "Power");
    model.component("comp1").physics("rac").feature("rt1").set("Qth", "P0/Nrays*1e-7");
    model.component("comp1").physics().copy("rac2", "rac");
    model.component("comp1").physics("rac2").prop("OnlyStoreAccumulatedVariables")
         .setIndex("OnlyStoreAccumulatedVariables", 1, 0);
    model.component("comp1").physics("rac2").create("rec1", "Receiver", 2);
    model.component("comp1").physics("rac2").feature("rec1").selection().named("geom1_sph1_bnd");
    model.component("comp1").physics("rac2").create("rec2", "Receiver", 2);
    model.component("comp1").physics("rac2").feature("rec2").selection().named("geom1_sph2_bnd");
    model.component("comp1").physics("rac2").create("rec3", "Receiver", 2);
    model.component("comp1").physics("rac2").feature("rec3").selection().named("geom1_sph3_bnd");
    model.component("comp1").physics("rac2").create("rec4", "Receiver", 2);
    model.component("comp1").physics("rac2").feature("rec4").selection().named("geom1_sph4_bnd");
    model.component("comp1").physics("rac2").create("rec5", "Receiver", 2);
    model.component("comp1").physics("rac2").feature("rec5").selection().named("geom1_sph5_bnd");

    model.component("comp1").mesh("mesh1").autoMeshSize(9);
    model.component("comp1").mesh("mesh1").automatic(false);
    model.component("comp1").mesh("mesh1").feature("ftri1").selection().all();
    model.component("comp1").mesh("mesh1").feature("ftri1").create("size1", "Size");
    model.component("comp1").mesh("mesh1").feature("ftri1").feature("size1").selection().named("geom1_csel1_bnd");
    model.component("comp1").mesh("mesh1").feature("ftri1").feature("size1").set("custom", true);
    model.component("comp1").mesh("mesh1").feature("ftri1").feature("size1").set("hmaxactive", true);
    model.component("comp1").mesh("mesh1").feature("ftri1").feature("size1").set("hmax", "r_rec/3");
    model.component("comp1").mesh("mesh1").run();

    model.study("std1").label("Study 1 - Single Frequency");
    model.study("std1").feature("rtrac").set("tunit", "s");
    model.study("std1").feature("rtrac").set("tlist", "0 2");
    model.study("std1").feature("rtrac").set("useadvanceddisable", true);
    model.study("std1").feature("rtrac").set("disabledphysics", new String[]{"rac/swd2"});
    model.study("std1").feature("rtrac").setSolveFor("/physics/rac2", false);
    model.study("std1").feature("rtrac").set("disabledphysics", new String[]{"rac/swd2", "rac2"});
    model.study("std1").createAutoSequences("all");

    model.sol("sol1").runAll();

    model.result().dataset().create("ray1", "Ray");
    model.result().dataset("ray1").set("solution", "sol1");
    model.result().dataset("ray1").set("posdof", new String[]{"comp1.qx", "comp1.qy", "comp1.qz"});
    model.result().dataset("ray1").set("geom", "geom1");
    model.result().dataset("ray1").set("rgeom", "pgeom_rac");
    model.result().dataset("ray1").set("rgeomspec", "fromphysics");
    model.result().dataset("ray1").set("physicsinterface", "rac");
    model.result().create("pg1", "PlotGroup3D");
    model.result("pg1").set("data", "ray1");
    model.result("pg1").label("Ray Trajectories (rac)");
    model.result("pg1").set("showlegendsunit", true);
    model.result("pg1").create("rtrj1", "RayTrajectories");
    model.result("pg1").feature("rtrj1").set("linetype", "line");
    model.result("pg1").feature("rtrj1").set("extrasteps", "none");
    model.result("pg1").feature("rtrj1").create("col1", "Color");
    model.result("pg1").feature("rtrj1").feature("col1").set("expr", "t");
    model.result("pg1").feature("rtrj1").create("filt1", "RayTrajectoriesFilter");
    model.result("pg1").run();
    model.result("pg1").setIndex("looplevel", "interp", 0);
    model.result("pg1").set("interp", new double[]{0.01});
    model.result("pg1").run();
    model.result("pg1").feature("rtrj1").set("linetype", "none");
    model.result("pg1").feature("rtrj1").set("pointtype", "point");
    model.result("pg1").run();
    model.result("pg1").feature("rtrj1").feature("col1").set("expr", "rac.Q");
    model.result("pg1").run();
    model.result("pg1").run();
    model.result("pg1").set("interp", new double[]{0.02});
    model.result("pg1").run();
    model.result("pg1").set("interp", new double[]{0.03});
    model.result("pg1").run();
    model.result("pg1").set("interp", new double[]{0.04});
    model.result("pg1").run();

    model.study().create("std2");
    model.study("std2").create("rtrac", "RayTracing");
    model.study("std2").label("Study 2 - Source 1");
    model.study("std2").create("param", "Parametric");
    model.study("std2").feature("param").setIndex("pname", "c0", 0);
    model.study("std2").feature("param").setIndex("plistarr", "", 0);
    model.study("std2").feature("param").setIndex("punit", "m/s", 0);
    model.study("std2").feature("param").setIndex("pname", "c0", 0);
    model.study("std2").feature("param").setIndex("plistarr", "", 0);
    model.study("std2").feature("param").setIndex("punit", "m/s", 0);
    model.study("std2").feature("param").setIndex("pname", "f0", 0);
    model.study("std2").feature("param").setIndex("plistarr", "", 0);
    model.study("std2").feature("param").setIndex("punit", "Hz", 0);
    model.study("std2").feature("param")
         .setIndex("plistarr", "{100, 125, 160, 200, 250, 315, 400, 500, 630, 800, 1e3, 1.25e3, 1.6e3, 2e3, 2.5e3, 3.15e3, 4e3, 5e3}", 0);
    model.study("std2").feature("rtrac").set("tunit", "s");
    model.study("std2").feature("rtrac").set("tlist", "0 2");
    model.study("std2").feature("rtrac").set("useadvanceddisable", true);
    model.study("std2").feature("rtrac").setSolveFor("/physics/rac", false);
    model.study("std2").feature("rtrac").set("disabledphysics", new String[]{"rac", "rac2/swd2"});
    model.study().create("std3");
    model.study("std3").create("rtrac", "RayTracing");
    model.study("std3").label("Study 3 - Source 2");
    model.study("std3").create("param", "Parametric");
    model.study("std3").feature("param").setIndex("pname", "c0", 0);
    model.study("std3").feature("param").setIndex("plistarr", "", 0);
    model.study("std3").feature("param").setIndex("punit", "m/s", 0);
    model.study("std3").feature("param").setIndex("pname", "c0", 0);
    model.study("std3").feature("param").setIndex("plistarr", "", 0);
    model.study("std3").feature("param").setIndex("punit", "m/s", 0);
    model.study("std3").feature("param").setIndex("pname", "f0", 0);
    model.study("std3").feature("param").setIndex("plistarr", "", 0);
    model.study("std3").feature("param").setIndex("punit", "Hz", 0);
    model.study("std3").feature("param")
         .setIndex("plistarr", "{100, 125, 160, 200, 250, 315, 400, 500, 630, 800, 1e3, 1.25e3, 1.6e3, 2e3, 2.5e3, 3.15e3, 4e3, 5e3}", 0);
    model.study("std3").feature("rtrac").set("tunit", "s");
    model.study("std3").feature("rtrac").set("tlist", "0 2");
    model.study("std3").feature("rtrac").set("useadvanceddisable", true);
    model.study("std3").feature("rtrac").setSolveFor("/physics/rac", false);
    model.study("std3").feature("rtrac").set("disabledphysics", new String[]{"rac", "rac2/swd1"});

    model.result().setOnlyPlotWhenRequested(true);

    model.study().create("std4");
    model.study("std4").create("ref", "StudyReference");
    model.study("std4").feature("ref").set("studyref", "std2");
    model.study("std4").create("ref2", "StudyReference");
    model.study("std4").feature("ref2").set("studyref", "std3");
    model.study("std4").createAutoSequences("all");

    model.sol().create("sol5");
    model.sol("sol5").study("std2");
    model.sol("sol5").label("Parametric Solutions 1");

    model.batch("p1").feature("so1").set("psol", "sol5");

    model.sol().create("sol6");
    model.sol("sol6").study("std3");
    model.sol("sol6").label("Parametric Solutions 2");

    model.batch("p2").feature("so1").set("psol", "sol6");
    model.batch("s1").run("compute");

    model.result().dataset().create("ray2", "Ray");
    model.result().dataset("ray2").set("solution", "sol6");
    model.result().dataset("ray2").set("posdof", new String[]{"comp1.q2x", "comp1.q2y", "comp1.q2z"});
    model.result().dataset("ray2").set("geom", "geom1");
    model.result().dataset("ray2").set("rgeom", "pgeom_rac2");
    model.result().dataset("ray2").set("rgeomspec", "fromphysics");
    model.result().dataset("ray2").set("physicsinterface", "rac2");
    model.result().dataset().create("re1", "Receiver3D");
    model.result().dataset("re1").set("data", "ray2");
    model.result().dataset("re1").set("receiverselection", "comp1.rac2.rec1");
    model.result().dataset().create("re2", "Receiver3D");
    model.result().dataset("re2").set("data", "ray2");
    model.result().dataset("re2").set("receiverselection", "comp1.rac2.rec2");
    model.result().dataset().create("re3", "Receiver3D");
    model.result().dataset("re3").set("data", "ray2");
    model.result().dataset("re3").set("receiverselection", "comp1.rac2.rec3");
    model.result().dataset().create("re4", "Receiver3D");
    model.result().dataset("re4").set("data", "ray2");
    model.result().dataset("re4").set("receiverselection", "comp1.rac2.rec4");
    model.result().dataset().create("re5", "Receiver3D");
    model.result().dataset("re5").set("data", "ray2");
    model.result().dataset("re5").set("receiverselection", "comp1.rac2.rec5");
    model.result().dataset().create("ray3", "Ray");
    model.result().dataset("ray3").set("solution", "sol5");
    model.result().dataset("ray3").set("posdof", new String[]{"comp1.q2x", "comp1.q2y", "comp1.q2z"});
    model.result().dataset("ray3").set("geom", "geom1");
    model.result().dataset("ray3").set("rgeom", "pgeom_rac2");
    model.result().dataset("ray3").set("rgeomspec", "fromphysics");
    model.result().dataset("ray3").set("physicsinterface", "rac2");
    model.result().dataset().create("re6", "Receiver3D");
    model.result().dataset("re6").set("data", "ray3");
    model.result().dataset("re6").set("receiverselection", "comp1.rac2.rec1");
    model.result().dataset().create("re7", "Receiver3D");
    model.result().dataset("re7").set("data", "ray3");
    model.result().dataset("re7").set("receiverselection", "comp1.rac2.rec2");
    model.result().dataset().create("re8", "Receiver3D");
    model.result().dataset("re8").set("data", "ray3");
    model.result().dataset("re8").set("receiverselection", "comp1.rac2.rec3");
    model.result().dataset().create("re9", "Receiver3D");
    model.result().dataset("re9").set("data", "ray3");
    model.result().dataset("re9").set("receiverselection", "comp1.rac2.rec4");
    model.result().dataset().create("re10", "Receiver3D");
    model.result().dataset("re10").set("data", "ray3");
    model.result().dataset("re10").set("receiverselection", "comp1.rac2.rec5");
    model.result().dataset("ray2").set("solution", "sol5");
    model.result().dataset("ray3").set("solution", "sol6");
    model.result().dataset("re1").label("Receiver 3D 1_1");
    model.result().dataset("re2").label("Receiver 3D 1_2");
    model.result().dataset("re3").label("Receiver 3D 1_3");
    model.result().dataset("re4").label("Receiver 3D 1_4");
    model.result().dataset("re5").label("Receiver 3D 1_5");
    model.result().dataset("re6").label("Receiver 3D 2_1");
    model.result().dataset("re7").label("Receiver 3D 2_2");
    model.result().dataset("re8").label("Receiver 3D 2_3");
    model.result().dataset("re9").label("Receiver 3D 2_4");
    model.result().dataset("re10").label("Receiver 3D 2_5");
    model.result().create("pg2", "PlotGroup1D");
    model.result("pg2").label("Impulse response 1_1");
    model.result("pg2").set("data", "re1");
    model.result("pg2").set("legendpos", "lowerleft");
    model.result("pg2").create("imp1", "ImpulseResponse");
    model.result("pg2").feature("imp1").set("markerpos", "datapoints");
    model.result("pg2").feature("imp1").set("linewidth", "preference");
    model.result("pg2").feature("imp1").set("freqtype", "octave3");
    model.result("pg2").feature("imp1").set("legend", true);
    model.result("pg2").feature("imp1").create("enyd1", "EnergyDecay");
    model.result("pg2").feature("imp1").feature("enyd1").set("bandtype", "indiband");
    model.result("pg2").feature("imp1").feature("enyd1").set("plot", "leveldecay");
    model.result("pg2").feature("imp1").feature("enyd1").set("c50", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("tr", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("ts", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("t30", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("t60", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("snr", false);
    model.result("pg2").feature("imp1").feature("enyd1").set("sti", false);
    model.result("pg2").run();
    model.result("pg2").feature("imp1").feature("enyd1").set("bandfreq", "All");
    model.result("pg2").run();
    model.result().duplicate("pg3", "pg2");
    model.result("pg3").label("Impulse response 1_2");
    model.result("pg3").set("data", "re2");
    model.result("pg3").run();
    model.result().duplicate("pg4", "pg3");
    model.result("pg4").label("Impulse response 1_3");
    model.result("pg4").set("data", "re3");
    model.result("pg4").run();
    model.result().duplicate("pg5", "pg4");
    model.result("pg5").label("Impulse response 1_4");
    model.result("pg5").set("data", "re4");
    model.result("pg5").run();
    model.result().duplicate("pg6", "pg5");
    model.result("pg6").label("Impulse response 1_5");
    model.result("pg6").set("data", "re5");
    model.result("pg6").run();
    model.result().duplicate("pg7", "pg6");
    model.result("pg7").label("Impulse response 2_1");
    model.result("pg7").set("data", "re6");
    model.result("pg7").run();
    model.result().duplicate("pg8", "pg7");
    model.result("pg8").label("Impulse response 2_2");
    model.result("pg8").set("data", "re7");
    model.result("pg8").run();
    model.result().duplicate("pg9", "pg8");
    model.result("pg9").label("Impulse response 2_3");
    model.result("pg9").set("data", "re8");
    model.result("pg9").run();
    model.result().duplicate("pg10", "pg9");
    model.result("pg10").label("Impulse response 2_4");
    model.result("pg10").set("data", "re9");
    model.result("pg10").run();
    model.result().duplicate("pg11", "pg10");
    model.result("pg11").label("Impulse response 2_5");
    model.result("pg11").set("data", "re10");
    model.result("pg11").run();

    model.nodeGroup().create("grp1", "Results");
    model.nodeGroup("grp1").set("type", "plotgroup");
    model.nodeGroup("grp1").placeAfter("plotgroup", "pg1");
    model.nodeGroup("grp1").add("plotgroup", "pg2");
    model.nodeGroup("grp1").add("plotgroup", "pg3");
    model.nodeGroup("grp1").add("plotgroup", "pg4");
    model.nodeGroup("grp1").add("plotgroup", "pg5");
    model.nodeGroup("grp1").add("plotgroup", "pg6");
    model.nodeGroup("grp1").add("plotgroup", "pg7");
    model.nodeGroup("grp1").add("plotgroup", "pg8");

    return model;
  }

  public static Model run2(Model model) {
    model.nodeGroup("grp1").add("plotgroup", "pg9");
    model.nodeGroup("grp1").add("plotgroup", "pg10");
    model.nodeGroup("grp1").add("plotgroup", "pg11");
    model.nodeGroup("grp1").label("Impulse responses");

    model.result().table("egydc1").label("Objective Quality Metrics 1_1");
    model.result().table("egydc2").label("Objective Quality Metrics 1_2");
    model.result().table("egydc3").label("Objective Quality Metrics 1_3");
    model.result().table("egydc4").label("Objective Quality Metrics 1_4");
    model.result().table("egydc5").label("Objective Quality Metrics 1_5");
    model.result().table("egydc6").label("Objective Quality Metrics 2_1");
    model.result().table("egydc7").label("Objective Quality Metrics 2_2");
    model.result().table("egydc8").label("Objective Quality Metrics 2_3");
    model.result().table("egydc9").label("Objective Quality Metrics 2_4");
    model.result().table("egydc10").label("Objective Quality Metrics 2_5");

    model.func().create("int13", "Interpolation");
    model.func("int13").set("source", "resultTable");
    model.func("int13").setEntry("columnType", "col3", "value");
    model.func("int13").setEntry("columnType", "col4", "value");
    model.func("int13").setEntry("columnType", "col5", "value");
    model.func("int13").setIndex("argunit", "Hz", 0);
    model.func("int13").setEntry("funcnames", "col2", "D50_11");
    model.func("int13").setIndex("fununit", "%", 0);
    model.func("int13").setEntry("funcnames", "col3", "C80_11");
    model.func("int13").setIndex("fununit", "dB", 1);
    model.func("int13").setEntry("funcnames", "col4", "EDT_11");
    model.func("int13").setIndex("fununit", "s", 2);
    model.func("int13").setEntry("funcnames", "col5", "T20_11");
    model.func("int13").setIndex("fununit", "s", 3);
    model.func("int13").set("interp", "neighbor");
    model.func().create("int14", "Interpolation");
    model.func("int14").set("source", "resultTable");
    model.func("int14").set("resultTable", "egydc2");
    model.func("int14").setEntry("columnType", "col3", "value");
    model.func("int14").setEntry("columnType", "col4", "value");
    model.func("int14").setEntry("columnType", "col5", "value");
    model.func("int14").setIndex("argunit", "Hz", 0);
    model.func("int14").setEntry("funcnames", "col2", "D50_12");
    model.func("int14").setIndex("fununit", "%", 0);
    model.func("int14").setEntry("funcnames", "col3", "C80_12");
    model.func("int14").setIndex("fununit", "dB", 1);
    model.func("int14").setEntry("funcnames", "col4", "EDT_12");
    model.func("int14").setIndex("fununit", "s", 2);
    model.func("int14").setEntry("funcnames", "col5", "T20_12");
    model.func("int14").setIndex("fununit", "s", 3);
    model.func("int14").set("interp", "neighbor");
    model.func().create("int15", "Interpolation");
    model.func("int15").set("source", "resultTable");
    model.func("int15").set("resultTable", "egydc3");
    model.func("int15").setEntry("columnType", "col3", "value");
    model.func("int15").setEntry("columnType", "col4", "value");
    model.func("int15").setEntry("columnType", "col5", "value");
    model.func("int15").setIndex("argunit", "Hz", 0);
    model.func("int15").setEntry("funcnames", "col2", "D50_13");
    model.func("int15").setIndex("fununit", "%", 0);
    model.func("int15").setEntry("funcnames", "col3", "C80_13");
    model.func("int15").setIndex("fununit", "dB", 1);
    model.func("int15").setEntry("funcnames", "col4", "EDT_13");
    model.func("int15").setIndex("fununit", "s", 2);
    model.func("int15").setEntry("funcnames", "col5", "T20_13");
    model.func("int15").setIndex("fununit", "s", 3);
    model.func("int15").set("interp", "neighbor");
    model.func().create("int16", "Interpolation");
    model.func("int16").set("source", "resultTable");
    model.func("int16").set("resultTable", "egydc4");
    model.func("int16").setEntry("columnType", "col3", "value");
    model.func("int16").setEntry("columnType", "col4", "value");
    model.func("int16").setEntry("columnType", "col5", "value");
    model.func("int16").setIndex("argunit", "Hz", 0);
    model.func("int16").setEntry("funcnames", "col2", "D50_14");
    model.func("int16").setIndex("fununit", "%", 0);
    model.func("int16").setEntry("funcnames", "col3", "C80_14");
    model.func("int16").setIndex("fununit", "dB", 1);
    model.func("int16").setEntry("funcnames", "col4", "EDT_14");
    model.func("int16").setIndex("fununit", "s", 2);
    model.func("int16").setEntry("funcnames", "col5", "T20_14");
    model.func("int16").setIndex("fununit", "s", 3);
    model.func("int16").set("interp", "neighbor");
    model.func().create("int17", "Interpolation");
    model.func("int17").set("source", "resultTable");
    model.func("int17").set("resultTable", "egydc5");
    model.func("int17").setEntry("columnType", "col3", "value");
    model.func("int17").setEntry("columnType", "col4", "value");
    model.func("int17").setEntry("columnType", "col5", "value");
    model.func("int17").setIndex("argunit", "Hz", 0);
    model.func("int17").setEntry("funcnames", "col2", "D50_15");
    model.func("int17").setIndex("fununit", "%", 0);
    model.func("int17").setEntry("funcnames", "col3", "C80_15");
    model.func("int17").setIndex("fununit", "dB", 1);
    model.func("int17").setEntry("funcnames", "col4", "EDT_15");
    model.func("int17").setIndex("fununit", "s", 2);
    model.func("int17").setEntry("funcnames", "col5", "T20_15");
    model.func("int17").setIndex("fununit", "s", 3);
    model.func("int17").set("interp", "neighbor");
    model.func().create("int18", "Interpolation");
    model.func("int18").set("source", "resultTable");
    model.func("int18").set("resultTable", "egydc6");
    model.func("int18").setEntry("columnType", "col3", "value");
    model.func("int18").setEntry("columnType", "col4", "value");
    model.func("int18").setEntry("columnType", "col5", "value");
    model.func("int18").setIndex("argunit", "Hz", 0);
    model.func("int18").setEntry("funcnames", "col2", "D50_21");
    model.func("int18").setIndex("fununit", "%", 0);
    model.func("int18").setEntry("funcnames", "col3", "C80_21");
    model.func("int18").setIndex("fununit", "dB", 1);
    model.func("int18").setEntry("funcnames", "col4", "EDT_21");
    model.func("int18").setIndex("fununit", "s", 2);
    model.func("int18").setEntry("funcnames", "col5", "T20_21");
    model.func("int18").setIndex("fununit", "s", 3);
    model.func("int18").set("interp", "neighbor");
    model.func().create("int19", "Interpolation");
    model.func("int19").set("source", "resultTable");
    model.func("int19").set("resultTable", "egydc7");
    model.func("int19").setEntry("columnType", "col3", "value");
    model.func("int19").setEntry("columnType", "col4", "value");
    model.func("int19").setEntry("columnType", "col5", "value");
    model.func("int19").setIndex("argunit", "Hz", 0);
    model.func("int19").setEntry("funcnames", "col2", "D50_22");
    model.func("int19").setIndex("fununit", "%", 0);
    model.func("int19").setEntry("funcnames", "col3", "C80_22");
    model.func("int19").setIndex("fununit", "dB", 1);
    model.func("int19").setEntry("funcnames", "col4", "EDT_22");
    model.func("int19").setIndex("fununit", "s", 2);
    model.func("int19").setEntry("funcnames", "col5", "T20_22");
    model.func("int19").setIndex("fununit", "s", 3);
    model.func("int19").set("interp", "neighbor");
    model.func().create("int20", "Interpolation");
    model.func("int20").set("source", "resultTable");
    model.func("int20").set("resultTable", "egydc8");
    model.func("int20").setEntry("columnType", "col3", "value");
    model.func("int20").setEntry("columnType", "col4", "value");
    model.func("int20").setEntry("columnType", "col5", "value");
    model.func("int20").setIndex("argunit", "Hz", 0);
    model.func("int20").setEntry("funcnames", "col2", "D50_23");
    model.func("int20").setIndex("fununit", "%", 0);
    model.func("int20").setEntry("funcnames", "col3", "C80_23");
    model.func("int20").setIndex("fununit", "dB", 1);
    model.func("int20").setEntry("funcnames", "col4", "EDT_23");
    model.func("int20").setIndex("fununit", "s", 2);
    model.func("int20").setEntry("funcnames", "col5", "T20_23");
    model.func("int20").setIndex("fununit", "s", 3);
    model.func("int20").set("interp", "neighbor");
    model.func().create("int21", "Interpolation");
    model.func("int21").set("source", "resultTable");
    model.func("int21").set("resultTable", "egydc9");
    model.func("int21").setEntry("columnType", "col3", "value");
    model.func("int21").setEntry("columnType", "col4", "value");
    model.func("int21").setEntry("columnType", "col5", "value");
    model.func("int21").setIndex("argunit", "Hz", 0);
    model.func("int21").setEntry("funcnames", "col2", "D50_24");
    model.func("int21").setIndex("fununit", "%", 0);
    model.func("int21").setEntry("funcnames", "col3", "C80_24");
    model.func("int21").setIndex("fununit", "dB", 1);
    model.func("int21").setEntry("funcnames", "col4", "EDT_24");
    model.func("int21").setIndex("fununit", "s", 2);
    model.func("int21").setEntry("funcnames", "col5", "T20_24");
    model.func("int21").setIndex("fununit", "s", 3);
    model.func("int21").set("interp", "neighbor");
    model.func().create("int22", "Interpolation");
    model.func("int22").set("source", "resultTable");
    model.func("int22").set("resultTable", "egydc10");
    model.func("int22").setEntry("columnType", "col3", "value");
    model.func("int22").setEntry("columnType", "col4", "value");
    model.func("int22").setEntry("columnType", "col5", "value");
    model.func("int22").setIndex("argunit", "Hz", 0);
    model.func("int22").setEntry("funcnames", "col2", "D50_25");
    model.func("int22").setIndex("fununit", "%", 0);
    model.func("int22").setEntry("funcnames", "col3", "C80_25");
    model.func("int22").setIndex("fununit", "dB", 1);
    model.func("int22").setEntry("funcnames", "col4", "EDT_25");
    model.func("int22").setIndex("fununit", "s", 2);
    model.func("int22").setEntry("funcnames", "col5", "T20_25");
    model.func("int22").setIndex("fununit", "s", 3);
    model.func("int22").set("interp", "neighbor");

    model.study().create("std5");
    model.study("std5").label("Study 5 - Empty for postprocessing");
    model.study("std5").setGenPlots(false);
    model.study("std5").create("param", "Parametric");
    model.study("std5").feature("param").setIndex("pname", "c0", 0);
    model.study("std5").feature("param").setIndex("plistarr", "", 0);
    model.study("std5").feature("param").setIndex("punit", "m/s", 0);
    model.study("std5").feature("param").setIndex("pname", "c0", 0);
    model.study("std5").feature("param").setIndex("plistarr", "", 0);
    model.study("std5").feature("param").setIndex("punit", "m/s", 0);
    model.study("std5").feature("param").setIndex("pname", "f0", 0);
    model.study("std5").feature("param").setIndex("plistarr", "", 0);
    model.study("std5").feature("param").setIndex("punit", "Hz", 0);
    model.study("std5").feature("param")
         .setIndex("plistarr", "{100, 125, 160, 200, 250, 315, 400, 500, 630, 800, 1e3, 1.25e3, 1.6e3, 2e3, 2.5e3, 3.15e3, 4e3, 5e3}", 0);
    model.study("std5").createAutoSequences("all");

    model.sol().create("sol44");
    model.sol("sol44").study("std5");
    model.sol("sol44").label("Parametric Solutions 3");

    model.batch("p3").feature("so1").set("psol", "sol44");
    model.batch("p3").run("compute");

    model.result().create("pg12", "PlotGroup1D");
    model.result("pg12").label("Early Decay Time EDT");
    model.result("pg12").set("data", "dset8");
    model.result("pg12").setIndex("looplevelinput", "first", 0);
    model.result("pg12").set("titletype", "manual");
    model.result("pg12").set("title", "Average over source-receiver pairs");
    model.result("pg12").set("xlabelactive", true);
    model.result("pg12").set("xlabel", "f (Hz)");
    model.result("pg12").set("ylabelactive", true);
    model.result("pg12").set("ylabel", "EDT (s)");
    model.result("pg12").set("axislimits", true);
    model.result("pg12").set("xmin", 95);
    model.result("pg12").set("xmax", 5250);
    model.result("pg12").set("ymin", 0);
    model.result("pg12").set("ymax", 3);
    model.result("pg12").set("xlog", true);
    model.result("pg12").create("glob1", "Global");
    model.result("pg12").feature("glob1").set("markerpos", "datapoints");
    model.result("pg12").feature("glob1").set("linewidth", "preference");
    model.result("pg12").feature("glob1").setIndex("expr", "EDT_meas(f0)", 0);
    model.result("pg12").feature("glob1").setIndex("unit", "s", 0);
    model.result("pg12").feature("glob1").setIndex("descr", "Interpolation 9", 0);
    model.result("pg12").feature("glob1")
         .setIndex("expr", "(EDT_11(f0)+EDT_12(f0)+EDT_13(f0)+EDT_14(f0)+EDT_15(f0)+EDT_21(f0)+EDT_22(f0)+EDT_23(f0)+EDT_24(f0)+EDT_25(f0))/10", 1);
    model.result("pg12").feature("glob1").setIndex("unit", "s", 1);
    model.result("pg12").feature("glob1").setIndex("descr", "", 1);
    model.result("pg12").feature("glob1").set("xdatasolnumtype", "level2");
    model.result("pg12").feature("glob1").set("linestyle", "dashed");
    model.result("pg12").feature("glob1").set("linemarker", "circle");
    model.result("pg12").feature("glob1").set("legendmethod", "manual");
    model.result("pg12").feature("glob1").setIndex("legends", "Measurement", 0);
    model.result("pg12").feature("glob1").setIndex("legends", "Calculation", 1);
    model.result("pg12").create("glob2", "Global");
    model.result("pg12").feature("glob2").set("markerpos", "datapoints");
    model.result("pg12").feature("glob2").set("linewidth", "preference");
    model.result("pg12").feature("glob2").setIndex("expr", "(1-3*0.05)*EDT_meas(f0)", 0);
    model.result("pg12").feature("glob2").setIndex("unit", "s", 0);
    model.result("pg12").feature("glob2").setIndex("descr", "", 0);
    model.result("pg12").feature("glob2").set("xdatasolnumtype", "level2");
    model.result("pg12").feature("glob2").set("linestyle", "dotted");
    model.result("pg12").feature("glob2").set("linecolor", "cyclereset");
    model.result("pg12").feature("glob2").set("legendmethod", "manual");
    model.result("pg12").feature("glob2").setIndex("legends", "3*JND interval", 0);
    model.result("pg12").create("glob3", "Global");
    model.result("pg12").feature("glob3").set("markerpos", "datapoints");
    model.result("pg12").feature("glob3").set("linewidth", "preference");
    model.result("pg12").feature("glob3").setIndex("expr", "(1+3*0.05)*EDT_meas(f0)", 0);
    model.result("pg12").feature("glob3").setIndex("unit", "s", 0);
    model.result("pg12").feature("glob3").setIndex("descr", "", 0);
    model.result("pg12").feature("glob3").set("xdatasolnumtype", "level2");
    model.result("pg12").feature("glob3").set("linestyle", "dotted");
    model.result("pg12").feature("glob3").set("linecolor", "cyclereset");
    model.result("pg12").feature("glob3").set("legend", false);
    model.result("pg12").run();
    model.result().duplicate("pg13", "pg12");
    model.result("pg13").label("Reverberation Time T20");
    model.result("pg13").set("ylabel", "T20 (s)");
    model.result("pg13").feature("glob1").setIndex("expr", "T20_meas(f0)", 0);
    model.result("pg13").feature("glob1").setIndex("unit", "s", 0);
    model.result("pg13").feature("glob1").setIndex("descr", "Interpolation 10", 0);
    model.result("pg13").feature("glob1")
         .setIndex("expr", "(T20_11(f0)+T20_12(f0)+T20_13(f0)+T20_14(f0)+T20_15(f0)+T20_21(f0)+T20_22(f0)+T20_23(f0)+T20_24(f0)+T20_25(f0))/10", 1);
    model.result("pg13").feature("glob1").setIndex("unit", "", 1);
    model.result("pg13").feature("glob1").setIndex("descr", "", 1);
    model.result("pg13").feature("glob2").setIndex("expr", "(1-3*0.05)*T20_meas(f0)", 0);
    model.result("pg13").feature("glob2").setIndex("unit", "s", 0);
    model.result("pg13").feature("glob2").setIndex("descr", "", 0);
    model.result("pg13").feature("glob3").setIndex("expr", "(1+3*0.05)*T20_meas(f0)", 0);
    model.result("pg13").feature("glob3").setIndex("unit", "s", 0);
    model.result("pg13").feature("glob3").setIndex("descr", "", 0);
    model.result("pg13").run();
    model.result().duplicate("pg14", "pg13");
    model.result("pg14").label("Clarity C80");
    model.result("pg14").set("ylabel", "C80 (dB)");
    model.result("pg14").set("ymin", -5);
    model.result("pg14").set("ymax", 8);
    model.result("pg14").set("legendpos", "upperleft");
    model.result("pg14").feature("glob1").setIndex("expr", "C80_meas(f0)", 0);
    model.result("pg14").feature("glob1").setIndex("unit", "dB", 0);
    model.result("pg14").feature("glob1").setIndex("descr", "Interpolation 11", 0);
    model.result("pg14").feature("glob1")
         .setIndex("expr", "(C80_11(f0)+C80_12(f0)+C80_13(f0)+C80_14(f0)+C80_15(f0)+C80_21(f0)+C80_22(f0)+C80_23(f0)+C80_24(f0)+C80_25(f0))/10", 1);
    model.result("pg14").feature("glob1").setIndex("unit", "dB", 1);
    model.result("pg14").feature("glob1").setIndex("descr", "", 1);
    model.result("pg14").feature("glob2").setIndex("expr", "C80_meas(f0)-3*1", 0);
    model.result("pg14").feature("glob2").setIndex("unit", "dB", 0);
    model.result("pg14").feature("glob2").setIndex("descr", "", 0);
    model.result("pg14").feature("glob3").setIndex("expr", "C80_meas(f0)+3*1", 0);
    model.result("pg14").feature("glob3").setIndex("unit", "dB", 0);
    model.result("pg14").feature("glob3").setIndex("descr", "", 0);
    model.result("pg14").run();
    model.result().duplicate("pg15", "pg14");
    model.result("pg15").label("Definition D");
    model.result("pg15").set("ylabel", "D (%)");
    model.result("pg15").set("ymin", 0);
    model.result("pg15").set("ymax", 100);
    model.result("pg15").feature("glob1").setIndex("expr", "D50_meas(f0)", 0);
    model.result("pg15").feature("glob1").setIndex("unit", "%", 0);
    model.result("pg15").feature("glob1").setIndex("descr", "Interpolation 12", 0);
    model.result("pg15").feature("glob1")
         .setIndex("expr", "100*(D50_11(f0)+D50_12(f0)+D50_13(f0)+D50_14(f0)+D50_15(f0)+D50_21(f0)+D50_22(f0)+D50_23(f0)+D50_24(f0)+D50_25(f0))/10", 1);
    model.result("pg15").feature("glob1").setIndex("unit", "", 1);
    model.result("pg15").feature("glob1").setIndex("descr", "", 1);
    model.result("pg15").feature("glob2").setIndex("expr", "D50_meas(f0)-3*0.05", 0);
    model.result("pg15").feature("glob2").setIndex("unit", "%", 0);
    model.result("pg15").feature("glob2").setIndex("descr", "", 0);
    model.result("pg15").feature("glob3").setIndex("expr", "D50_meas(f0)+3*0.05", 0);
    model.result("pg15").feature("glob3").setIndex("unit", "%", 0);
    model.result("pg15").feature("glob3").setIndex("descr", "", 0);
    model.result("pg15").run();

    model.title("Chamber Music Hall");

    model
         .description("In this model, the acoustics of the Small Hall in the Konzerthaus Berlin is simulated with ray tracing. A full study of the room is performed in 1/3-octave bands with 10\u00a0pairs of source\u2013receiver positions. The room acoustic parameters are derived from the calculated impulse responses, and the results are compared with measurement data from a round robin study on room acoustic simulations.");

    return model;
  }

  public static void main(String[] args) {
    Model model = run();
    run2(model);
  }

}
