A method for detection and analysis of a learner's cognitive flow, the method comprising: asking the learner to perform a task, wherein the task has a difficulty level; recording a plurality of parameters related to the task using a data capture tool; measuring brain activity of the learner by sensing an electroencephalogram EEG signal using an EEG device; measuring concentration of the learner by sensing galvanic skin response GSR using a GSR sensing device measuring stress level of the learner by sensing heart rate variability HRV; measuring an actual cognitive state of the learner during the task using a questionnaire filled by the learner after performing the task; creating, by a processor, a Bayesian network framework, wherein the Bayesian network framework includes a plurality of evidence nodes, a plurality of sensor nodes and a plurality of state nodes; providing, by the processor, intelligence quotient IQ level of the person and the difficulty level of the task as inputs to the plurality of evidence nodes; predicting, by the processor, a cognitive state of the learner using the results obtained from the plurality of sensor nodes, the inputs provided at the plurality of evidence nodes and the plurality of parameters; comparing, by the processor, the predicted cognitive state with the actual cognitive state, wherein if the predicted cognitive state is same as the actual cognitive state then the processor validating the Bayesian network framework, else resolving a conflict generated due to the difference between the predicted cognitive state and the actual cognitive state by reasoning between the nodes using probabilistic queries. asking the learner to perform a task, wherein the task has a difficulty level; recording a plurality of parameters related to the task using a data capture tool; measuring brain activity of the learner by sensing an electroencephalogram EEG signal using an EEG device; measuring concentration of the learner by sensing galvanic skin response GSR using a GSR sensing device measuring stress level of the learner by sensing heart rate variability HRV; measuring an actual cognitive state of the learner during the task using a questionnaire filled by the learner after performing the task; creating, by a processor, a Bayesian network framework, wherein the Bayesian network framework includes a plurality of evidence nodes, a plurality of sensor nodes and a plurality of state nodes; providing, by the processor, intelligence quotient IQ level of the person and the difficulty level of the task as inputs to the plurality of evidence nodes; predicting, by the processor, a cognitive state of the learner using the results obtained from the plurality of sensor nodes, the inputs provided at the plurality of evidence nodes and the plurality of parameters; comparing, by the processor, the predicted cognitive state with the actual cognitive state, wherein if the predicted cognitive state is same as the actual cognitive state then the processor validating the Bayesian network framework, else resolving a conflict generated due to the difference between the predicted cognitive state and the actual cognitive state by reasoning between the nodes using probabilistic queries.