I have a complicated function as

`f=m*Log[lamda1]+lamda1*Total[x1]+m*Log[lamda2]+lamda2*Total[x2]+ m*Log[s1*s2*a*(a+1)]-Total[Log[(1+s1*(Exp[lamda1*x1]-1)+s2*(Exp[lamda2*x2]-1))^(a+2)]] `

x1 and x2 are two vectors, respectively as

`x1={53, 55, 85,87, 22, 23, 25,93, 51, 62, 53,32, 43, 47, 30, 88,59, 49, 42, 71,41, 82, 75, 93, 37} x2={89, 90, 59,50, 25, 29, 54,62, 39, 25, 89,32, 33, 63, 38, 77,55, 41, 31, 66,57, 32, 43, 88, 34} and m=25. `

I want to determine 5 parameters, `{s1,s2,a,lamda1,lamda2}`

to maximize `f`

. and maximum of f.

I wrote in mathematica

`x1={53, 55, 85,87, 22, 23, 25,93, 51, 62, 53,32, 43, 47, 30, 88,59, 49, 42, 71,41, 82, 75, 93, 37} x2={89, 90, 59,50, 25, 29, 54,62, 39, 25, 89,32, 33, 63, 38, 77,55, 41, 31, 66,57, 32, 43, 88, 34} m=25 NMaximize[{m*Log[lamda1]+lamda1*Total[x1]+m*Log[lamda2]+lamda2*Total[x2]+ m*Log[s1*s2*a*(a+1)]-Total[Log[(1+s1*(Exp[lamda1*x1]-1)+s2*(Exp[lamda2*x2]-1))^(a+2)]]},{s1,s2,a,lamda1,lamda2}] `

But my answer is

`NMaximize[{1398 lamda1 + 1301 lamda2 + 25 Log[lamda1] + 25 Log[lamda2] + 25 Log[a (1 + a) s1 s2] - Log[(1 + (-1 + E^(22 lamda1)) s1 + (-1 + E^(25 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(62 lamda1)) s1 + (-1 + E^(25 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(23 lamda1)) s1 + (-1 + E^(29 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(42 lamda1)) s1 + (-1 + E^(31 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(32 lamda1)) s1 + (-1 + E^(32 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(82 lamda1)) s1 + (-1 + E^(32 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(43 lamda1)) s1 + (-1 + E^(33 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(37 lamda1)) s1 + (-1 + E^(34 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(30 lamda1)) s1 + (-1 + E^(38 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(51 lamda1)) s1 + (-1 + E^(39 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(49 lamda1)) s1 + (-1 + E^(41 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(75 lamda1)) s1 + (-1 + E^(43 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(87 lamda1)) s1 + (-1 + E^(50 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(25 lamda1)) s1 + (-1 + E^(54 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(59 lamda1)) s1 + (-1 + E^(55 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(41 lamda1)) s1 + (-1 + E^(57 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(85 lamda1)) s1 + (-1 + E^(59 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(93 lamda1)) s1 + (-1 + E^(62 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(47 lamda1)) s1 + (-1 + E^(63 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(71 lamda1)) s1 + (-1 + E^(66 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(88 lamda1)) s1 + (-1 + E^(77 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(93 lamda1)) s1 + (-1 + E^(88 lamda2)) s2)^( 2 + a)] - 2 Log[(1 + (-1 + E^(53 lamda1)) s1 + (-1 + E^(89 lamda2)) s2)^( 2 + a)] - Log[(1 + (-1 + E^(55 lamda1)) s1 + (-1 + E^(90 lamda2)) s2)^( 2 + a)]}, {s1, s2, a, lamda1, lamda2}] `

I will be thanks for any help.