/*
 * This script contains the language-specific data used by searchtools.js,
 * namely the set of stopwords, stemmer, scorer and splitter.
 */

const stopwords = new Set(["ad", "af", "alle", "alt", "anden", "at", "blev", "blive", "bliver", "da", "de", "dem", "den", "denne", "der", "deres", "det", "dette", "dig", "din", "disse", "dog", "du", "efter", "eller", "en", "end", "er", "et", "for", "fra", "ham", "han", "hans", "har", "havde", "have", "hende", "hendes", "her", "hos", "hun", "hvad", "hvis", "hvor", "i", "ikke", "ind", "jeg", "jer", "jo", "kunne", "man", "mange", "med", "meget", "men", "mig", "min", "mine", "mit", "mod", "ned", "noget", "nogle", "nu", "n\u00e5r", "og", "ogs\u00e5", "om", "op", "os", "over", "p\u00e5", "selv", "sig", "sin", "sine", "sit", "skal", "skulle", "som", "s\u00e5dan", "thi", "til", "ud", "under", "var", "vi", "vil", "ville", "vor", "v\u00e6re", "v\u00e6ret"]);
window.stopwords = stopwords;  // Export to global scope


/* Non-minified versions are copied as separate JavaScript files, if available */
BaseStemmer=function(){this.current="",this.cursor=0,this.limit=0,this.limit_backward=0,this.bra=0,this.ket=0,this.setCurrent=function(t){this.current=t,this.cursor=0,this.limit=this.current.length,this.limit_backward=0,this.bra=this.cursor,this.ket=this.limit},this.getCurrent=function(){return this.current},this.copy_from=function(t){this.current=t.current,this.cursor=t.cursor,this.limit=t.limit,this.limit_backward=t.limit_backward,this.bra=t.bra,this.ket=t.ket},this.in_grouping=function(t,r,i){return!(this.cursor>=this.limit||i<(i=this.current.charCodeAt(this.cursor))||i<r||0==(t[(i-=r)>>>3]&1<<(7&i))||(this.cursor++,0))},this.go_in_grouping=function(t,r,i){for(;this.cursor<this.limit;){var s=this.current.charCodeAt(this.cursor);if(i<s||s<r)return!0;if(0==(t[(s-=r)>>>3]&1<<(7&s)))return!0;this.cursor++}return!1},this.in_grouping_b=function(t,r,i){return!(this.cursor<=this.limit_backward||i<(i=this.current.charCodeAt(this.cursor-1))||i<r||0==(t[(i-=r)>>>3]&1<<(7&i))||(this.cursor--,0))},this.go_in_grouping_b=function(t,r,i){for(;this.cursor>this.limit_backward;){var s=this.current.charCodeAt(this.cursor-1);if(i<s||s<r)return!0;if(0==(t[(s-=r)>>>3]&1<<(7&s)))return!0;this.cursor--}return!1},this.out_grouping=function(t,r,i){return!(this.cursor>=this.limit)&&(i<(i=this.current.charCodeAt(this.cursor))||i<r||0==(t[(i-=r)>>>3]&1<<(7&i)))&&(this.cursor++,!0)},this.go_out_grouping=function(t,r,i){for(;this.cursor<this.limit;){var s=this.current.charCodeAt(this.cursor);if(s<=i&&r<=s&&0!=(t[(s-=r)>>>3]&1<<(7&s)))return!0;this.cursor++}return!1},this.out_grouping_b=function(t,r,i){return!(this.cursor<=this.limit_backward)&&(i<(i=this.current.charCodeAt(this.cursor-1))||i<r||0==(t[(i-=r)>>>3]&1<<(7&i)))&&(this.cursor--,!0)},this.go_out_grouping_b=function(t,r,i){for(;this.cursor>this.limit_backward;){var s=this.current.charCodeAt(this.cursor-1);if(s<=i&&r<=s&&0!=(t[(s-=r)>>>3]&1<<(7&s)))return!0;this.cursor--}return!1},this.eq_s=function(t){return!(this.limit-this.cursor<t.length||this.current.slice(this.cursor,this.cursor+t.length)!=t||(this.cursor+=t.length,0))},this.eq_s_b=function(t){return!(this.cursor-this.limit_backward<t.length||this.current.slice(this.cursor-t.length,this.cursor)!=t||(this.cursor-=t.length,0))},this.find_among=function(t){for(var r=0,i=t.length,s=this.cursor,h=this.limit,e=0,n=0,c=!1;;){for(var u=r+(i-r>>>1),o=0,a=e<n?e:n,l=t[u],f=a;f<l[0].length;f++){if(s+a==h){o=-1;break}if(0!=(o=this.current.charCodeAt(s+a)-l[0].charCodeAt(f)))break;a++}if(o<0?(i=u,n=a):(r=u,e=a),i-r<=1){if(0<r)break;if(i==r)break;if(c)break;c=!0}}do{if(e>=(l=t[r])[0].length){if(this.cursor=s+l[0].length,l.length<4)return l[2];var g=l[3](this);if(this.cursor=s+l[0].length,g)return l[2]}}while(0<=(r=l[1]));return 0},this.find_among_b=function(t){for(var r=0,i=t.length,s=this.cursor,h=this.limit_backward,e=0,n=0,c=!1;;){for(var u,o=r+(i-r>>1),a=0,l=e<n?e:n,f=(u=t[o])[0].length-1-l;0<=f;f--){if(s-l==h){a=-1;break}if(0!=(a=this.current.charCodeAt(s-1-l)-u[0].charCodeAt(f)))break;l++}if(a<0?(i=o,n=l):(r=o,e=l),i-r<=1){if(0<r)break;if(i==r)break;if(c)break;c=!0}}do{if(e>=(u=t[r])[0].length){if(this.cursor=s-u[0].length,u.length<4)return u[2];var g=u[3](this);if(this.cursor=s-u[0].length,g)return u[2]}}while(0<=(r=u[1]));return 0},this.replace_s=function(t,r,i){var s=i.length-(r-t);return this.current=this.current.slice(0,t)+i+this.current.slice(r),this.limit+=s,this.cursor>=r?this.cursor+=s:this.cursor>t&&(this.cursor=t),s},this.slice_check=function(){return!(this.bra<0||this.bra>this.ket||this.ket>this.limit||this.limit>this.current.length)},this.slice_from=function(t){var r=!1;return this.slice_check()&&(this.replace_s(this.bra,this.ket,t),r=!0),r},this.slice_del=function(){return this.slice_from("")},this.insert=function(t,r,i){r=this.replace_s(t,r,i);t<=this.bra&&(this.bra+=r),t<=this.ket&&(this.ket+=r)},this.slice_to=function(){var t="";return t=this.slice_check()?this.current.slice(this.bra,this.ket):t},this.assign_to=function(){return this.current.slice(0,this.limit)}};
var DanishStemmer=function(){var s=new BaseStemmer,c=[["hed",-1,1],["ethed",0,1],["ered",-1,1],["e",-1,1],["erede",3,1],["ende",3,1],["erende",5,1],["ene",3,1],["erne",3,1],["ere",3,1],["en",-1,1],["heden",10,1],["eren",10,1],["er",-1,1],["heder",13,1],["erer",13,1],["s",-1,2],["heds",16,1],["es",16,1],["endes",18,1],["erendes",19,1],["enes",18,1],["ernes",18,1],["eres",18,1],["ens",16,1],["hedens",24,1],["erens",24,1],["ers",16,1],["ets",16,1],["erets",28,1],["et",-1,1],["eret",30,1]],e=[["gd",-1,-1],["dt",-1,-1],["gt",-1,-1],["kt",-1,-1]],t=[["ig",-1,1],["lig",0,1],["elig",1,1],["els",-1,1],["løst",-1,2]],a=[119,223,119,1],o=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],u=[239,254,42,3,0,0,0,0,0,0,0,0,0,0,0,0,16],l=0,m=0,_="";function n(){var r,i=s.limit-s.cursor;s.cursor<m||(r=s.limit_backward,s.limit_backward=m,s.ket=s.cursor,0==s.find_among_b(e)?s.limit_backward=r:(s.bra=s.cursor,s.limit_backward=r,s.cursor=s.limit-i,s.cursor<=s.limit_backward||(s.cursor--,s.bra=s.cursor,s.slice_del())))}this.stem=function(){var r=s.cursor,i=(m=s.limit,e=s.cursor,(i=s.cursor+3)>s.limit||(s.cursor=i,l=s.cursor,s.cursor=e,s.go_out_grouping(o,97,248)&&(s.cursor++,s.go_in_grouping(o,97,248))&&(s.cursor++,m=s.cursor,l<=m||(m=l))),s.cursor=r,s.limit_backward=s.cursor,s.cursor=s.limit,s.limit-s.cursor),e=((()=>{var r;if(!(s.cursor<m)){var i=s.limit_backward;if(s.limit_backward=m,s.ket=s.cursor,0==(r=s.find_among_b(c)))s.limit_backward=i;else switch(s.bra=s.cursor,s.limit_backward=i,r){case 1:if(s.slice_del())break;return;case 2:if(!s.in_grouping_b(u,97,229))return;if(s.slice_del())break}}})(),s.cursor=s.limit-i,s.limit-s.cursor),r=(n(),s.cursor=s.limit-e,s.limit-s.cursor),i=((()=>{var r,i=s.limit-s.cursor;if(s.ket=s.cursor,(!s.eq_s_b("st")||(s.bra=s.cursor,!s.eq_s_b("ig"))||s.slice_del())&&(s.cursor=s.limit-i,!(s.cursor<m))){i=s.limit_backward;if(s.limit_backward=m,s.ket=s.cursor,0==(r=s.find_among_b(t)))s.limit_backward=i;else switch(s.bra=s.cursor,s.limit_backward=i,r){case 1:if(!s.slice_del())return;var e=s.limit-s.cursor;n(),s.cursor=s.limit-e;break;case 2:if(s.slice_from("løs"))break}}})(),s.cursor=s.limit-r,s.limit-s.cursor);return s.cursor<m||(e=s.limit_backward,s.limit_backward=m,s.ket=s.cursor,s.in_grouping_b(a,98,122)?(s.bra=s.cursor,""!=(_=s.slice_to())&&(s.limit_backward=e,s.eq_s_b(_))&&s.slice_del()):s.limit_backward=e),s.cursor=s.limit-i,s.cursor=s.limit_backward,!0},this.stemWord=function(r){return s.setCurrent(r),this.stem(),s.getCurrent()}};
window.Stemmer = DanishStemmer;
